Passing command line arguments to the benhmark program using stack

346 Views Asked by At

I'm using stack as a build tool, and criterion as benchmarking library. To run the benchmarks I execute the following command:

stack bench

Criterion accepts command line arguments to specify where the output should be written to. I would like to pass these arguments to the executable built and run by stack. Is there a way to achieve this?

1

There are 1 best solutions below

0
Li-yao Xia On BEST ANSWER
stack bench --benchmark-arguments "--arguments --for --criterion"

(It's among options listed under stack bench --help.)