[project @ 2005-07-11 14:21:54 by simonmar]
authorsimonmar <unknown>
Mon, 11 Jul 2005 14:21:54 +0000 (14:21 +0000)
committersimonmar <unknown>
Mon, 11 Jul 2005 14:21:54 +0000 (14:21 +0000)
byte code info tables for x86_64 (same as i386)

ghc/compiler/ghci/ByteCodeItbls.lhs

index 681a462..5cc07d6 100644 (file)
@@ -172,12 +172,15 @@ mkJumpToAddr a =
        0x7D8903A6, 0x4E800420
        ]
 
-#elif i386_TARGET_ARCH
+#elif i386_TARGET_ARCH || x86_64_TARGET_ARCH
 -- Let the address to jump to be 0xWWXXYYZZ.
 -- Generate   movl $0xWWXXYYZZ,%eax  ;  jmp *%eax
 -- which is
 -- B8 ZZ YY XX WW FF E0
 
+-- This works on x86_64 too, because we're assuming the small memory
+-- model, where all symbols fit into the lower 2Gb.
+
 type ItblCode = Word8
 mkJumpToAddr a
    = let w32 = fromIntegral (ptrToInt a)