1
1
mirror of https://github.com/github/semantic.git synced 2024-12-18 04:11:48 +03:00
Commit Graph

82 Commits

Author SHA1 Message Date
Rob Rix
f68fa5ea30
Enable hard-mode warnings project-wide. 2019-10-30 13:29:45 -04:00
Rob Rix
c4e2c14601
Whoops 2: the Whoopsening. 2019-10-25 15:26:30 -04:00
Rob Rix
72ba6821ea
Whoops. 2019-10-25 14:34:54 -04:00
Rob Rix
e636757c29
Executing the monadic actions is the important thing, not evaluating the graph. 2019-10-25 14:22:50 -04:00
Rob Rix
93db4cfa45
Use the helpers anywhere we look up a parser. 2019-10-23 12:17:10 -04:00
Rob Rix
52b0d4c508
Select an abstract parser. 2019-10-23 11:48:01 -04:00
Rob Rix
d5cc356a8a
Map results to unit in evaluateProject. 2019-10-23 11:46:33 -04:00
Rob Rix
e9ca7cb1b8
Select an abstract parser. 2019-10-23 11:45:45 -04:00
Rob Rix
be51d3139f
Align. 2019-10-23 11:40:37 -04:00
Rob Rix
b8ff23f2c5
Inline the evaluators. 2019-10-23 11:40:23 -04:00
Rob Rix
46094f3e59
Fix which project we eval. 2019-10-23 11:39:50 -04:00
Rob Rix
9dcfbd8f2c
Spacing. 2019-10-23 11:39:30 -04:00
Rob Rix
d6d16c1c0d
Factor justEvaluating into evaluateProject. 2019-10-23 11:38:10 -04:00
Rob Rix
2dffafa12f
Type applications. 2019-10-23 11:36:59 -04:00
Rob Rix
97a31acc7a
Don’t require an NFData instance for the terms. 2019-10-23 11:36:36 -04:00
Rob Rix
ee539d8594
Fix some missing imports. 2019-10-22 17:12:58 -04:00
Rob Rix
10ee109dae
Try to correct the constraints for the benchmarks. 2019-10-22 17:04:31 -04:00
Rob Rix
a78cf3c7d2
Add some missing constraints. 2019-10-22 16:22:41 -04:00
Rob Rix
bf82196315
Abstract the benchmarks over the term type. 2019-10-21 17:37:01 -04:00
Rob Rix
2e8e65a13b
Rename VertexDeclaration to VertexDeclaration1. 2019-10-18 13:32:15 -04:00
Rob Rix
30b0f31020
Simplify VertexDeclaration to avoid the extra type parameter. 2019-10-18 13:18:02 -04:00
Patrick Thomson
df96f43acd Make findFilesInDir use pathtype. 2019-10-11 19:24:53 -04:00
Patrick Thomson
54394d61c8 Move around and correct benchmarks. 2019-10-04 12:37:24 -04:00
Patrick Thomson
284fc30f1c Reorganize benchmarks. 2019-10-04 11:25:34 -04:00
Patrick Thomson
65060868bc Make benchmarks operate and switch to gauge.
I find myself wanting to benchmark some I/O code, so I decided to look
at our benchmark suite, to find that it had bitrotted somewhat. This
patch brings it back up to working status, switches to `gauge` (which
is more accurate than `criteron` and incurs fewer dependencies), and
sprinkles some typed paths on there.
2019-09-27 13:18:30 -04:00
Patrick Thomson
ac543651ee Add NFData instances to enable more accurate benchmarking.
Because we're getting serious about benchmarking in the run-up to
Windrose, it's time to bring in the `deepseq` package to ensure that
benchmarks can fully evaluate the result of a test case.

The `deepseq` package provides an `NFData` typeclass:

```
class NFData a where
  rnf :: a -> ()
```

Instances use the `seq` combinator to ensure that the argument to
`rnf` is fully evaluated, returning (). If there is a `Generic`
instance for `a`, the implementation can be omitted. This patch adds
NFData for every syntax node, graph vertex, environment data
structures, and exceptions. It is long, but the work is very
straightforward, so don't panick.

