Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable environment reduction by default #1890

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Language/Haskell/Liquid/Constraint/ToFixpoint.hs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ fixConfig tgt cfg = def
, FC.rwTerminationCheck = rwTerminationCheck cfg
, FC.noLazyPLE = noLazyPLE cfg
, FC.fuel = fuel cfg
, FC.noEnvironmentReduction = noEnvironmentReduction cfg
, FC.noEnvironmentReduction = not (environmentReduction cfg)
, FC.inlineANFBindings = inlineANFBindings cfg
}

Expand Down
6 changes: 6 additions & 0 deletions src/Language/Haskell/Liquid/UX/CmdLine.hs
Original file line number Diff line number Diff line change
Expand Up @@ -434,6 +434,11 @@ config = cmdArgsMode $ Config {
= Nothing
&= help "Maximum fuel (per-function unfoldings) for PLE"

, environmentReduction
= def
&= explicit
&= name "environment-reduction"
&= help "perform environment reduction (disabled by default)"
, noEnvironmentReduction
= def
&= explicit
Expand Down Expand Up @@ -702,6 +707,7 @@ defConfig = Config
, skipModule = False
, noLazyPLE = False
, fuel = Nothing
, environmentReduction = False
, noEnvironmentReduction = False
, inlineANFBindings = False
}
Expand Down
1 change: 1 addition & 0 deletions src/Language/Haskell/Liquid/UX/Config.hs
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ data Config = Config
, skipModule :: Bool -- ^ Skip this module entirely (don't even compile any specs in it)
, noLazyPLE :: Bool
, fuel :: Maybe Int -- ^ Maximum PLE "fuel" (unfold depth) (default=infinite)
, environmentReduction :: Bool -- ^ Perform environment reduction
, noEnvironmentReduction :: Bool -- ^ Don't perform environment reduction
, inlineANFBindings :: Bool -- ^ Inline ANF bindings.
-- Sometimes improves performance and sometimes worsens it.
Expand Down