Comments (4)
OMPI_CXX=g++
This part can go as an env param, right?
mpiexec -np 1
What is this part supposed to do?
from dap-mode.
OMPI_CXX=g++
This part can go as an env param, right?
I did not think of that! Thank you. I'll dig around to see how to add env parameter in the launch.json
.
mpiexec -np 1
What is this part supposed to do?
The mpiexec
command is used to execute the binary. Since the binary has been compiled with mpi++
, using mpiexec
is the required method to run it. The -np
flag specifies the number of processes to initiate, which is set to 1 in this case. Debugging multiple processes can be tough -np 2
but theoretically np 1
should be same as debugging any C++
code.
from dap-mode.
To me it sounds like one way to debug it is to attach to the process, right? That would be the way to debug it even if you start the process via command like lldb?
from dap-mode.
TL;DR
Could you assist me / point me to some examples which might help me in resolving the issue with the attach
request in the LLDB setting?
Long answer
I tried to attach the process and debug the code. However, I'm encountering issues when using the attach
request. Below are the steps I've taken and the outcomes:
-
Initial Setup:
- Compiled the C++ code with
g++ -g betweeness_centrality_serial.cpp -o betweeness_centrality_serial
. - Launched LLDB with
lldb betweeness_centrality_serial
.
- Compiled the C++ code with
-
LLDB Attach Attempt:
- Used the following
launch.json
configuration with anattach
request:{ "configurations": [{ "type": "lldb-vscode", "request": "attach", "name": "Debug | C++ | Betweenness Centrality Serial", "cwd": "${workspaceFolder}", "program": "${workspaceFolder}/betweeness_centrality_serial", "pid": "${command:PickProcess}" }] }
- Selected the process from the list corresponding to the
lldb <binary>
- Result: The debug session exited with process status: 9.
- Used the following
-
Changing Request to
launch
:- Modified the request to
launch
inlaunch.json
. - Outcome: Debugger functioned correctly, allowing PID selection and showing expected behavior.
- Modified the request to
-
Parallel Execution Issue:
- Executed
OMPI_CXX=g++ mpiexec -np 1 lldb ./bc_dslV2 small.graph
. - Tried attaching the process with the same
attach
configuration for a parallel setup. - Result: Encountered the same error - "debug session exited with process status".
- Executed
I suspect the issue lies with the attach
request configuration itself. I've referred to LLDB-VSCode documentation and tried all the three techniques mentioned in the doc (pid, waitFor, application name) but couldn't pin point it whether it's a syntax issue or a problem with the process.
from dap-mode.
Related Issues (20)
- Have you loaded the lldb specific package? HOT 1
- How to specify the java version when I debug the program with dap-debug HOT 1
- Breakpoints not working with debugpy HOT 3
- Rust debugger doesn't print array elements in local variables HOT 2
- Cannot run DAP for Python - dap-exception-breakpoints HOT 1
- dap-ui-locals "Invalid menu item in easymenu" in Emacs 29
- Support gdb's built-in DAP implementation HOT 1
- [golang] Expanding map only shows len() not content. HOT 3
- Default Go Dlv Attach Configuration Failing
- dap-dlv-go .env variables with special characters problem
- Typescript - dap-hydra/dap-disconnect does not clean up enabled modes
- [Q] Question about dap-ui-locals and variable expansion HOT 3
- Crashes on breakpoint (Python) HOT 5
- Multi-process debugging: dap-python and debugpyAttach/startDebugging HOT 7
- doc missing HOT 2
- `Treemacs` issue when trying to utilize `dap-mode`
- company-mode off-by-one error regarding prefix length in dap-ui-repl
- delete-session bug reporting.. not killing output buffer
- Trying to debug C++ code running in a docker container with gdbserver but can't seem to connect
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dap-mode.