The benchmark suite (`stack bench`) now produces more accurate
results. The benchmarks previously mimicked `rnf` by calling `show` on
the result of an evaluation or graph construction; now that we have
actual `NFData` instances we can use the `nfIO` combinator from
criterion. This has sped up the evaluation benchmarks and reduced
their memory consumption, while it has slowed down the call graph
benchmarks, as those benchmarks weren't evaluating the whole of the
graph.

Unfortunately, this patch increases compile times, as we have to
derive a few more Generic instances. I wish this weren't the case, but
there's little we can do about it now. In the future I have some plans
for how to reduce compile time, and I bet that those gains will at
least nullify the speed hit from this patch.

Now that we have NFData instances for every data type, we can start
benchmarking assignments, in preparation for fixing #2205.

This patch also pulls in updates to `effects` and `fastsum` that add
appropriate NFData instances for the data they vend.
2018-10-17 14:08:47 -04:00
Rick Winfrey
00693a54ee Update bench to work again 2018-08-13 15:42:42 -07:00
Patrick Thomson
bad6e9f53a Fix benchmarks and add benchmark for call graph.
Preyy straightforward.
2018-07-18 11:38:28 -04:00
Patrick Thomson
926e81b8a0 Fix benchmarks.
The interface in Semantic.Util had changed.
Also removes the old `evalRubyFile` and `evalPythonFile` functions,
since they did not typecheck in ghci and do nothing that the project
equivalents don't.
2018-05-04 13:49:37 -04:00
Patrick Thomson
6d5561f9b9 fix misalignment 2018-03-12 10:51:07 -04:00
Patrick Thomson
4378fa5657 add comment 2018-03-08 13:18:36 -05:00
Patrick Thomson
5ffa873279 add script/bench 2018-03-08 10:13:26 -05:00
Patrick Thomson
1ea97534b6 print so that we know everything is evaluated 2018-03-07 19:56:54 -05:00
Patrick Thomson
be2d90f029 add ruby 2018-03-07 19:47:23 -05:00
Patrick Thomson
0ac705b0f5 flesh out some benchmarks 2018-03-07 19:34:20 -05:00
Timothy Clem
c862b7bcf5 Remove benchmark target 2017-04-10 15:04:45 -07:00
Rob Rix
cfbe7e2108 🔥 the generative benchmark stuff. 2017-01-10 14:46:07 -05:00
Rob Rix
a5e7f584c8 hlint insists that this is redundant. 2017-01-09 16:15:36 -05:00
Rob Rix
d2709f6cab First pass at generative testing using leancheck. 2017-01-09 16:12:25 -05:00
Timothy Clem
6cbfa91475 Try out moving project around 2016-10-05 16:17:46 -07:00
Rob Rix
114e203c4a Handle rounding error by taking exactly n measurements. 2016-06-06 17:20:00 -04:00
Rob Rix
9eff3053ec Traverse up to the default size in n steps. 2016-06-06 17:19:42 -04:00
Rob Rix
927ee4345f Benchmark SES over fixed intervals. 2016-06-06 17:17:37 -04:00
Rob Rix
a7dd94f9d7 Compute element cost as sums of string length. 2016-06-06 17:17:19 -04:00
Rob Rix
b45bc321b2 Compute SES over lists of strings. 2016-06-06 17:16:52 -04:00
Rob Rix
2648406b34 Generalize generativeBenchmark over Gen a. 2016-06-06 17:15:51 -04:00
Rob Rix
ef57f3aece Add a baseline benchmark of SES. 2016-06-06 15:32:38 -04:00
Rob Rix
95eabb8b5d Add an NFData instance for Patch. 2016-06-06 15:32:16 -04:00
Rob Rix
893f53fa08 🔥 some unused setup from the numberedRows benchmark. 2016-06-06 13:09:17 -04:00
Rob Rix
44a1599afa 🔥 redundant imports. 2016-06-06 13:06:09 -04:00