Mike,
One other observation. The only differences in the .s
output for compiling...
program test
integer i
common i
end
...with -m32 and -m64 is...
--- assign_m32.s 2006-08-19 10:53:33.000000000 -0400
+++ assign_m64.s 2006-08-19 10:53:59.000000000 -0400
@@ -1,10 +1,11 @@
- .machine ppc
+ .machine ppc64
.stabs "/Users/howarth/",100,0,7,Ltext0
.stabs "assign.f90",100,0,7,Ltext0
.text
Ltext0:
.stabs "gcc2_compiled.",60,0,0,0
.align 2
+ .p2align 4,,15
.globl _MAIN__
_MAIN__:
.stabd 68,0,3
@@ -35,11 +36,11 @@
mflr r11
addis r11,r11,ha16(L__gfortran_set_std$lazy_ptr-"L00000000001$spb")
mtlr r0
- lwzu r12,lo16(L__gfortran_set_std$lazy_ptr-"L00000000001$spb")(r11)
+ ldu r12,lo16(L__gfortran_set_std$lazy_ptr-"L00000000001$spb")(r11)
mtctr r12
bctr
.lazy_symbol_pointer
L__gfortran_set_std$lazy_ptr:
.indirect_symbol __gfortran_set_std
- .long dyld_stub_binding_helper
+ .quad dyld_stub_binding_helper
.subsections_via_symbols
...so even if "i" were being optimized away only ld64 seems to care.
The ld 32-bit linker remains silent on the issue.
Jack