This is the mail archive of the gdb@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

How to call functions which have ifunc symbols (e.g. strcmp) from inside gdb


Hi,

Calling strcmp from inside gdb thusly:

 (gdb) call strcmp("foo", "foo")
 $3 = -146921376

Gives unexpected values.

I note that there is a bug for this already
(http://sourceware.org/bugzilla/show_bug.cgi?id=12347) and this mentions
that the strcmp symbol is the ifunc wrapper for the strcmp function, but
this seems counter-intuitive for a user of gdb.

Is there an alternative method of calling ifunc-enabled functions which
can be used for calls (and related items such as conditional
breakpoints) within gdb?  Or is just an open bug which is awaiting a fix
and I should work around by making wrappers for such functions which I
want to call from within gdb?


        Many thanks for any help!

Attachment: signature.asc
Description: Digital signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]