Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
GHC
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
0
Merge Requests
0
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Package Registry
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Alex D
GHC
Commits
46379cbb
Commit
46379cbb
authored
Jan 09, 2008
by
rl@cse.unsw.edu.au
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
More refactoring in getCoreToDo
parent
6c9db8f1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
3 deletions
+6
-3
compiler/main/DynFlags.hs
compiler/main/DynFlags.hs
+6
-3
No files found.
compiler/main/DynFlags.hs
View file @
46379cbb
...
...
@@ -774,6 +774,10 @@ runWhen :: Bool -> CoreToDo -> CoreToDo
runWhen
True
do_this
=
do_this
runWhen
False
do_this
=
CoreDoNothing
runMaybe
::
Maybe
a
->
(
a
->
CoreToDo
)
->
CoreToDo
runMaybe
(
Just
x
)
f
=
f
x
runMaybe
Nothing
_
=
CoreDoNothing
getCoreToDo
::
DynFlags
->
[
CoreToDo
]
getCoreToDo
dflags
|
Just
todo
<-
coreToDo
dflags
=
todo
-- set explicitly by user
...
...
@@ -790,8 +794,7 @@ getCoreToDo dflags
rule_check
=
ruleCheck
dflags
vectorisation
=
dopt
Opt_Vectorise
dflags
maybe_rule_check
phase
|
Just
s
<-
rule_check
=
CoreDoRuleCheck
phase
s
|
otherwise
=
CoreDoNothing
maybe_rule_check
phase
=
runMaybe
rule_check
(
CoreDoRuleCheck
phase
)
simpl_phase
phase
iter
=
CoreDoPasses
[
CoreDoSimplify
(
SimplPhase
phase
)
[
...
...
@@ -842,7 +845,7 @@ getCoreToDo dflags
-- We run vectorisation here for now, but we might also try to run
-- it later
runWhen
vectorisation
(
CoreDoPasses
[
CoreDoVectorisation
,
simpl_gently
]),
runWhen
vectorisation
(
CoreDoPasses
[
CoreDoVectorisation
,
simpl_gently
]),
-- Specialisation is best done before full laziness
-- so that overloaded functions have all their dictionary lambdas manifest
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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