[PATCH 2/2] Enable ILP32 mode on aarch64 (version 3)

Steve Ellcey sellcey@caviumnetworks.com
Mon Dec 19 22:46:00 GMT 2016


Here is a new version of my aarch64 ILP32 patch.  It includes
everything except the ablist changes (sent in a separate patch) and a
change to build-many-glibcs.py to build the ILP32 toolchain, which I
will send in a new patch later today or tomorrow.

With the checkin of the rename consolidation that happend a few days
ago, this patch could be checked in before (or after) Adhemerval's
sysvipc consolidation patch.

I believe I have addressed all the issues with the last patch.  I added
elf/cache.c to print out FLAG_AARCH64_LIB32 when it is used.  I fixed
the preprocessor indentation in tls-macros.h.  I added an aarch64
specific statfs.h header file so that the statfs and statfs64
structures match and we can alias the statfs and statfs64 calls to each
other.  I moved c++-types.data to the lp64 directory and created a new
ilp32 version of c++-types.data so that the C++ ABI checking test now
passes on ILP32.  And I fixed the .Lsyscall_error routine in sysdep.h
to use PTR_REG.  This fixed several of the TLS tests that were failing.

With these changes there are 7 tests that fail in ILP32 but pass in
LP64 mode:

FAIL: math/test-double
FAIL: math/test-double-finite
FAIL: math/test-float
FAIL: math/test-float-finite
FAIL: misc/tst-sync_file_range
FAIL: stdlib/tst-makecontext3

tst-mallocstate also fails, I had to remove it from the run because
when it failed it killed the 'make check'.
See https://sourceware.org/ml/libc-alpha/2016-12/msg00527.html

I have a fix for two of the four math tests, but even with this
patch two of them still fail due to the inexact exception being set.
See https://sourceware.org/ml/libc-alpha/2016-11/msg01075.html

Steve Ellcey
sellcey@caviumnetworks.com


2016-12-19  Andrew Pinski  <andrew.pinski@caviumnetworks.com>
	    Yury Norov  <ynorov@caviumnetworks.com>
	    Steve Ellcey  <sellcey@caviumnetworks.com>

	* elf/cache.c (print_entry): Add FLAG_AARCH64_LIB32.
	* sysdeps/aarch64/configure.ac (HAVE_AARCH64_ILP32): New define.
	(default-abi): Allow for ilp32 ABI.
	* sysdeps/aarch64/configure: Regenerate.
	* sysdeps/aarch64/Implies: Deleted.
	* sysdeps/aarch64/ilp32/Implies: New file.
	* sysdeps/aarch64/ilp32/Implies-after: New file.
	* sysdeps/aarch64/lp64/Implies: New file.
	* sysdeps/aarch64/lp64/Implies-after: New file.
	* sysdeps/aarch64/preconfigure (machine): Check for ilp32/lp64.
	* sysdeps/aarch64/tls-macros.h (TLS_IE): Remove register specification
	for __result and ifdef for ILP32.
	* sysdeps/generic/ldconfig.h (FLAG_AARCH64_LIB32): New define.
	* sysdeps/unix/sysv/linux/aarch64/Implies: Remove generic and
	wordsize-64 entries.
	* sysdeps/unix/sysv/linux/aarch64/Makefile (abi-variants): Add
	new variants for ilp32 and ilp32_be.
	(abi-lp64-options, abi-lp64_be-options): define __LP64__ and
	undefine __ILP32__.
	(abi-lp64-condition, abi-lp64_be-condition): Check for __WORDSIZE
	equal to 64.
	(abi-ilp32-options, abi-ilp32-condition, abi-ilp32_be-options,
	abi-ilp32_be-condition): New.
	* sysdeps/unix/sysv/linux/aarch64/configure.ac (arch_minimum_kernel):
	Use different value for ILP32.
	(LIBC_SLIBDIR_RTLDDIR): Modify for ILP32.
	* sysdeps/unix/sysv/linux/aarch64/configure: Regenerate.
	* sysdeps/unix/sysv/linux/aarch64/ilp32/Implies: New file.
	* sysdeps/unix/sysv/linux/aarch64/ilp32/c++-types.data: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/ilp32/kernel_stat.h: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/ilp32/shlib-versions: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/bits/stat.h: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/bits/statfs.h: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/bits/typesizes.h: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/bits/utmp.h: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/bits/utmpx.h: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/kernel-features.h: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/Implies: Add unix/sysv/linux/aarch64.
	* sysdeps/unix/sysv/linux/aarch64/ioctl.S: Move to lp64 directory.
	* sysdeps/unix/sysv/linux/aarch64/mmap.c: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/shlib-versions: Ditto.
	* sysdeps/unix/sysv/linux/aarch64/c++-types.data: Ditto.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: aarch64-ilp32-final.patch
Type: text/x-patch
Size: 34121 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/libc-alpha/attachments/20161219/74bbb4f7/attachment.bin>


More information about the Libc-alpha mailing list