Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
30e7b73a
Commit
30e7b73a
authored
Oct 09, 2012
by
ian@well-typed.com
Browse files
Make -fsimple-list-literals a dynamic flag
parent
1255ff1c
Changes
4
Hide whitespace changes
Inline
Side-by-side
compiler/deSugar/DsExpr.lhs
View file @
30e7b73a
...
...
@@ -40,7 +40,6 @@ import CoreFVs
import MkCore
import DynFlags
import StaticFlags
import CostCentre
import Id
import VarSet
...
...
@@ -688,8 +687,8 @@ dsExplicitList elt_ty xs
= do { dflags <- getDynFlags
; xs' <- mapM dsLExpr xs
; let (dynamic_prefix, static_suffix) = spanTail is_static xs'
; if
o
pt_SimpleListLiterals
-- -fsimple-list-literals
|| not (dopt Opt_EnableRewriteRules dflags)
-- Rewrite rules off
; if
dopt O
pt_SimpleListLiterals
dflags
-- -fsimple-list-literals
|| not (dopt Opt_EnableRewriteRules dflags) -- Rewrite rules off
-- Don't generate a build if there are no rules to eliminate it!
-- See Note [Desugaring RULE left hand sides] in Desugar
|| null dynamic_prefix -- Avoid build (\c n. foldr c n xs)!
...
...
compiler/main/DynFlags.hs
View file @
30e7b73a
...
...
@@ -291,6 +291,7 @@ data DynFlag
|
Opt_CmmSink
|
Opt_CmmElimCommonBlocks
|
Opt_OmitYields
|
Opt_SimpleListLiterals
-- Interface files
|
Opt_IgnoreInterfacePragmas
...
...
@@ -2316,6 +2317,7 @@ fFlags = [
(
"cmm-sink"
,
Opt_CmmSink
,
nop
),
(
"cmm-elim-common-blocks"
,
Opt_CmmElimCommonBlocks
,
nop
),
(
"omit-yields"
,
Opt_OmitYields
,
nop
),
(
"simple-list-literals"
,
Opt_SimpleListLiterals
,
nop
),
(
"gen-manifest"
,
Opt_GenManifest
,
nop
),
(
"embed-manifest"
,
Opt_EmbedManifest
,
nop
),
(
"ext-core"
,
Opt_EmitExternalCore
,
nop
),
...
...
compiler/main/StaticFlagParser.hs
View file @
30e7b73a
...
...
@@ -119,7 +119,6 @@ isStaticFlag f =
"fno-hi-version-check"
,
"dno-black-holing"
,
"fno-state-hack"
,
"fsimple-list-literals"
,
"fruntime-types"
,
"fno-pre-inlining"
,
"fno-opt-coercion"
,
...
...
compiler/main/StaticFlags.hs
View file @
30e7b73a
...
...
@@ -34,7 +34,6 @@ module StaticFlags (
-- optimisation opts
opt_NoStateHack
,
opt_SimpleListLiterals
,
opt_CprOff
,
opt_SimplNoPreInlining
,
opt_SimplExcessPrecision
,
...
...
@@ -172,9 +171,6 @@ opt_NoDebugOutput = lookUp (fsLit "-dno-debug-output")
opt_DictsStrict
::
Bool
opt_DictsStrict
=
lookUp
(
fsLit
"-fdicts-strict"
)
opt_SimpleListLiterals
::
Bool
opt_SimpleListLiterals
=
lookUp
(
fsLit
"-fsimple-list-literals"
)
opt_NoStateHack
::
Bool
opt_NoStateHack
=
lookUp
(
fsLit
"-fno-state-hack"
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment