ddcc / libcpuidoverride

GNU General Public License v3.0
20 stars 8 forks source link

patching binary breaks gdb #1

Open tyler274 opened 3 years ago

tyler274 commented 3 years ago

if I patch a binary, it runs, but GDB is broken.

warning: Unable to find dynamic linker breakpoint function.
GDB will be unable to debug shared library initializers
and track explicitly loaded dynamic code.
Overriding feature AVX!
Overriding feature AVX2!

Program received signal SIGSEGV, Segmentation fault.
ddcc commented 3 years ago

What platform and version of glibc is this on? Could you post the backtrace of the crash? You can enable coredumps using ulimit then load that in a debugger.

tyler274 commented 3 years ago

I had to shelve getting this working for a while to catch up on the project implementation itself. Kernel ver is 5.4.0-58-generic OS is

Distributor ID: Ubuntu
Description:    Ubuntu 20.04.1 LTS
Release:        20.04
Codename:       focal

I don't have root on the box, and can't mess with perf paranoia either. I was trying to debug a rust application, and can try to get a coredump later (a few weeks...)

ddcc commented 3 years ago

Hmm ok, I never tested with any non-C/C++ binaries. I'm curious if this is a Rust-specific issue; does the interception work fine with e.g. /bin/true?