gcc/libgcc
Szabolcs Nagy 328c17af77 libgcc: aarch64: Add SME runtime support
The call ABI for SME (Scalable Matrix Extension) requires a number of
helper routines which are added to libgcc so they are tied to the
compiler version instead of the libc version. See
https://github.com/ARM-software/abi-aa/blob/main/aapcs64/aapcs64.rst#sme-support-routines

The routines are in shared libgcc and static libgcc eh, even though
they are not related to exception handling.  This is to avoid linking
a copy of the routines into dynamic linked binaries, because TPIDR2_EL0
block can be extended in the future which is better to handle in a
single place per process.

The support routines have to decide if SME is accessible or not. Linux
tells userspace if SME is accessible via AT_HWCAP2, otherwise a new
__aarch64_sme_accessible symbol was introduced that a libc can define.
Due to libgcc and libc build order, the symbol availability cannot be
checked so for __aarch64_sme_accessible an unistd.h feature test macro
is used while such detection mechanism is not available for __getauxval
so we rely on configure checks based on the target triplet.

Asm helper code is added to make writing the routines easier.

libgcc/ChangeLog:

	* config/aarch64/t-aarch64: Add sources to the build.
	* config/aarch64/__aarch64_have_sme.c: New file.
	* config/aarch64/__arm_sme_state.S: New file.
	* config/aarch64/__arm_tpidr2_restore.S: New file.
	* config/aarch64/__arm_tpidr2_save.S: New file.
	* config/aarch64/__arm_za_disable.S: New file.
	* config/aarch64/aarch64-asm.h: New file.
	* config/aarch64/libgcc-sme.ver: New file.
2023-12-08 11:29:06 +00:00
..
config libgcc: aarch64: Add SME runtime support 2023-12-08 11:29:06 +00:00
soft-fp
ChangeLog Daily bump. 2023-12-08 00:17:33 +00:00
config.host arm: libgcc: provide implementations of __sync_synchronize 2023-11-24 14:15:26 +00:00
config.in libgcc: aarch64: Configure check for __getauxval 2023-12-08 11:29:06 +00:00
configure libgcc: aarch64: Configure check for __getauxval 2023-12-08 11:29:06 +00:00
configure.ac libgcc: aarch64: Configure check for __getauxval 2023-12-08 11:29:06 +00:00
crtstuff.c
dfp-bit.c
dfp-bit.h
divmod.c
emutls.c libgcc: Avoid -Wbuiltin-declaration-mismatch warnings in emutls.c 2023-12-06 12:27:12 +01:00
enable-execute-stack-empty.c
enable-execute-stack-mprotect.c
find-symver.awk
fixed-bit.c
fixed-bit.h
fixed-obj.mk
floatunsidf.c
floatunsisf.c
floatunsitf.c
floatunsixf.c
fp-bit.c
fp-bit.h
gbl-ctors.h
gcov.h
gen-fixed.sh
generic-morestack-thread.c
generic-morestack.c
generic-morestack.h
gstdint.h
gthr-posix.h
gthr-single.h
gthr.h
hardcfr.c libgcc: mark __hardcfr_check_fail as always_inline 2023-11-23 17:31:40 +01:00
libgcc-std.ver.in Introduce strub: machine-independent stack scrubbing 2023-12-05 21:07:36 -03:00
libgcc2.c
libgcc2.h Introduce strub: machine-independent stack scrubbing 2023-12-05 21:07:36 -03:00
libgcov-driver-system.c
libgcov-driver.c
libgcov-interface.c
libgcov-merge.c
libgcov-profiler.c
libgcov-util.c
libgcov.h gcov: Fix use of __LIBGCC_HAVE_LIBATOMIC 2023-12-01 09:54:24 +01:00
Makefile.in strub: enable conditional support 2023-12-07 12:58:20 -03:00
memcmp.c
memcpy.c
memmove.c
memset.c
mkheader.sh
mkmap-flat.awk
mkmap-symver.awk
offloadstuff.c
shared-object.mk
siditi-object.mk
static-object.mk
strub.c Introduce strub: machine-independent stack scrubbing 2023-12-05 21:07:36 -03:00
sync.c
udivhi3.c
udivmod.c
udivmodhi4.c
udivmodsi4.c
unwind-arm-common.inc
unwind-c.c
unwind-compat.c
unwind-compat.h
unwind-dw2-btree.h
unwind-dw2-execute_cfa.h
unwind-dw2-fde-compat.c
unwind-dw2-fde-dip.c
unwind-dw2-fde.c
unwind-dw2-fde.h
unwind-dw2.c
unwind-dw2.h
unwind-generic.h
unwind-pe.h [committed] Fix build of libgcc on ports using FDPIC 2023-12-02 22:45:48 -07:00
unwind-seh.c
unwind-sjlj.c
unwind.inc
vtv_end.c
vtv_end_preinit.c
vtv_start.c
vtv_start_preinit.c