This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/37216] [cygming] Invalid alignment for SSE store to .comm data generated with -O3
- From: "dannysmith at users dot sourceforge dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 6 Oct 2008 20:18:01 -0000
- Subject: [Bug target/37216] [cygming] Invalid alignment for SSE store to .comm data generated with -O3
- References: <bug-37216-16627@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #41 from dannysmith at users dot sourceforge dot net 2008-10-06 20:18 -------
(In reply to comment #35)
> As I suspected. The PE/COFF file format does not provide for specifying
> the alignment of commons.
>
> Hmm, I wonder if gcc should complain if it finds aligned commons with
> COFF backends or if we should try to generate a GNU extension to the
> COFF format.
>
Aligned commons are not part of the PE COFF spec and AFAICT neither MASM nor
NASM provide a way to specify aligned commons. I am afraid that a GNU
extension will cause object incompatibility, so it would it need to be a
non-default option. We already have
-fno-common
__attribute__((no_common))
#pragma gcc optimize (no_common)
G++ already puts commons in .bss
Perhaps a new option -fno_large_common that applies -fcommon only to objects
with align <= 4 bytes?
A warning would be useful in any case.
Danny
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37216