diff options
author | Herbert Valerio Riedel <hvr@gnu.org> | 2017-09-19 14:35:36 -0400 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2017-09-19 14:35:38 -0400 |
commit | f63bc730c7ea42ca6882f8078eb86be8bf1cc6ad (patch) | |
tree | 3273e53bf00121c2a2657a9fe997283300e997e9 /compiler/nativeGen | |
parent | 12a92fedf8b1997f2e26800929be117d54536b7e (diff) | |
download | haskell-f63bc730c7ea42ca6882f8078eb86be8bf1cc6ad.tar.gz |
compiler: introduce custom "GhcPrelude" Prelude
This switches the compiler/ component to get compiled with
-XNoImplicitPrelude and a `import GhcPrelude` is inserted in all
modules.
This is motivated by the upcoming "Prelude" re-export of
`Semigroup((<>))` which would cause lots of name clashes in every
modulewhich imports also `Outputable`
Reviewers: austin, goldfire, bgamari, alanz, simonmar
Reviewed By: bgamari
Subscribers: goldfire, rwbarton, thomie, mpickering, bgamari
Differential Revision: https://phabricator.haskell.org/D3989
Diffstat (limited to 'compiler/nativeGen')
63 files changed, 126 insertions, 0 deletions
diff --git a/compiler/nativeGen/AsmCodeGen.hs b/compiler/nativeGen/AsmCodeGen.hs index 314d726b50..373852a4be 100644 --- a/compiler/nativeGen/AsmCodeGen.hs +++ b/compiler/nativeGen/AsmCodeGen.hs @@ -25,6 +25,8 @@ module AsmCodeGen ( #include "nativeGen/NCG.h" +import GhcPrelude + import qualified X86.CodeGen import qualified X86.Regs import qualified X86.Instr diff --git a/compiler/nativeGen/CPrim.hs b/compiler/nativeGen/CPrim.hs index c52fe10b13..ad61a002d3 100644 --- a/compiler/nativeGen/CPrim.hs +++ b/compiler/nativeGen/CPrim.hs @@ -11,6 +11,8 @@ module CPrim , word2FloatLabel ) where +import GhcPrelude + import CmmType import CmmMachOp import Outputable diff --git a/compiler/nativeGen/Dwarf.hs b/compiler/nativeGen/Dwarf.hs index afeac030fd..b858b7734d 100644 --- a/compiler/nativeGen/Dwarf.hs +++ b/compiler/nativeGen/Dwarf.hs @@ -2,6 +2,8 @@ module Dwarf ( dwarfGen ) where +import GhcPrelude + import CLabel import CmmExpr ( GlobalReg(..) ) import Config ( cProjectName, cProjectVersion ) diff --git a/compiler/nativeGen/Dwarf/Constants.hs b/compiler/nativeGen/Dwarf/Constants.hs index a8034ef295..db5395af35 100644 --- a/compiler/nativeGen/Dwarf/Constants.hs +++ b/compiler/nativeGen/Dwarf/Constants.hs @@ -3,6 +3,8 @@ module Dwarf.Constants where +import GhcPrelude + import AsmUtils import FastString import Platform diff --git a/compiler/nativeGen/Dwarf/Types.hs b/compiler/nativeGen/Dwarf/Types.hs index 95f07151ce..23a2c920e7 100644 --- a/compiler/nativeGen/Dwarf/Types.hs +++ b/compiler/nativeGen/Dwarf/Types.hs @@ -22,6 +22,8 @@ module Dwarf.Types ) where +import GhcPrelude + import Debug import CLabel import CmmExpr ( GlobalReg(..) ) diff --git a/compiler/nativeGen/Format.hs b/compiler/nativeGen/Format.hs index 1e3218517a..82ecbecc14 100644 --- a/compiler/nativeGen/Format.hs +++ b/compiler/nativeGen/Format.hs @@ -20,6 +20,8 @@ module Format ( where +import GhcPrelude + import Cmm import Outputable diff --git a/compiler/nativeGen/Instruction.hs b/compiler/nativeGen/Instruction.hs index 515d4f3d85..63b5b0df7e 100644 --- a/compiler/nativeGen/Instruction.hs +++ b/compiler/nativeGen/Instruction.hs @@ -14,6 +14,8 @@ module Instruction ( where +import GhcPrelude + import Reg import BlockId diff --git a/compiler/nativeGen/NCGMonad.hs b/compiler/nativeGen/NCGMonad.hs index 6af0df5b01..f4d02dae3c 100644 --- a/compiler/nativeGen/NCGMonad.hs +++ b/compiler/nativeGen/NCGMonad.hs @@ -37,6 +37,8 @@ where #include "HsVersions.h" +import GhcPrelude + import Reg import Format import TargetReg diff --git a/compiler/nativeGen/PIC.hs b/compiler/nativeGen/PIC.hs index de1fbaa8d4..165c3a7a44 100644 --- a/compiler/nativeGen/PIC.hs +++ b/compiler/nativeGen/PIC.hs @@ -47,6 +47,8 @@ module PIC ( where +import GhcPrelude + import qualified PPC.Instr as PPC import qualified PPC.Regs as PPC diff --git a/compiler/nativeGen/PPC/CodeGen.hs b/compiler/nativeGen/PPC/CodeGen.hs index 7b898ee6b0..299238b7a5 100644 --- a/compiler/nativeGen/PPC/CodeGen.hs +++ b/compiler/nativeGen/PPC/CodeGen.hs @@ -25,6 +25,8 @@ where #include "../includes/MachDeps.h" -- NCG stuff: +import GhcPrelude + import CodeGen.Platform import PPC.Instr import PPC.Cond diff --git a/compiler/nativeGen/PPC/Cond.hs b/compiler/nativeGen/PPC/Cond.hs index 0e4b1fd701..bd8bdee81a 100644 --- a/compiler/nativeGen/PPC/Cond.hs +++ b/compiler/nativeGen/PPC/Cond.hs @@ -8,6 +8,8 @@ module PPC.Cond ( where +import GhcPrelude + import Panic data Cond diff --git a/compiler/nativeGen/PPC/Instr.hs b/compiler/nativeGen/PPC/Instr.hs index eb179c5a99..d39f0bcff5 100644 --- a/compiler/nativeGen/PPC/Instr.hs +++ b/compiler/nativeGen/PPC/Instr.hs @@ -23,6 +23,8 @@ module PPC.Instr ( where +import GhcPrelude + import PPC.Regs import PPC.Cond import Instruction diff --git a/compiler/nativeGen/PPC/Ppr.hs b/compiler/nativeGen/PPC/Ppr.hs index fe8d9e6484..7f8f407bd8 100644 --- a/compiler/nativeGen/PPC/Ppr.hs +++ b/compiler/nativeGen/PPC/Ppr.hs @@ -9,6 +9,8 @@ {-# OPTIONS_GHC -fno-warn-orphans #-} module PPC.Ppr (pprNatCmmDecl) where +import GhcPrelude + import PPC.Regs import PPC.Instr import PPC.Cond diff --git a/compiler/nativeGen/PPC/RegInfo.hs b/compiler/nativeGen/PPC/RegInfo.hs index c4724d4193..bf894fd42f 100644 --- a/compiler/nativeGen/PPC/RegInfo.hs +++ b/compiler/nativeGen/PPC/RegInfo.hs @@ -20,6 +20,8 @@ where #include "nativeGen/NCG.h" #include "HsVersions.h" +import GhcPrelude + import PPC.Instr import BlockId diff --git a/compiler/nativeGen/PPC/Regs.hs b/compiler/nativeGen/PPC/Regs.hs index 5c7c5aec90..7ebe36f178 100644 --- a/compiler/nativeGen/PPC/Regs.hs +++ b/compiler/nativeGen/PPC/Regs.hs @@ -50,6 +50,8 @@ where #include "nativeGen/NCG.h" #include "HsVersions.h" +import GhcPrelude + import Reg import RegClass import Format diff --git a/compiler/nativeGen/PprBase.hs b/compiler/nativeGen/PprBase.hs index aca427449d..d96b18783d 100644 --- a/compiler/nativeGen/PprBase.hs +++ b/compiler/nativeGen/PprBase.hs @@ -16,6 +16,8 @@ module PprBase ( where +import GhcPrelude + import AsmUtils import CLabel import Cmm diff --git a/compiler/nativeGen/Reg.hs b/compiler/nativeGen/Reg.hs index 598074d881..d9d56d47c4 100644 --- a/compiler/nativeGen/Reg.hs +++ b/compiler/nativeGen/Reg.hs @@ -26,6 +26,8 @@ module Reg ( where +import GhcPrelude + import Outputable import Unique import RegClass diff --git a/compiler/nativeGen/RegAlloc/Graph/ArchBase.hs b/compiler/nativeGen/RegAlloc/Graph/ArchBase.hs index 6771e4ecb9..634e61cb13 100644 --- a/compiler/nativeGen/RegAlloc/Graph/ArchBase.hs +++ b/compiler/nativeGen/RegAlloc/Graph/ArchBase.hs @@ -21,6 +21,8 @@ module RegAlloc.Graph.ArchBase ( bound, squeese ) where +import GhcPrelude + import UniqSet import UniqFM import Unique diff --git a/compiler/nativeGen/RegAlloc/Graph/ArchX86.hs b/compiler/nativeGen/RegAlloc/Graph/ArchX86.hs index 9873118dcf..0472e4cf09 100644 --- a/compiler/nativeGen/RegAlloc/Graph/ArchX86.hs +++ b/compiler/nativeGen/RegAlloc/Graph/ArchX86.hs @@ -15,6 +15,8 @@ module RegAlloc.Graph.ArchX86 ( squeese, ) where +import GhcPrelude + import RegAlloc.Graph.ArchBase (Reg(..), RegSub(..), RegClass(..)) import UniqSet diff --git a/compiler/nativeGen/RegAlloc/Graph/Coalesce.hs b/compiler/nativeGen/RegAlloc/Graph/Coalesce.hs index 832df2334e..0f5cf2dfd8 100644 --- a/compiler/nativeGen/RegAlloc/Graph/Coalesce.hs +++ b/compiler/nativeGen/RegAlloc/Graph/Coalesce.hs @@ -3,6 +3,8 @@ module RegAlloc.Graph.Coalesce ( regCoalesce, slurpJoinMovs ) where +import GhcPrelude + import RegAlloc.Liveness import Instruction import Reg diff --git a/compiler/nativeGen/RegAlloc/Graph/Main.hs b/compiler/nativeGen/RegAlloc/Graph/Main.hs index 08538453f7..a4d1841c93 100644 --- a/compiler/nativeGen/RegAlloc/Graph/Main.hs +++ b/compiler/nativeGen/RegAlloc/Graph/Main.hs @@ -4,6 +4,8 @@ module RegAlloc.Graph.Main ( regAlloc ) where +import GhcPrelude + import qualified GraphColor as Color import RegAlloc.Liveness import RegAlloc.Graph.Spill diff --git a/compiler/nativeGen/RegAlloc/Graph/Spill.hs b/compiler/nativeGen/RegAlloc/Graph/Spill.hs index b86b143f59..02da824cfe 100644 --- a/compiler/nativeGen/RegAlloc/Graph/Spill.hs +++ b/compiler/nativeGen/RegAlloc/Graph/Spill.hs @@ -7,6 +7,8 @@ module RegAlloc.Graph.Spill ( SpillStats(..), accSpillSL ) where +import GhcPrelude + import RegAlloc.Liveness import Instruction import Reg diff --git a/compiler/nativeGen/RegAlloc/Graph/SpillClean.hs b/compiler/nativeGen/RegAlloc/Graph/SpillClean.hs index faef4037c2..50001d7334 100644 --- a/compiler/nativeGen/RegAlloc/Graph/SpillClean.hs +++ b/compiler/nativeGen/RegAlloc/Graph/SpillClean.hs @@ -28,6 +28,8 @@ module RegAlloc.Graph.SpillClean ( cleanSpills ) where +import GhcPrelude + import RegAlloc.Liveness import Instruction import Reg diff --git a/compiler/nativeGen/RegAlloc/Graph/SpillCost.hs b/compiler/nativeGen/RegAlloc/Graph/SpillCost.hs index 9811f1a64b..f603b609df 100644 --- a/compiler/nativeGen/RegAlloc/Graph/SpillCost.hs +++ b/compiler/nativeGen/RegAlloc/Graph/SpillCost.hs @@ -13,6 +13,8 @@ module RegAlloc.Graph.SpillCost ( lifeMapFromSpillCostInfo ) where +import GhcPrelude + import RegAlloc.Liveness import Instruction import RegClass diff --git a/compiler/nativeGen/RegAlloc/Graph/Stats.hs b/compiler/nativeGen/RegAlloc/Graph/Stats.hs index 71956025b0..e3ff226710 100644 --- a/compiler/nativeGen/RegAlloc/Graph/Stats.hs +++ b/compiler/nativeGen/RegAlloc/Graph/Stats.hs @@ -16,6 +16,8 @@ module RegAlloc.Graph.Stats ( #include "nativeGen/NCG.h" +import GhcPrelude + import qualified GraphColor as Color import RegAlloc.Liveness import RegAlloc.Graph.Spill diff --git a/compiler/nativeGen/RegAlloc/Graph/TrivColorable.hs b/compiler/nativeGen/RegAlloc/Graph/TrivColorable.hs index 204de846ae..7774985dce 100644 --- a/compiler/nativeGen/RegAlloc/Graph/TrivColorable.hs +++ b/compiler/nativeGen/RegAlloc/Graph/TrivColorable.hs @@ -8,6 +8,8 @@ where #include "HsVersions.h" +import GhcPrelude + import RegClass import Reg diff --git a/compiler/nativeGen/RegAlloc/Linear/Base.hs b/compiler/nativeGen/RegAlloc/Linear/Base.hs index d4f124e297..1172870729 100644 --- a/compiler/nativeGen/RegAlloc/Linear/Base.hs +++ b/compiler/nativeGen/RegAlloc/Linear/Base.hs @@ -17,6 +17,8 @@ module RegAlloc.Linear.Base ( where +import GhcPrelude + import RegAlloc.Linear.StackMap import RegAlloc.Liveness import Reg diff --git a/compiler/nativeGen/RegAlloc/Linear/FreeRegs.hs b/compiler/nativeGen/RegAlloc/Linear/FreeRegs.hs index 9933f5bb49..b4e79432d8 100644 --- a/compiler/nativeGen/RegAlloc/Linear/FreeRegs.hs +++ b/compiler/nativeGen/RegAlloc/Linear/FreeRegs.hs @@ -9,6 +9,8 @@ module RegAlloc.Linear.FreeRegs ( where +import GhcPrelude + import Reg import RegClass diff --git a/compiler/nativeGen/RegAlloc/Linear/JoinToTargets.hs b/compiler/nativeGen/RegAlloc/Linear/JoinToTargets.hs index c262b2b059..89f496c409 100644 --- a/compiler/nativeGen/RegAlloc/Linear/JoinToTargets.hs +++ b/compiler/nativeGen/RegAlloc/Linear/JoinToTargets.hs @@ -9,6 +9,8 @@ -- module RegAlloc.Linear.JoinToTargets (joinToTargets) where +import GhcPrelude + import RegAlloc.Linear.State import RegAlloc.Linear.Base import RegAlloc.Linear.FreeRegs diff --git a/compiler/nativeGen/RegAlloc/Linear/Main.hs b/compiler/nativeGen/RegAlloc/Linear/Main.hs index c13d02edb8..171ce88ef3 100644 --- a/compiler/nativeGen/RegAlloc/Linear/Main.hs +++ b/compiler/nativeGen/RegAlloc/Linear/Main.hs @@ -102,6 +102,8 @@ module RegAlloc.Linear.Main ( #include "HsVersions.h" +import GhcPrelude + import RegAlloc.Linear.State import RegAlloc.Linear.Base import RegAlloc.Linear.StackMap diff --git a/compiler/nativeGen/RegAlloc/Linear/PPC/FreeRegs.hs b/compiler/nativeGen/RegAlloc/Linear/PPC/FreeRegs.hs index 5d369249c7..581548212a 100644 --- a/compiler/nativeGen/RegAlloc/Linear/PPC/FreeRegs.hs +++ b/compiler/nativeGen/RegAlloc/Linear/PPC/FreeRegs.hs @@ -2,6 +2,8 @@ module RegAlloc.Linear.PPC.FreeRegs where +import GhcPrelude + import PPC.Regs import RegClass import Reg diff --git a/compiler/nativeGen/RegAlloc/Linear/SPARC/FreeRegs.hs b/compiler/nativeGen/RegAlloc/Linear/SPARC/FreeRegs.hs index db4d6ba376..653b2707c9 100644 --- a/compiler/nativeGen/RegAlloc/Linear/SPARC/FreeRegs.hs +++ b/compiler/nativeGen/RegAlloc/Linear/SPARC/FreeRegs.hs @@ -3,6 +3,8 @@ module RegAlloc.Linear.SPARC.FreeRegs where +import GhcPrelude + import SPARC.Regs import RegClass import Reg diff --git a/compiler/nativeGen/RegAlloc/Linear/StackMap.hs b/compiler/nativeGen/RegAlloc/Linear/StackMap.hs index 748fb98c30..95819c6fb3 100644 --- a/compiler/nativeGen/RegAlloc/Linear/StackMap.hs +++ b/compiler/nativeGen/RegAlloc/Linear/StackMap.hs @@ -20,6 +20,8 @@ module RegAlloc.Linear.StackMap ( where +import GhcPrelude + import DynFlags import UniqFM import Unique diff --git a/compiler/nativeGen/RegAlloc/Linear/State.hs b/compiler/nativeGen/RegAlloc/Linear/State.hs index 8b17d3ab88..6554188f41 100644 --- a/compiler/nativeGen/RegAlloc/Linear/State.hs +++ b/compiler/nativeGen/RegAlloc/Linear/State.hs @@ -31,6 +31,8 @@ module RegAlloc.Linear.State ( ) where +import GhcPrelude + import RegAlloc.Linear.Stats import RegAlloc.Linear.StackMap import RegAlloc.Linear.Base diff --git a/compiler/nativeGen/RegAlloc/Linear/Stats.hs b/compiler/nativeGen/RegAlloc/Linear/Stats.hs index 71dedaeb55..66fd8742ba 100644 --- a/compiler/nativeGen/RegAlloc/Linear/Stats.hs +++ b/compiler/nativeGen/RegAlloc/Linear/Stats.hs @@ -6,6 +6,8 @@ module RegAlloc.Linear.Stats ( where +import GhcPrelude + import RegAlloc.Linear.Base import RegAlloc.Liveness import Instruction diff --git a/compiler/nativeGen/RegAlloc/Linear/X86/FreeRegs.hs b/compiler/nativeGen/RegAlloc/Linear/X86/FreeRegs.hs index ae4aa53254..65a566d1c3 100644 --- a/compiler/nativeGen/RegAlloc/Linear/X86/FreeRegs.hs +++ b/compiler/nativeGen/RegAlloc/Linear/X86/FreeRegs.hs @@ -3,6 +3,8 @@ module RegAlloc.Linear.X86.FreeRegs where +import GhcPrelude + import X86.Regs import RegClass import Reg diff --git a/compiler/nativeGen/RegAlloc/Linear/X86_64/FreeRegs.hs b/compiler/nativeGen/RegAlloc/Linear/X86_64/FreeRegs.hs index 5a7f71e3f0..713b053356 100644 --- a/compiler/nativeGen/RegAlloc/Linear/X86_64/FreeRegs.hs +++ b/compiler/nativeGen/RegAlloc/Linear/X86_64/FreeRegs.hs @@ -3,6 +3,8 @@ module RegAlloc.Linear.X86_64.FreeRegs where +import GhcPrelude + import X86.Regs import RegClass import Reg diff --git a/compiler/nativeGen/RegAlloc/Liveness.hs b/compiler/nativeGen/RegAlloc/Liveness.hs index e66139786b..db09b0e994 100644 --- a/compiler/nativeGen/RegAlloc/Liveness.hs +++ b/compiler/nativeGen/RegAlloc/Liveness.hs @@ -35,6 +35,8 @@ module RegAlloc.Liveness ( regLiveness, natCmmTopToLive ) where +import GhcPrelude + import Reg import Instruction diff --git a/compiler/nativeGen/RegClass.hs b/compiler/nativeGen/RegClass.hs index 0c793173cb..cd008bbbb1 100644 --- a/compiler/nativeGen/RegClass.hs +++ b/compiler/nativeGen/RegClass.hs @@ -4,6 +4,8 @@ module RegClass where +import GhcPrelude + import Outputable import Unique diff --git a/compiler/nativeGen/SPARC/AddrMode.hs b/compiler/nativeGen/SPARC/AddrMode.hs index bf4d480005..ee40843351 100644 --- a/compiler/nativeGen/SPARC/AddrMode.hs +++ b/compiler/nativeGen/SPARC/AddrMode.hs @@ -6,6 +6,8 @@ module SPARC.AddrMode ( where +import GhcPrelude + import SPARC.Imm import SPARC.Base import Reg diff --git a/compiler/nativeGen/SPARC/Base.hs b/compiler/nativeGen/SPARC/Base.hs index a57d5e1c9a..04e8fed2b3 100644 --- a/compiler/nativeGen/SPARC/Base.hs +++ b/compiler/nativeGen/SPARC/Base.hs @@ -18,6 +18,8 @@ module SPARC.Base ( where +import GhcPrelude + import DynFlags import Panic diff --git a/compiler/nativeGen/SPARC/CodeGen.hs b/compiler/nativeGen/SPARC/CodeGen.hs index 902a5aea43..1a7fbeb54d 100644 --- a/compiler/nativeGen/SPARC/CodeGen.hs +++ b/compiler/nativeGen/SPARC/CodeGen.hs @@ -22,6 +22,8 @@ where #include "../includes/MachDeps.h" -- NCG stuff: +import GhcPrelude + import SPARC.Base import SPARC.CodeGen.Sanity import SPARC.CodeGen.Amode diff --git a/compiler/nativeGen/SPARC/CodeGen/Amode.hs b/compiler/nativeGen/SPARC/CodeGen/Amode.hs index a59287f171..33e3f535da 100644 --- a/compiler/nativeGen/SPARC/CodeGen/Amode.hs +++ b/compiler/nativeGen/SPARC/CodeGen/Amode.hs @@ -4,6 +4,8 @@ module SPARC.CodeGen.Amode ( where +import GhcPrelude + import {-# SOURCE #-} SPARC.CodeGen.Gen32 import SPARC.CodeGen.Base import SPARC.AddrMode diff --git a/compiler/nativeGen/SPARC/CodeGen/Base.hs b/compiler/nativeGen/SPARC/CodeGen/Base.hs index 27b533f46b..039bb6496c 100644 --- a/compiler/nativeGen/SPARC/CodeGen/Base.hs +++ b/compiler/nativeGen/SPARC/CodeGen/Base.hs @@ -13,6 +13,8 @@ module SPARC.CodeGen.Base ( where +import GhcPrelude + import SPARC.Instr import SPARC.Cond import SPARC.AddrMode diff --git a/compiler/nativeGen/SPARC/CodeGen/CondCode.hs b/compiler/nativeGen/SPARC/CodeGen/CondCode.hs index e5fb82df4d..e6b2e174b6 100644 --- a/compiler/nativeGen/SPARC/CodeGen/CondCode.hs +++ b/compiler/nativeGen/SPARC/CodeGen/CondCode.hs @@ -6,6 +6,8 @@ module SPARC.CodeGen.CondCode ( where +import GhcPrelude + import {-# SOURCE #-} SPARC.CodeGen.Gen32 import SPARC.CodeGen.Base import SPARC.Instr diff --git a/compiler/nativeGen/SPARC/CodeGen/Expand.hs b/compiler/nativeGen/SPARC/CodeGen/Expand.hs index 70cb0111c0..cf861df77a 100644 --- a/compiler/nativeGen/SPARC/CodeGen/Expand.hs +++ b/compiler/nativeGen/SPARC/CodeGen/Expand.hs @@ -5,6 +5,8 @@ module SPARC.CodeGen.Expand ( where +import GhcPrelude + import SPARC.Instr import SPARC.Imm import SPARC.AddrMode diff --git a/compiler/nativeGen/SPARC/CodeGen/Gen32.hs b/compiler/nativeGen/SPARC/CodeGen/Gen32.hs index a0e86f14c4..a7a1f60416 100644 --- a/compiler/nativeGen/SPARC/CodeGen/Gen32.hs +++ b/compiler/nativeGen/SPARC/CodeGen/Gen32.hs @@ -6,6 +6,8 @@ module SPARC.CodeGen.Gen32 ( where +import GhcPrelude + import SPARC.CodeGen.CondCode import SPARC.CodeGen.Amode import SPARC.CodeGen.Gen64 diff --git a/compiler/nativeGen/SPARC/CodeGen/Gen64.hs b/compiler/nativeGen/SPARC/CodeGen/Gen64.hs index f186d437d0..8549fa07ee 100644 --- a/compiler/nativeGen/SPARC/CodeGen/Gen64.hs +++ b/compiler/nativeGen/SPARC/CodeGen/Gen64.hs @@ -7,6 +7,8 @@ module SPARC.CodeGen.Gen64 ( where +import GhcPrelude + import {-# SOURCE #-} SPARC.CodeGen.Gen32 import SPARC.CodeGen.Base import SPARC.CodeGen.Amode diff --git a/compiler/nativeGen/SPARC/CodeGen/Sanity.hs b/compiler/nativeGen/SPARC/CodeGen/Sanity.hs index 81641326f2..fcf5b65bde 100644 --- a/compiler/nativeGen/SPARC/CodeGen/Sanity.hs +++ b/compiler/nativeGen/SPARC/CodeGen/Sanity.hs @@ -6,6 +6,8 @@ module SPARC.CodeGen.Sanity ( where +import GhcPrelude + import SPARC.Instr import SPARC.Ppr () import Instruction diff --git a/compiler/nativeGen/SPARC/Cond.hs b/compiler/nativeGen/SPARC/Cond.hs index da41457950..3fbfb8603f 100644 --- a/compiler/nativeGen/SPARC/Cond.hs +++ b/compiler/nativeGen/SPARC/Cond.hs @@ -7,6 +7,8 @@ module SPARC.Cond ( where +import GhcPrelude + -- | Branch condition codes. data Cond = ALWAYS diff --git a/compiler/nativeGen/SPARC/Imm.hs b/compiler/nativeGen/SPARC/Imm.hs index cb53ba411c..15acf41a50 100644 --- a/compiler/nativeGen/SPARC/Imm.hs +++ b/compiler/nativeGen/SPARC/Imm.hs @@ -7,6 +7,8 @@ module SPARC.Imm ( where +import GhcPrelude + import Cmm import CLabel diff --git a/compiler/nativeGen/SPARC/Instr.hs b/compiler/nativeGen/SPARC/Instr.hs index 4c19ac69a7..54fb513478 100644 --- a/compiler/nativeGen/SPARC/Instr.hs +++ b/compiler/nativeGen/SPARC/Instr.hs @@ -25,6 +25,8 @@ module SPARC.Instr ( where +import GhcPrelude + import SPARC.Stack import SPARC.Imm import SPARC.AddrMode diff --git a/compiler/nativeGen/SPARC/Ppr.hs b/compiler/nativeGen/SPARC/Ppr.hs index 1e4d5c535d..eb401fff06 100644 --- a/compiler/nativeGen/SPARC/Ppr.hs +++ b/compiler/nativeGen/SPARC/Ppr.hs @@ -25,6 +25,8 @@ where #include "HsVersions.h" #include "nativeGen/NCG.h" +import GhcPrelude + import SPARC.Regs import SPARC.Instr import SPARC.Cond diff --git a/compiler/nativeGen/SPARC/Regs.hs b/compiler/nativeGen/SPARC/Regs.hs index 188f66e482..544e4488a9 100644 --- a/compiler/nativeGen/SPARC/Regs.hs +++ b/compiler/nativeGen/SPARC/Regs.hs @@ -32,6 +32,8 @@ module SPARC.Regs ( where +import GhcPrelude + import CodeGen.Platform.SPARC import Reg import RegClass diff --git a/compiler/nativeGen/SPARC/ShortcutJump.hs b/compiler/nativeGen/SPARC/ShortcutJump.hs index 0bbcc48f94..0df280095b 100644 --- a/compiler/nativeGen/SPARC/ShortcutJump.hs +++ b/compiler/nativeGen/SPARC/ShortcutJump.hs @@ -8,6 +8,8 @@ module SPARC.ShortcutJump ( where +import GhcPrelude + import SPARC.Instr import SPARC.Imm diff --git a/compiler/nativeGen/SPARC/Stack.hs b/compiler/nativeGen/SPARC/Stack.hs index 629b18789f..3f5b2a7289 100644 --- a/compiler/nativeGen/SPARC/Stack.hs +++ b/compiler/nativeGen/SPARC/Stack.hs @@ -7,6 +7,8 @@ module SPARC.Stack ( where +import GhcPrelude + import SPARC.AddrMode import SPARC.Regs import SPARC.Base diff --git a/compiler/nativeGen/TargetReg.hs b/compiler/nativeGen/TargetReg.hs index a298cccaf6..6800b9043b 100644 --- a/compiler/nativeGen/TargetReg.hs +++ b/compiler/nativeGen/TargetReg.hs @@ -21,6 +21,8 @@ where #include "HsVersions.h" +import GhcPrelude + import Reg import RegClass import Format diff --git a/compiler/nativeGen/X86/CodeGen.hs b/compiler/nativeGen/X86/CodeGen.hs index 49631066ca..e62906d125 100644 --- a/compiler/nativeGen/X86/CodeGen.hs +++ b/compiler/nativeGen/X86/CodeGen.hs @@ -30,6 +30,8 @@ where #include "../includes/MachDeps.h" -- NCG stuff: +import GhcPrelude + import X86.Instr import X86.Cond import X86.Regs diff --git a/compiler/nativeGen/X86/Cond.hs b/compiler/nativeGen/X86/Cond.hs index 586dabd8f4..35cbf943e1 100644 --- a/compiler/nativeGen/X86/Cond.hs +++ b/compiler/nativeGen/X86/Cond.hs @@ -8,6 +8,8 @@ module X86.Cond ( where +import GhcPrelude + data Cond = ALWAYS -- What's really used? ToDo | EQQ diff --git a/compiler/nativeGen/X86/Instr.hs b/compiler/nativeGen/X86/Instr.hs index 71f50e9d2a..1bb682ad87 100644 --- a/compiler/nativeGen/X86/Instr.hs +++ b/compiler/nativeGen/X86/Instr.hs @@ -17,6 +17,8 @@ where #include "HsVersions.h" #include "nativeGen/NCG.h" +import GhcPrelude + import X86.Cond import X86.Regs import Instruction diff --git a/compiler/nativeGen/X86/Ppr.hs b/compiler/nativeGen/X86/Ppr.hs index 8f9fe9be39..84ce7516b5 100644 --- a/compiler/nativeGen/X86/Ppr.hs +++ b/compiler/nativeGen/X86/Ppr.hs @@ -23,6 +23,8 @@ where #include "HsVersions.h" #include "nativeGen/NCG.h" +import GhcPrelude + import X86.Regs import X86.Instr import X86.Cond diff --git a/compiler/nativeGen/X86/RegInfo.hs b/compiler/nativeGen/X86/RegInfo.hs index 4dfe0350d4..226441b16f 100644 --- a/compiler/nativeGen/X86/RegInfo.hs +++ b/compiler/nativeGen/X86/RegInfo.hs @@ -9,6 +9,8 @@ where #include "nativeGen/NCG.h" #include "HsVersions.h" +import GhcPrelude + import Format import Reg diff --git a/compiler/nativeGen/X86/Regs.hs b/compiler/nativeGen/X86/Regs.hs index c81850c736..169d4020a0 100644 --- a/compiler/nativeGen/X86/Regs.hs +++ b/compiler/nativeGen/X86/Regs.hs @@ -48,6 +48,8 @@ where #include "nativeGen/NCG.h" #include "HsVersions.h" +import GhcPrelude + import CodeGen.Platform import Reg import RegClass |