This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

How to guarantee alignment for .comm and .lcomm defined variables


Some platforms like interix and cygwin do not support the third argument to .comm/.lcomm which enables alignment of common variables defined in .bss section. Now i want to understand how we can guarantee that the object code generated would have these symbols aligned at lets say 16 byte boundary.
s_lcomm_internal takes a parameter needs_align and based on whether the third parameter was entered, records the largest alignment requested for .bss section. I did not see how guaranteeing the alignment of the .bss section for the largest alignment would also take care of the alignment requirement of symbols defined in .bss.

could somebody shed some light here?
How does other platforms implement the alignment for symbols defined in .bss section.

Thanks and regards
Mayank


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]