glibc/sysdeps
Ilya Leoshkevich 71c01af52f S390: Implement 64-bit __fentry__
* Since __fentry__ is almost the same as _mcount, reuse the code by
  #including it twice with different #defines around.
* Remove LA usages - they are needed in 31-bit mode to clear the top
  bit, but in 64-bit they appear to do nothing.
* Add CFI rule for the nonstandard return register. This rule applies
  to the current function (binutils generates a new CIE - see
  gas/dw2gencfi.c:select_cie_for_fde()), so it is not necessary to put
  __fentry__ into a new file.
* Fix CFI offset for %r14.
* Add CFI rule for %r0.
* Fix unwound value of %r15 being off by 244 bytes.
* Unwinding in __fentry__@plt does not work, no plan to fix it - it
  would require asking linker to generate CFI for return address in
  %r0.  From functional perspective keeping it broken is fine, since
  the callee did not have a chance to do anything yet.  From
  convenience perspective it would be possible to enhance GDB in the
  future to treat __fentry__@plt in a special way.
* Fix whitespace.
* Fix offsets in comments, which were copied from 32-bit code.
* 32-bit version will not be implemented, since it's not compatible
  with the corresponding PLT stubs: they assume %r12 points to GOT,
  which is not the case for gcc-emitted __fentry__ stub, which runs
  before the prolog.

This patch adds the runtime support in glibc for the -mfentry
gcc feature introduced in [1] and [2].

[1] https://gcc.gnu.org/ml/gcc-patches/2018-07/msg00784.html
[2] https://gcc.gnu.org/ml/gcc-patches/2018-07/msg00912.html

ChangeLog:

	* sysdeps/s390/s390-64/Versions (__fentry__): Add.
	* sysdeps/s390/s390-64/s390x-mcount.S: Move the common
	code to s390x-mcount.h and #include it.
	* sysdeps/s390/s390-64/s390x-mcount.h: New file.
	* sysdeps/unix/sysv/linux/s390/s390-64/libc.abilist
	(__fentry__): Add.
2018-08-10 09:07:44 +02:00
..
aarch64 [aarch64] Fix value of MIN_PAGE_SIZE for testing 2018-08-08 22:47:17 +05:30
alpha
arm
generic Replace gen-libm-test.pl with gen-libm-test.py. 2018-08-09 15:34:12 +00:00
gnu
hppa Move SNAN_TESTS_PRESERVE_PAYLOAD out of math-tests.h. 2018-08-01 11:21:16 +00:00
htl hurd: Avoid PLTs for __pthread_get/setspecific 2018-08-09 01:28:55 +02:00
hurd
i386 Move __fentry__ version definition to sysdeps/{i386,x86_64} 2018-08-10 09:07:44 +02:00
ia64
ieee754
init_array
m68k
mach hurd: Fix exec usage of mach_setup_thread 2018-08-01 00:10:03 +02:00
microblaze
mips Do not define various fenv.h macros for MIPS soft-float (bug 23479). 2018-08-02 15:53:29 +00:00
nios2
nptl
posix
powerpc Rename the glibc.tune namespace to glibc.cpu 2018-08-02 23:49:19 +05:30
pthread
riscv RISC-V: Don't use ps_get_thread_area in libthread_db (bug 23402) 2018-08-06 12:51:59 -07:00
s390 S390: Implement 64-bit __fentry__ 2018-08-10 09:07:44 +02:00
sh
sparc
unix S390: Implement 64-bit __fentry__ 2018-08-10 09:07:44 +02:00
wordsize-32
wordsize-64
x86 x86: Move STATE_SAVE_OFFSET/STATE_SAVE_MASK to sysdep.h 2018-08-06 06:25:43 -07:00
x86_64 Move __fentry__ version definition to sysdeps/{i386,x86_64} 2018-08-10 09:07:44 +02:00