This is the mail archive of the gcc-bugs@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]

[Bug fortran/13240] [g77] wrong alignment of automatic adjustable DOUBLE PRECISION array


------- Additional Comments From gcc-bug at vogtner dot de  2003-11-30 21:20 -------
This is hard to believe! I have modified the program. The mis-alignment only
occurs, if adjustable arrays are used. I don't think that #10395 applies here.

#> g77 -malign-double g77-3.3.2-misaligned-dp-array-bug-1.f 
#> a.out 
08049D20
0A049D20
0C049D20
ADDRESS OF DBLE : BFFFF548 <-- scalar dp variable: OK
ADDRESS OF DBLE : BFFFF520 <-- automatic array (fixed size): OK
ADDRESS OF DBLE : BFFFE4FC <-- adjustable array: mis-aligned
ADDRESS OF DBLE : BFDFE4FC <-- adjustable array: mis-aligned

now:

#> g77 -malign-double -mpreferred-stack-boundary=3
g77-3.3.2-misaligned-dp-array-bug-1.f 
#> a.out 
08049D40
0A049D40
0C049D40
ADDRESS OF DBLE : BFFFF550
ADDRESS OF DBLE : BFFFF530
ADDRESS OF DBLE : BFFFE510 <-- OK
ADDRESS OF DBLE : BFDFE500 <-- OK

and also ok is preferred stack boundary of 2.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |UNCONFIRMED
         Resolution|DUPLICATE                   |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13240


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