diff options
| author | wolfgang <unknown> | 2004-09-27 17:43:47 +0000 |
|---|---|---|
| committer | wolfgang <unknown> | 2004-09-27 17:43:47 +0000 |
| commit | b4639cb249f2f904eb78271d0bdedbd90ceb7216 (patch) | |
| tree | e2c3b4d692d9c68218a8cb7a158601f2487f0607 /ghc | |
| parent | c9aeb3c625b2a472270762d4c5896614cf886d53 (diff) | |
| download | haskell-b4639cb249f2f904eb78271d0bdedbd90ceb7216.tar.gz | |
[project @ 2004-09-27 17:43:47 by wolfgang]
Mac OS X: Fix an incorrect ASSERT
Merge to STABLE
Diffstat (limited to 'ghc')
| -rw-r--r-- | ghc/rts/Linker.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ghc/rts/Linker.c b/ghc/rts/Linker.c index 891cf13731..7924913624 100644 --- a/ghc/rts/Linker.c +++ b/ghc/rts/Linker.c @@ -3492,7 +3492,7 @@ static int relocateSection( else if(reloc->r_type == PPC_RELOC_BR24) { word = *wordPtr; - word = (word & 0x03FFFFFC) | (word & 0x02000000) ? 0xFC000000 : 0; + word = (word & 0x03FFFFFC) | ((word & 0x02000000) ? 0xFC000000 : 0); } @@ -3518,7 +3518,9 @@ static int relocateSection( if(reloc->r_pcrel) { - ASSERT(word == 0); + // In the .o file, this should be a relative jump to NULL + // and we'll change it to a jump to a relative jump to the symbol + ASSERT(-word == reloc->r_address); word = symbolAddress; jumpIsland = makeJumpIsland(oc,reloc->r_symbolnum,word); word -= ((long)image) + sect->offset + reloc->r_address; |
