cue/benchmarks: move benchmark code out of testdata
bench_test.go used to reside in cue/testdata/benchmarks
This meant that a `go test bench=. ./...` would not run these
benchmarks, because go test never delves inside testdata directories.
- Move bench_test to the cue directory (with package cue_test)
- Make it use filepath.WalkDir (matching cuetxtar)
- Make it use the eval matrices so that the benchmarks get run against
both the old and new evaluators
Signed-off-by: Matthew Sackman <matthew@cue.works>
Change-Id: I85fb895579ad38039eb47176eeb48c1aaceda9ea
Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1199739
TryBot-Result: CUEcueckoo <cueckoo@cuelang.org>
Unity-Result: CUE porcuepine <cue.porcuepine@gmail.com>
Reviewed-by: Marcel van Lohuizen <mpvl@gmail.com>