Messages in this thread | | | Date | Thu, 23 Nov 2017 11:02:14 +0100 | From | Peter Zijlstra <> | Subject | Re: [PATCH 1/6] perf: Add new type PERF_TYPE_PROBE |
| |
On Wed, Nov 15, 2017 at 09:23:33AM -0800, Song Liu wrote:
> Note: We use type __u64 for pointer probe_desc instead of __aligned_u64. > The reason here is to avoid changing the size of struct perf_event_attr, > and breaking new-kernel-old-utility scenario. To avoid alignment problem > with the pointer, we will (in the following patches) copy probe_desc to > __aligned_u64 before using it as pointer.
ISTR there are only relatively few architectures where __u64 and __aligned_u64 are not the same thing.
The comment that goes with it seems to suggest i386 has short alignment for u64 but my compiler says differently:
printf("%d, %d\n", sizeof(unsigned long long), __alignof__(unsigned long long));
$ gcc -m32 -o align align.c && ./align 8, 8
| |