summaryrefslogtreecommitdiffstats
path: root/tools/perf.c
diff options
context:
space:
mode:
authorQuentin Armitage <quentin@armitage.org.uk>2010-03-24 12:26:46 -0500
committerJeffrey C. Ollie <jeff@ocjtech.us>2010-03-24 12:26:46 -0500
commit4f1aa735c204d08b6022a99b01e97f3cd6c98c75 (patch)
tree8fc60c8a76a07a0c9e35dd4c96aa3bd17c48ee23 /tools/perf.c
parente909440a2abcdf1ed58810a20a7fd6a8f187816f (diff)
downloadiksemel-fedora-1.4.tar.gz
iksemel-fedora-1.4.tar.xz
iksemel-fedora-1.4.zip
Fix alignment on architectures where doubles are 64bit aligned, but pointers are smallerfedora-1.4
The tst-ikstack test fails on architectures where doubles are 64bit aligned, but pointers are smaller, hence ppc, sparc and arm have the problems. The issue is that the ikstack and ikschunk structures are not necessarily aligned to 64bits, and in fact ikschunk, with 32bit pointers, is 20 bytes long, and hence not aligned. The patch forces alignment of the two structures, and more importantly makes the sizes of the structs multiples of the size of a double. I have made a couple of other small changes: i) The ALIGN macro for a pointer that was already aligned was adding DEFAULT_ALIGNMENT bytes unnecessarily. The amendment also means that the parameter to the macro is only processed once. ii) The changing of char data[4] to char data[0] in the ikschunk struct avoids a wasted allocation of 4 bytes.
Diffstat (limited to 'tools/perf.c')
0 files changed, 0 insertions, 0 deletions