[Haskell-cafe] Is this a known problem?
ok at cs.otago.ac.nz
Thu Oct 4 18:04:06 EDT 2007
UltraSPARC II, Solaris 2.10, gcc 4.0.4 (gccfss),
Haskell GHC 6.6.1 binary release.
Trying to compile a simple file gives me oodles of errors because
ghc is generating something that makes gcc generate lots of these:
sethi %hi(<<some register>>),<<another register>>
For people unfamiliar with SPARC assembly code, the %hi(...) operation
returns the top bits of a *literal* address, it makes absolutely no
sense to give it a register.
I have tried this version of gccfss with lots of C code and have been
unable to make it generate this construction; it's only ghc's .hc files
that do it.
Running gcc by hand on the .hc file produces 8 warnings
...lib/ghc-6.6.1/include/Regs.h: ###: warning:
call-clobbered register used for global register variable
-DNO_GLOBAL_REG_DECLS eliminated that.
Comparing the .s file produced using 'ghc -S' with the .s file
produced by gcc'ing the .hc produced some illumination:
What with one thing and another, I'm not really sure that it's
More information about the Haskell-Cafe