Skip to content

Commit

Permalink
cue: add a benchmark regression test for issue 572
Browse files Browse the repository at this point in the history
It seems like the old evaluator fixed the performance issue here
sometime around the v0.4.0 release, as only certain v0.3 alpha versions
take more than a second to evaluate the bit of CUE.

For the sake of posterity, below are some rough performance numbers
for this input:

    # With an ancient version of CUE. (1.235s)
    > exec cue-v0.3.0-alpha5 vet -c
    # With the old evaluator. (0.109s)
    > env CUE_EXPERIMENT=evalv3=0
    > exec cue vet -c
    # With the new evaluator. (0.063s)
    > env CUE_EXPERIMENT=evalv3=1
    > exec cue vet -c

Closes #572.

Signed-off-by: Daniel Martí <mvdan@mvdan.cc>
Change-Id: I6cc256248efcf715b3e4fc81b1a770175121b0e7
Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1206507
Unity-Result: CUE porcuepine <cue.porcuepine@gmail.com>
Reviewed-by: Paul Jolly <paul@myitcv.io>
TryBot-Result: CUEcueckoo <cueckoo@cuelang.org>
  • Loading branch information
mvdan committed Jan 3, 2025
1 parent 7373f67 commit b5e1647
Showing 1 changed file with 3,040 additions and 0 deletions.
Loading

0 comments on commit b5e1647

Please sign in to comment.