Alignment of functions
-
28-10-2019 - |
题
How do I make the functions align at 4-byte boundaries with GCC, target 680x0?
-malign-functions=4
does not seem to do the trick, by itself anyway. Some kind of option meant to improve cache performance on 68020 and up perhaps?
解决方案
-malign-functions=4
should do the trick but it can be overridden with the function attribute aligned()
. Make sure that your code doesn't use this (for example with a macro).
其他提示
Try using this:
( Quoted from linux.die )
-m4byte-functions
F-mno-4byte-functions
Force all functions to be aligned to a four byte boundary.
不隶属于 StackOverflow