This should correct issue #572

We should leave the ticket open until we figure out if this is actually
a bug in SBV, as the API it exposes is quite odd.
This commit is contained in:
Iavor Diatchki 2019-02-14 14:11:40 -08:00
parent fd67463b2b
commit ff81ea4095

View File

@ -20,7 +20,7 @@ import Control.Monad.IO.Class
import Control.Monad (replicateM, when, zipWithM, foldM)
import Control.Monad.Writer (WriterT, runWriterT, tell, lift)
import Data.List (intercalate, genericLength)
import Data.IORef(IORef)
import Data.IORef(IORef,writeIORef)
import qualified Control.Exception as X
import qualified Data.SBV.Dynamic as SBV
@ -176,6 +176,9 @@ satProve ProverCommand {..} =
lPutStrLn $ "Trying proof with " ++
intercalate ", " (map (show . SBV.name . SBV.solver) provers)
(firstProver, timeElapsed, res) <- M.io (fn provers' e)
-- NOTE: It would appear that the ref does not contain the elaspsed
-- time but rahter some sort of small value, so we write it here.
liftIO $ writeIORef pcProverStats timeElapsed
when pcVerbose $
lPutStrLn $ "Got result from " ++ show firstProver ++
", time: " ++ showTDiff timeElapsed