This is the mail archive of the gdb-patches@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]

Re: [patch+7.12.1 1/2] Code cleanup: write_exp_msymbol: +is_tls


On 10/09/2016 07:56 PM, Jan Kratochvil wrote:
> Hi,
> 
> no functionality change, for patch 2/2.


>    /* The minimal symbol might point to a function descriptor;
>       resolve it to the actual code address instead.  */
>    pc = gdbarch_convert_from_func_ptr_addr (gdbarch, addr, &current_target);
> -  if (pc != addr)
> +  if (!is_tls && pc != addr)

This bit might be a functionality change / fix, AFAICS.  I pushed in
the  other patch without this bit, because:

 - it looked like we could skip the gdbarch_convert_from_func_ptr_addr
   call too?

 - I wondered whether for TLS function pointers we should
   actually translate the TLS address and then
   still see if the translated address points to a function
   descriptor that needs to be resolved, like in the non-TLS case.

At this point, it seemed better to leave it be until we add
a testcase with a TLS function pointer.

Thanks,
Pedro Alves


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