diff options
Diffstat (limited to 'compiler/GHC/CmmToLlvm/Data.hs')
-rw-r--r-- | compiler/GHC/CmmToLlvm/Data.hs | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/compiler/GHC/CmmToLlvm/Data.hs b/compiler/GHC/CmmToLlvm/Data.hs index b32f619640..ac155179d1 100644 --- a/compiler/GHC/CmmToLlvm/Data.hs +++ b/compiler/GHC/CmmToLlvm/Data.hs @@ -17,7 +17,6 @@ import GHC.CmmToLlvm.Base import GHC.Cmm.BlockId import GHC.Cmm.CLabel import GHC.Cmm -import GHC.Driver.Session import GHC.Platform import GHC.Data.FastString @@ -71,7 +70,7 @@ genLlvmData (sec, CmmStaticsRaw lbl xs) = do label <- strCLabel_llvm lbl static <- mapM genData xs lmsec <- llvmSection sec - platform <- getLlvmPlatform + platform <- getPlatform let types = map getStatType static strucTy = LMStruct types @@ -113,9 +112,9 @@ llvmSectionType p t = case t of -- | Format a Cmm Section into a LLVM section name llvmSection :: Section -> LlvmM LMSection llvmSection (Section t suffix) = do - dflags <- getDynFlags - let splitSect = gopt Opt_SplitSections dflags - platform = targetPlatform dflags + opts <- getLlvmOpts + let splitSect = llvmOptsSplitSections opts + platform = llvmOptsPlatform opts if not splitSect then return Nothing else do |