Commit Graph

145 Commits

Author SHA1 Message Date
Aaron Tomb
010540c4b4 Comment out cryptol-server from Cabal file 2017-07-24 15:26:49 -07:00
Aaron Tomb
69e49d4245 Bump version to 2.5.0 2017-07-24 09:16:40 -07:00
Aaron Tomb
de80a9c2f5 Update copyright dates in Cabal file 2017-07-24 09:01:34 -07:00
Levent Erkok
5857477ab2 Modifications to make cryptol compile with SBV 7.0
Also, bumped up the version to 2.4.1
2017-07-18 10:25:00 -07:00
Aaron Tomb
d76f21f89e Update benchmarks to find Prelude and CryptolTC.z3
Since they don’t run in the normal REPL environment, they need to know
about where to find the Prelude and CryptolTC.z3 more directly.
2017-03-21 12:31:04 -07:00
Iavor S. Diatchki
41131fe7ed Redo the export to SMT story in a much simpler way. 2017-02-16 16:46:38 -08:00
Iavor S. Diatchki
3c15d086d1 Merge branch 'master' into wip/solver 2017-02-08 16:24:46 -08:00
Iavor S. Diatchki
710355176a More rules and things; external solver disabled; we can at least load ChaCha 2017-02-08 15:08:50 -08:00
Brian Huffman
140ab21f11 Add new unoptimized reference interpreter; use in REPL with ":eval <expr>" 2017-02-03 09:02:25 -08:00
Iavor S. Diatchki
f3db823f3e Checkpoint: (broken, but builds) 2017-02-01 11:43:01 -08:00
Iavor S. Diatchki
b788079244 More aggressive goal simplification. 2017-01-31 14:12:53 -08:00
Iavor S. Diatchki
12bb2c30c8 Merge branch 'master' into wip/solver 2017-01-31 10:15:49 -08:00
Iavor S. Diatchki
ee1c8c796b Switch to using the official sbv release. 2017-01-31 10:04:34 -08:00
Iavor S. Diatchki
baa19ce362 Checkpoint. 2017-01-30 18:14:10 -08:00
Iavor S. Diatchki
c3ce33f5a6 Remove old stuff 2017-01-30 10:54:45 -08:00
Robert Dockins
dae3ab11b1 Change the representation and caching of sequences for better performance.
There are two major changes in this patch.  The first is that sequence maps
now have special representations for point updates, of the sort produced by
the 'update' and 'updateEnd' primtives.  These updates are stored in a
finite map, rather than as a functional-update thunk using lambdas; this
reduces memory usage and improves time efficecy of sequences defined by
sequences of updates.

The second change is that the caching policy for sequences is changed
to retain all previously-calculated values.  This is a change from the
previous LRU policy, which retained only a small finite number of previous
values.  Benchmarking showed that unbounded memoization was better for
performance in essentially all cases over both an LRU and an adaptive
caching strategy.  The potential downside is that we may retain values
longer than necessary.  If this becomes a problem, we may need to revisit
this decision.
2016-08-12 12:10:49 -07:00
Robert Dockins
2e15d4f443 Increase the size of the garbage collector nursery to 64m.
This greatly increases mutator productivity, and thus provides
significant speedups on some examples.  The tradeoff with
larger nurseries is the potential for long GC pause times.
This is probably acceptable tradeoff for a tool like Cryptol,
despite the potential for unresponsiveness at the REPL.
2016-07-20 15:55:05 -07:00
Robert Dockins
998bddc7a7 Merge remote-tracking branch 'origin/master' into new-eval
Fix some minor conflicts in the test suite.
Conflicts:
	tests/issues/issue002.icry.fails
	tests/issues/issue148.icry.stdout
	tests/issues/issue198.icry.stdout
	tests/issues/issue214.icry.stdout
	tests/issues/issue290v2.icry.stdout
	tests/issues/issue312.icry.fails
