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

Add timeout to solver interface #49

Merged
merged 2 commits into from
Feb 11, 2023
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
10 changes: 9 additions & 1 deletion src/Grisette/Backend/SBV.hs
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,16 @@
-- Portability : GHC only
module Grisette.Backend.SBV
( -- * Grisette SBV backend configuration
ApproximationConfig (..),
ExtraConfig (..),
precise,
approx,
withTimeout,
clearTimeout,
withApprox,
clearApprox,
GrisetteSMTConfig (..),
sbvConfig,
SolvingFailure (..),

-- * SBV backend solver configuration
SBV.SMTConfig (..),
Expand Down
6 changes: 4 additions & 2 deletions src/Grisette/Backend/SBV/Data/SMT/Lowering.hs
Original file line number Diff line number Diff line change
Expand Up @@ -1002,8 +1002,10 @@ resolveConfigView ::
GrisetteSMTConfig integerBitWidth ->
DictConfig integerBitWidth
resolveConfigView config = case config of
UnboundedReasoning c -> DictConfig c
BoundedReasoning c -> DictConfig c
GrisetteSMTConfig c extra ->
case integerApprox extra of
NoApprox -> DictConfig c
Approx _ -> DictConfig c

pattern ResolvedConfig ::
forall integerBitWidth.
Expand Down
Loading