From: Andrew Crabtree Message-Id: <199705201614.AA183124895@typhoon.rose.hp.com> Subject: Re: -m486 alignment problem To: eliz AT is DOT elta DOT co DOT il (Eli Zaretskii) Date: Tue, 20 May 1997 9:14:55 PDT Cc: djgpp AT delorie DOT com In-Reply-To: ; from "Eli Zaretskii" at May 20, 97 6:04 pm Precedence: bulk > As far as I remember, gcc and gas indeed disagree on this. DJ reported > this when v2 was in beta, but I don't think it was fixed. I tried compiling the following code bit with gcc and pgcc to see what alignment they would use (they are different). Since old versions of gas used power of 2 aligning, and new versions use byte aligning (so I've been told), it looks like the problem was in the compiler. Of course, I may have my logic reversed here somewhere, but it sounded good when I wrote it. test.c int junk = 1; char more_junk = 2; double db = 4.56; int still_more_junk = 4; regular gcc gives me this .globl _junk .data .align 2 _junk: .long 1 .globl _more_junk _more_junk: .byte 2 .globl _db .align 2 _db: .long 0xa3d70a3d,0x40123d70 .globl _still_more_junk .align 2 _still_more_junk: .long 4 pgcc this .globl _junk .data .align 4 _junk: .long 1 .globl _more_junk _more_junk: .byte 2 .globl _db .align 8 _db: .long 0xa3d70a3d,0x40123d70 .globl _still_more_junk .align 4 _still_more_junk: .long 4