Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GDB segfaults when debugging anything using kj-async or CAPNP_DEBUG_TYPES #191

Closed
arichardson opened this issue Mar 16, 2015 · 5 comments
Closed

Comments

@arichardson
Copy link
Contributor

The symbol kj::Quantity<decltype(((long)(1)) * ((long)(1))), kj::::NanosecondLabel> kj::operator*<long, long, kj::::NanosecondLabel>(long, kj::Quantity<long, kj::_::NanosecondLabel>) causes GDB (and c++filt) to crash while demangling it: https://sourceware.org/bugzilla/show_bug.cgi?id=18133. While this is an upstream bug in binutils, it makes it impossible to debug my application. It would be really nice if a workaround could be found.

@kentonv
Copy link
Member

kentonv commented Mar 16, 2015

Yeah, I run into this all the time and it's really annoying. There is a work-around, though:

  1. Start gdb without telling it an executable.
  2. Disable demangling: set demangle-style none
  3. Now load the executable: file path/to/executable
  4. Proceed as normal... demangling names in your head. :(

@kentonv
Copy link
Member

kentonv commented Mar 16, 2015

Also here is a previous bug report for the same problem:

https://sourceware.org/bugzilla/show_bug.cgi?id=17066

@kentonv kentonv changed the title Cannot debug anything that uses Cap'nProto with GDB GDB segfaults when debugging anything using kj-async or CAPNP_DEBUG_TYPES Mar 16, 2015
@arichardson
Copy link
Contributor Author

Thanks, didn't think about disabling demangling.

@kentonv
Copy link
Member

kentonv commented Mar 17, 2015

(Thanks to @mortehu for introducing me to the work-around.)

@kentonv
Copy link
Member

kentonv commented Apr 23, 2017

I believe this has long been fixed in gdb.

@kentonv kentonv closed this as completed Apr 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants