Re: Function pointer alignment

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Dec 22, 2017 at 1:28 PM, Geert Uytterhoeven
<geert@xxxxxxxxxxxxxx> wrote:
> On Fri, Dec 22, 2017 at 4:55 AM, Matthew Wilcox <willy@xxxxxxxxxxxxx> wrote:
>> What alignment can we rely on for function pointers?
>>
>> Most architectures seem to have settled on 4-byte aligned instructions.
>>
>> While x86 is only byte-aligned, at least x86-64 aligns functions on a
>> 16-byte boundary.  I know s390 has 2-byte alignment on instructions,
>> but does it have greater alignment on functions?
>>
>> The three architectures with function descriptors (parisc, ia64, ppc64)
>> all seem like they'll be 8-byte aligned.
>>
>> (I'm looking to steal the bottom two bits of a function pointer, so
>> that's where my interest comes from).
>
> Only one bit to steal on m68k...

Same on SH.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds



[Index of Archives]     [Linux Kernel]     [Kernel Newbies]     [x86 Platform Driver]     [Netdev]     [Linux Wireless]     [Netfilter]     [Bugtraq]     [Linux Filesystems]     [Yosemite Discussion]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]

  Powered by Linux