From: simonmar Date: Mon, 11 Apr 2005 09:50:18 +0000 (+0000) Subject: [project @ 2005-04-11 09:50:18 by simonmar] X-Git-Tag: Initial_conversion_from_CVS_complete~764 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=a6f9b43aa7e032e97725b09efff2241181ebbc94;p=ghc-hetmet.git [project @ 2005-04-11 09:50:18 by simonmar] Fix i386 breakage --- diff --git a/ghc/compiler/nativeGen/MachCodeGen.hs b/ghc/compiler/nativeGen/MachCodeGen.hs index d911c24..4fda4ee 100644 --- a/ghc/compiler/nativeGen/MachCodeGen.hs +++ b/ghc/compiler/nativeGen/MachCodeGen.hs @@ -1996,12 +1996,14 @@ getAmode other #if i386_TARGET_ARCH || x86_64_TARGET_ARCH getNonClobberedOperand :: CmmExpr -> NatM (Operand, InstrBlock) +#if x86_64_TARGET_ARCH getNonClobberedOperand (CmmLit lit) | isSuitableFloatingPointLit lit = do lbl <- getNewLabelNat let code = unitOL (LDATA ReadOnlyData [CmmDataLabel lbl, CmmStaticLit lit]) return (OpAddr (ripRel (ImmCLbl lbl)), code) +#endif getNonClobberedOperand (CmmLit lit) | not (is64BitLit lit) && not (isFloatingRep (cmmLitRep lit)) = return (OpImm (litToImm lit), nilOL) @@ -2030,12 +2032,14 @@ regClobbered _ = False -- getOperand: the operand is not required to remain valid across the -- computation of an arbitrary expression. getOperand :: CmmExpr -> NatM (Operand, InstrBlock) +#if x86_64_TARGET_ARCH getOperand (CmmLit lit) | isSuitableFloatingPointLit lit = do lbl <- getNewLabelNat let code = unitOL (LDATA ReadOnlyData [CmmDataLabel lbl, CmmStaticLit lit]) return (OpAddr (ripRel (ImmCLbl lbl)), code) +#endif getOperand (CmmLit lit) | not (is64BitLit lit) && not (isFloatingRep (cmmLitRep lit)) = do return (OpImm (litToImm lit), nilOL)