This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC 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]

Documentation for __aligned__ out of date?


The manual says:

     The `aligned' attribute can only increase the alignment; but you
     can decrease it by specifying `packed' as well.  See below.

But it doesn't seem to behave that way.  The third argument to .comm, below,
is alignment (i686-pc-linux-gnu):

drow@nevyn:/big/codesourcery% echo 'int x __attribute__((__aligned__(1)));' >qqqq.c
drow@nevyn:/big/codesourcery% gcc -S qqqq.c
drow@nevyn:/big/codesourcery% cat qqqq.s
        .file   "qqqq.c"
        .comm   x,4,1
        .section        .note.GNU-stack,"",@progbits
        .ident  "GCC: (GNU) 3.3.4 (Debian 1:3.3.4-2)"

Shouldn't that be x,4,4?  Same thing happens with non-common variables, in
3.3 and HEAD.

-- 
Daniel Jacobowitz


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