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

Enable choice of term ordering for REST #1930

Open
wants to merge 13 commits into
base: develop
Choose a base branch
from
Next Next commit
Allow different ordering constraints
  • Loading branch information
zgrannan committed Nov 9, 2021
commit 000c0ab7b3aa41547f5100f314678b6f04cac1c8
1 change: 1 addition & 0 deletions src/Language/Haskell/Liquid/Constraint/ToFixpoint.hs
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ fixConfig tgt cfg = def
, FC.fuel = fuel cfg
, FC.noEnvironmentReduction = not (environmentReduction cfg)
, FC.inlineANFBindings = inlineANFBindings cfg
, FC.restOrdering = read (restOrdering cfg)
}

cgInfoFInfo :: TargetInfo -> CGInfo -> IO (F.FInfo Cinfo)
Expand Down
5 changes: 5 additions & 0 deletions src/Language/Haskell/Liquid/UX/CmdLine.hs
Original file line number Diff line number Diff line change
Expand Up @@ -446,6 +446,10 @@ config = cmdArgsMode $ Config {
, "Sometimes improves performance and sometimes worsens it."
, "Disabled by --no-environment-reduction"
])
, restOrdering
= "rpo"
&= name "rest-ordering"
&= help "Ordering Constraints Algebra to use for REST"
zgrannan marked this conversation as resolved.
Show resolved Hide resolved
} &= program "liquid"
&= help "Refinement Types for Haskell"
&= summary copyright
Expand Down Expand Up @@ -702,6 +706,7 @@ defConfig = Config
, environmentReduction = False
, noEnvironmentReduction = False
, inlineANFBindings = False
, restOrdering = "rpo"
}


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 @@ -105,6 +105,7 @@ data Config = Config
, noEnvironmentReduction :: Bool -- ^ Don't perform environment reduction
, inlineANFBindings :: Bool -- ^ Inline ANF bindings.
-- Sometimes improves performance and sometimes worsens it.
, restOrdering :: String
} deriving (Generic, Data, Typeable, Show, Eq)

allowPLE :: Config -> Bool
Expand Down