This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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][AArch64] Fix libc internal asm profiling code


On 15/01/16 15:46, Szabolcs Nagy wrote:
> When glibc is built with --enable-profile, the ENTRY of
> asm functions includes CALL_MCOUNT for profiling.
> (matters for binaries static linked against libc_p.a.)
> 
> CALL_MCOUNT did not save/restore argument registers
> around the _mcount call so it clobbered them.
> (it is enough to only save/restore the arguments passed
> to a given asm function, but that would be too many asm
> changes so it is simpler to always save all argument
> registers in this macro.)
> 
> float args are not saved: mcount does not clobber the
> float regs and currently no asm function takes float
> arguments anyway.
> 
> 2016-01-15  Szabolcs Nagy  <szabolcs.nagy@arm.com>
> 
>     * sysdeps/aarch64/Makefile (CFLAGS-mcount.c): Add -mgeneral-regs-only.
>     * sysdeps/aarch64/sysdep.h (CALL_MCOUNT): Save argument registers.

ping.

with bz in changelog:

2016-07-08  Szabolcs Nagy  <szabolcs.nagy@arm.com>

	[BZ #18707]
	* sysdeps/aarch64/Makefile (CFLAGS-mcount.c): Add -mgeneral-regs-only.
	* sysdeps/aarch64/sysdep.h (CALL_MCOUNT): Save argument registers.


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