[PATCH 00/11] Fixing GNU ifunc support

Alan Hayward Alan.Hayward@arm.com
Mon Mar 12 11:16:00 GMT 2018



> On 9 Mar 2018, at 21:18, Pedro Alves <palves@redhat.com> wrote:
> 
> On 03/09/2018 09:16 PM, Pedro Alves wrote:
> 
>> Pedro Alves (11):
>>  eval.c: reverse minsym and sym
>>  Fix breakpoints in ifunc after inferior resolved it (@got.plt symbol
>>    creation)
>>  Fix calling ifunc functions when resolver has debug info and different
>>    name
>>  Calling ifunc functions when target has no debug info but resolver has
>>  Calling ifunc functions when resolver has debug info, user symbol same
>>    name
>>  Fix setting breakpoints on ifunc functions after they're already
>>    resolved
>>  Breakpoints, don't skip prologue of ifunc resolvers with debug info
>>  Eliminate find_pc_partial_function_gnu_ifunc
>>  Factor out minsym_found/find_function_start_sal overload
>>  Extend GNU ifunc testcases
>>  Fix resolving GNU ifunc bp locations when inferior runs resolver
> 
> As always, I forgot to say that I pushed this to the
> "users/palves/ifunc" branch on sourceware.org.
> 

I was using your branch to try a few things, and debugging gdb gave me a segfault:

$ ./gdb/gdb ./gdb/gdb

(gdb) b amd64_push_dummy_call
Segmentation fault (core dumped)

Backtrace of core file gives me:

#0  get_objfile_arch (objfile=0x0) at ../../src/binutils-gdb/gdb/objfiles.c:448
#1  0x000000000067a889 in find_function_start_sal (func_addr=4335952, section=0x1a4eb20, funfirstline=<optimised out>)
    at ../../src/binutils-gdb/gdb/symtab.c:3590
#2  0x000000000067a934 in find_function_start_sal (sym=sym@entry=0x2b78980, funfirstline=<optimised out>)
    at ../../src/binutils-gdb/gdb/symtab.c:3625
#3  0x00000000005e77f2 in symbol_to_sal (result=result@entry=0x7fff8467b1a0, funfirstline=<optimised out>, sym=sym@entry=0x2b78980)
    at ../../src/binutils-gdb/gdb/linespec.c:4679
#4  0x00000000005ebbd0 in convert_linespec_to_sals (state=state@entry=0x7fff8467b560, ls=ls@entry=0x7fff8467b5b0)
    at ../../src/binutils-gdb/gdb/linespec.c:2384
#5  0x00000000005ed26d in parse_linespec (parser=parser@entry=0x7fff8467b530, arg=<optimised out>, match_type=<optimised out>)
    at ../../src/binutils-gdb/gdb/linespec.c:2771

This was running on Ubuntu 14.04.5 LTS on x86, gdb built with gcc 5.4.0.
Using gdb git HEAD 0dec80227990d5cc2fddd5e5e5bce92fd6629260

Alan.




More information about the Gdb-patches mailing list