[PATCH 2/2] recordmcount: Handle sections with no non-weak symbols

Christophe Leroy christophe.leroy at csgroup.eu
Tue May 3 21:20:22 AEST 2022



Le 03/05/2022 à 01:52, Steven Rostedt a écrit :
> On Mon, 2 May 2022 14:44:56 +0000
> Christophe Leroy <christophe.leroy at csgroup.eu> wrote:
> 
>> If we do that after the linking, won't it be a nightmare with the
>> trampolines installed by the linker when the destination is over the 24
>> bits limit ?
> 
> Not sure what you mean. The locations I'm talking about is the full
> address saved in the __mcount_loc table (data section).
> 

Maybe I misunderstood. When you say 'after linking', do you mean vmlinux 
or vmlinux.o ?

In vmlinux, the addresses to be saved in __mcount_loc table might not 
contain anymore a call to _mcount but a call to a trampoline that jumps 
to _mcount, in case _mcount is too far from the said location at link 
time. That's what I meant.

Christophe


More information about the Linuxppc-dev mailing list