Alignment of object code

Clark L. Coleman clc5q@cobra.cs.Virginia.EDU
Wed Dec 22 15:33:00 GMT 1999


As part of my research, I have a program that has code sections that
really need to be aligned on certain boundaries. Is there any way in
gcc, including the use of inline assembler, to cause the alignment of
code on really big boundaries, such as 4KB or 16KB?

I am considering writing an awk program to process the assmebly output
of the compiler and insert directives, but they are machine-dependent,
of course. I also know of another possible workaround, but I am hoping
for a straightforward #pragma or similar solution. Thanks for any
help.

(Yes, I really do need to do this; no, I really don't want to explain
why; yes, I really do know what I am doing, etc., etc., so please
don't ask or try to persuade me otherwise. Thanks.)



More information about the Gcc-help mailing list