Closed GoogleCodeExporter closed 8 years ago
the test runs if built with -fno-common (which is also required on
hppa*-*-hpux* and
*-*-darwin* targets). however, should probably investigate why ...
Original comment by jmoc...@gmail.com
on 9 Feb 2009 at 10:30
problem was wrong definition with ASM_OUTPUT_ALIGNED_COMMON, which failed to
align
common symbols required by these testcases. removed in favour of
ASM_OUTPUT_COMMON,
since SX assembler syntax does not really allow for aligned comm symbols.
fixed with r222.
Original comment by jmoc...@gmail.com
on 9 Feb 2009 at 2:33
note that you will also need r187 of binutils, which provides an updated linker
script that aligns BSS to 16 bytes (previously 8 bytes).
namely: if the linker aligns BSS start to 8 bytes, it is beyond the power of the
compiler to align any symbol therein to a larger boundary, no matter how it
rearranges the symbols inside a single object file's BSS.
Original comment by jmoc...@gmail.com
on 9 Feb 2009 at 2:38
this seems to have resurfaced with r257/r193. works with -fno-common, fails
otherwise.
Original comment by jmoc...@gmail.com
on 9 Mar 2009 at 11:34
this was caused by r251:
----
Index: sx.h
===================================================================
--- sx.h (revision 250)
+++ sx.h (revision 251)
@@ -108,6 +108,7 @@
right after the prologue. The default is __main (glibc alike),
for SuperUX compatibility we change this to _main */
#define NAME__MAIN "_main"
+#define SYMBOL__MAIN _main
#define CPP_SPEC \
"%{.c: -D_FLOAT0 -D_LONG64}"
----
the problem is that we should call superux initializer function (i.e. _main from
superux startup files) in main. #defining SYMBOL__MAIN redirects this call to
libgcc2.
otoh, call to libgcc2 startup routine is also needed, as it will run global
contructors. so we need to run both and thus need to find a way how to run them
both.
Original comment by jmoc...@gmail.com
on 9 Mar 2009 at 1:39
fixed with binutils r194 aligning subsections of data and bss sections to 16
bytes.
gcc r251 just exposed the bug due to a bit different memory layout.
Original comment by jmoc...@gmail.com
on 9 Mar 2009 at 3:10
Original issue reported on code.google.com by
jmoc...@gmail.com
on 9 Feb 2009 at 10:01