s390: Implement 'type_align' gdbarch method
authorAndreas Arnez <arnez@linux.ibm.com>
Fri, 9 Aug 2019 18:27:03 +0000 (20:27 +0200)
committerAndreas Arnez <arnez@linux.ibm.com>
Fri, 9 Aug 2019 18:27:03 +0000 (20:27 +0200)
commit1022c627dbd9d7f7f67ac68f16de05474de7a75a
tree54bac81fe8d3f44c008f16429c295bab8b2e844b
parentf211b8c0b91fc7b1657079a495f05a9a4d957821
s390: Implement 'type_align' gdbarch method

The align.exp test case yields many FAILs on s390x, since GDB's _Alignoff
doesn't always agree with the compiler's.  On s390x, the maximum alignment
is 8, but GDB returns an alignment of 16 for 16-byte data types such as
"long double".

This is fixed by implementing the type_align gdbarch method.  The new
method returns an alignment of 8 for all integer, floating-point, and
vector types larger than 8 bytes.  With this change, all align.exp tests
pass.

gdb/ChangeLog:

* s390-tdep.c (s390_type_align): New function.
(s390_gdbarch_init): Set it as type_align gdbarch method.
gdb/ChangeLog
gdb/s390-tdep.c
This page took 0.026272 seconds and 4 git commands to generate.