eclipse-cdt-cloud / eclipse-cdt-cloud/cdt-gdb-adapter

gdb does not stop at launch - likely because of `exec-run` and race conditions

Open
#238 10 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
39
Forks
56
Avg merge
3d 9h
Merged PRs (30d)
2

Description

Checking with the verbose option we can see

* gdb is started
* setup (config, pretty-printing, ...) is done
* breakpoints are set (and responded by GDB to be set as pending)
* `-exec-run` is executed
* gdb reports adjusted breakpoints (now active, with full address)
* gdb reports libraries loaded
* gdb reports running
* everything is over

This _may_ be solved by executing `-exec-run --start` (so it will stop the execution at the start of the inferior’s main subprogram) and only after the "internal" startup is completely done (including getting messages for everything sent) then issuing a `-exec-continue`.
This _should_ fix all race conditions on startup.

Ideally there would be an option "stopAtConnect" or similar, if this is set then `-exec-continue` won't be executed and we can actually stop at the start.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.