-
Simon Marlow authored
GHCi staggers to its feet on x86_64. The problem is that in the small code model on x86_64, all symbol relocations are 32-bit, because the program is assumed to fit into 2Gb. However, shared libraries are linked outside the 2Gb range, and the linker arranges that references to shared library symbols either go via a jump table (for code references) or are copied into the 2Gb area (for data references). In GHCi's linker, We can use a jump table for the function symbols, but we can't copy the data symbols because they've already been relocated to point to the shared library. What's more, we can't tell whether a symbol reference is to code or data - this information is only available from the shared library itself. Fortunately, at least HSbase.o doesn't have any data references to shared libraries (at least on the Linux distro I'm using), so I can at least get GHCi up and limping.
0af6ff59