gcc/libffi/testsuite
Jakub Jelinek 37be80af29 libffi: Fix up x86_64 classify_argument
As the following testcase shows, libffi didn't handle properly
classify_arguments of structures at byte offsets not divisible by
UNITS_PER_WORD.  The following patch adjusts it to match what
config/i386/ classify_argument does for that and also ports the
PR38781 fix there (the second chunk).

This has been committed to upstream libffi already:
5651bea284

2021-06-16  Jakub Jelinek  <jakub@redhat.com>

	* src/x86/ffi64.c (classify_argument): For FFI_TYPE_STRUCT set words
	to number of words needed for type->size + byte_offset bytes rather
	than just type->size bytes.  Compute pos before the loop and check
	total size of the structure.
	* testsuite/libffi.call/nested_struct12.c: New test.

(cherry picked from commit 041f741770)
2022-05-11 07:58:19 +02:00
..
config
lib [PR libffi/65567] libffi: Fix, and simply libffi_feature_test 2016-05-23 16:54:04 +02:00
libffi.call libffi: Fix up x86_64 classify_argument 2022-05-11 07:58:19 +02:00
libffi.complex Merge libffi to upstream commit c82cc159426d8d4402375fa1ae3f045b9cf82e16 2015-01-12 08:19:59 -08:00
libffi.go ffi.c (ffi_struct_type): Put type declaration on separate line. 2016-09-04 17:39:05 +00:00
libffi.special libffi-dg.exp: Rename ... 2010-11-15 20:30:37 +00:00
Makefile.am Merge libffi to upstream commit c82cc159426d8d4402375fa1ae3f045b9cf82e16 2015-01-12 08:19:59 -08:00
Makefile.in Update GCC to autoconf 2.69, automake 1.15.1 (PR bootstrap/82856). 2018-10-31 17:03:16 +00:00