2016-07-12 14:58:53 -07:00
Adam C. Foltzer
3c25c096a7 clean up build a bit 2016-07-06 16:20:01 -07:00
Adam C. Foltzer
78cacc4d3e Merge pull request #333 from RyanGlScott/master
Put bench/data/*.cry in extra-source-files
2016-07-05 08:49:53 -07:00
Robert Dockins
c3c1bb2c74 Merge branch 'master' into new-eval-merge 2016-06-13 16:29:36 -07:00
Robert Dockins
b95b734b74 Refactoring of how bits and words are handled in the interpreters.
The major change in this patch is to add a new type of 'WordValue'
which is always used to represent finite sequences of bits.  A word
value is either a packed word, or a sequence of lazy bits.  The 'VSeq'
constructor, in constrast, is now never used for a finite sequence of
bits.

This avoids certain thorny problems that arise when trying to faithfully
implement the lazy semantics of Cryptol.  We now do not have to commit
to a value at type '[n]' being represented as a packed word or as an
unpacked word until relatively late.  This allows us to perform type-directed
eta-expansion at every recursive call before we know how words will be represented.

This patch fixes all the outstanding strictness bugs that I know of.

Unfortunately, we seem to lose some ground on performance.  The new evaluator
is now about 5% slower than the old one on the AES benchmark, and quite a bit
slower on the SHA1 benchmark.  Fortunately, the use if LRU caches for memoization
of sequences seems to keep heap usage to manageable levels; so programs generally
complete, even if they take a long time.
2016-06-09 08:31:23 -04:00
Adam C. Foltzer
76be770d83 clean up 7.8-isms 2016-06-07 13:40:15 -07:00
Robert Dockins
99526f5700 Merge branch 'master' of github.com:GaloisInc/cryptol into new-eval 2016-06-01 15:22:09 -07:00
Thomas M. DuBuisson
363651c907 Fixes #320 Use -N1, not -N, as the default RTS option. 2016-05-31 10:38:13 -07:00
Rob Dockins
bdcfdd39a1 Update benchmarks for new interpreters 2016-05-30 23:07:05 -07:00
Rob Dockins
b518336885 Merge branch 'master' of cryptol into new-eval 2016-05-30 17:25:10 -07:00
Trevor Elliott
2f21dd509a Remove the generic-trie dependency 2016-05-27 17:05:16 -07:00
Ryan Scott
f1a45163a4 Put bench/data/*.cry in extra-source-files 2016-05-20 15:04:53 -04:00
Robert Dockins
7e968d2d18 WIP. New monadic Cryptol interpreter.
The concrete evaluator now seems to be working correctly,
but seems to suffer from major performace problems.
2016-05-12 18:44:06 -07:00
Sergei Trofimovich
ab43c275d4 tweak for deepseq-generics-0.2
deepseq-generics-0.2 stopped reexporting NFData from deepseq.
Patch imports it explicitly.

Signed-off-by: Sergei Trofimovich <siarheit@google.com>
2016-03-25 14:35:55 +00:00
Adam C. Foltzer
feb9d22a88 version bump & housekeeping
Bumped to version 2.4.0 and dropped the minor version from the GHC710
etc variables
2016-01-26 12:09:54 -08:00
Adam C. Foltzer
4d3fc9a413 Update copyright dates and add missing headers 2016-01-19 18:19:35 -08:00
Adam C. Foltzer
da6916702b split new Prelude definitions into Extras module
The definitions added in #299 cause a regression in Prelude typechecking
performance. Until we sort out the performance, we'll keep these
definitions in the module `Cryptol::Extras`.
2016-01-19 18:19:24 -08:00
Adam C. Foltzer
31176993e0 add lower bound for optparse-applicative
With the newer `transformers-compat` release, cabal was resolving this
dependency all the way back to `0.0.1`
2016-01-19 18:18:03 -08:00
Adam C. Foltzer
5c80fc2e1c temporary upper bound for deepseq-generics
We're only using this package for 7.8 compatibility, which will end when
GHC 8.0 is released soon. For now, just limit to the older version to
avoid import errors.
2016-01-08 11:53:01 -08:00
Thomas M. DuBuisson
752310cd0d Merge branch 'master' into writeFile 2015-12-25 21:39:01 -08:00
Adam C. Foltzer
9c07fe1006 merge in the 2.2.6 changes, including z3 switch 2015-12-23 16:10:56 -08:00
Thomas M. DuBuisson
1c36537d78 Update for SBV 5.7
Conflicts:
	cryptol.cabal
	src/Cryptol/Symbolic.hs
	src/Cryptol/Symbolic/Prims.hs
2015-12-23 14:13:59 -08:00
Adam C. Foltzer
579ccc96a0 backport prover command interface
Conflicts:
	src/Cryptol/REPL/Command.hs
	src/Cryptol/Symbolic.hs
2015-12-23 14:03:59 -08:00
Adam C. Foltzer
917cc27145 version bump to 2.2.6 2015-12-23 11:33:36 -08:00
Adam C. Foltzer
aeefab69a1 refactor :check and :exhaust
This is to set up improvements to the cryptol-server, and therefore
pycryptol interface.

This patch also fixes a regression in pretty-printing output caused by a
previous error in fixity of the `<>` operator
2015-12-22 18:17:20 -08:00
Adam C. Foltzer
f87ea62646 Merge branch 'server-interrupts' into HEAD 2015-12-14 13:56:52 -08:00
Thomas M. DuBuisson
1ffc086ed4 Update for SBV 5.6 2015-12-10 12:38:26 -08:00
Adam C. Foltzer
04d62ae221 refine interrupt behavior
In order to prevent Ctrl-Cs in, e.g. Python from bringing down the
server, there's now an option to swallow SIGINT when launching the server.
2015-12-04 15:53:51 -08:00
Adam C. Foltzer
563efcc25b start improving handling of interrupts in server
This notably adds a `MonadBaseControl` instance for the `REPL` monad so
that we can catch asynchronous exceptions in the middle of `REPL`
computations. Since this is a generalization of Haskeline's exception
support, that orphan instance for the console executable is now in terms
of this new instance.
2015-12-03 15:36:43 -08:00
Adam C. Foltzer
4796b0a75a tweak how the prelude is loaded
This removes the `self-contained` flag, since it is fine for all builds
to have the baked-in prelude as a last resort. Tinkerers can still
change the prelude as long as it's in the search path.

Also removes some unnecessary extra prelude loading by the Cryptol
server by means of a new command
2015-11-16 12:56:36 -08:00
Thomas M. DuBuisson
0d18bc821c Merge branch 'writeFile' of github.com:TomMD/cryptol into tommd/writeFile 2015-11-15 10:16:16 -08:00
Adam C. Foltzer
6203eedf3a bump SBV lower bound 2015-11-11 15:11:19 -08:00
Adam C. Foltzer
9f3d42344d require new aeson 2015-10-27 16:10:50 -07:00