[GHC] #709: "Fixup too large" error with -fasm on PowerPC
GHC
cvs-ghc at haskell.org
Tue Dec 4 02:34:25 CET 2012
#709: "Fixup too large" error with -fasm on PowerPC
----------------------------------+-----------------------------------------
Reporter: simonmar | Owner:
Type: bug | Status: new
Priority: low | Milestone: 6.8.1
Component: Compiler (NCG) | Version: 7.7
Resolution: | Keywords:
Os: Unknown/Multiple | Architecture: powerpc
Failure: Building GHC failed | Difficulty: Moderate (less than a day)
Testcase: | Blockedby:
Blocking: | Related:
----------------------------------+-----------------------------------------
Changes (by PHO):
* cc: pho@… (added)
* failure: => Building GHC failed
* status: closed => new
* resolution: fixed =>
* version: 6.4.1 => 7.7
Comment:
The problem has recurred in HEAD:
{{{
"inplace/bin/ghc-stage1" -static -prof -H32m -O -package-name
time-1.4.0.2 -hide-all-packages -i -ilibraries/time/. -ilibraries/time
/dist-install/build -ilibraries/time/dist-install/build/autogen
-Ilibraries/time/dist-install/build -Ilibraries/time/dist-
install/build/autogen -Ilibraries/time/include -optP-
DLANGUAGE_Rank2Types -optP-DLANGUAGE_DeriveDataTypeable -optP-
DLANGUAGE_StandaloneDeriving -optP-include -optPlibraries/time/dist-
install/build/autogen/cabal_macros.h -package base-4.7.0.0 -package
deepseq-1.3.0.2 -package old-locale-1.0.0.5 -Wall -XHaskell2010
-XRank2Types -XDeriveDataTypeable -XStandaloneDeriving -XCPP -O2 -no-
user-package-db -rtsopts -odir libraries/time/dist-install/build
-hidir libraries/time/dist-install/build -stubdir libraries/time/dist-
install/build -hisuf p_hi -osuf p_o -hcsuf p_hc -c
libraries/time/./Data/Time/Format.hs -o libraries/time/dist-
install/build/Data/Time/Format.p_o
/var/folders/rN/rNbpGijHEzGPi-
Ux2JwMgU+++TI/-Tmp-/ghc78514_0/ghc78514_0.s:104514:0:
Fixup of -33272 too large for field width of 16 bits
/var/folders/rN/rNbpGijHEzGPi-
Ux2JwMgU+++TI/-Tmp-/ghc78514_0/ghc78514_0.s:104498:0:
Fixup of -33636 too large for field width of 16 bits
/var/folders/rN/rNbpGijHEzGPi-
Ux2JwMgU+++TI/-Tmp-/ghc78514_0/ghc78514_0.s:94635:0:
Fixup of 33240 too large for field width of 16 bits
/var/folders/rN/rNbpGijHEzGPi-
Ux2JwMgU+++TI/-Tmp-/ghc78514_0/ghc78514_0.s:94632:0:
Fixup of 33316 too large for field width of 16 bits
/var/folders/rN/rNbpGijHEzGPi-
Ux2JwMgU+++TI/-Tmp-/ghc78514_0/ghc78514_0.s:94629:0:
Fixup of 33392 too large for field width of 16 bits
/var/folders/rN/rNbpGijHEzGPi-
Ux2JwMgU+++TI/-Tmp-/ghc78514_0/ghc78514_0.s:94547:0:
Fixup of 33504 too large for field width of 16 bits
/var/folders/rN/rNbpGijHEzGPi-
Ux2JwMgU+++TI/-Tmp-/ghc78514_0/ghc78514_0.s:94486:0:
Fixup of 33640 too large for field width of 16 bits
}}}
I found it was triggered by an extremely large function with lots of info
tables. While {{{AsmCodeGen.makeFarBranches}}} tries to transform
problematic {{{PPC.Instr.BCC}}} to {{{PPC.Instr.BCCFAR}}}, it
underestimates the maximum number of instructions to jump over as it
doesn't take account of the presence of info tables.
Here is my
[https://github.com/phonohawk/ghc/commit/df7b8799b1f008dbcebff0a8566331f298e1bbe1
patch] to work around:
{{{
% git fetch http://github.com/phonohawk/ghc.git ticket-709
}}}
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/709#comment:7>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the Glasgow-haskell-bugs
mailing list