Look up system-wide time binary instead of hardcoding it to /bin/time; e.g. on Ubuntu it's /usr/bin/time. This made the .sh script work for me.
To get benchmarking working I also had to exclude p0.flac and p1.flac sample files from archive.org because Claxon benchmarking program was panicking on decoding them:
thread 'main' panicked at 'assertion failed: reader.streaminfo().channels == 2', examples/decode.rs:25:5 for p0
thread 'main' panicked at 'assertion failed: reader.streaminfo().bits_per_sample == 16', examples/decode.rs:24:5 for p1.
For me this custom R thing is way more trouble than it's worth and I'll just stick to hyperfine "target/release/examples/decode testsamples/extra/*.flac" "flac -fd testsamples/extra/*.flac" which does exactly the same in Rust and without custom scripts. But I thought I'd submit the fix anyway.
Look up system-wide
time
binary instead of hardcoding it to /bin/time; e.g. on Ubuntu it's /usr/bin/time. This made the .sh script work for me.To get benchmarking working I also had to exclude p0.flac and p1.flac sample files from archive.org because Claxon benchmarking program was panicking on decoding them:
thread 'main' panicked at 'assertion failed: reader.streaminfo().channels == 2', examples/decode.rs:25:5
for p0thread 'main' panicked at 'assertion failed: reader.streaminfo().bits_per_sample == 16', examples/decode.rs:24:5
for p1.For me this custom R thing is way more trouble than it's worth and I'll just stick to
hyperfine "target/release/examples/decode testsamples/extra/*.flac" "flac -fd testsamples/extra/*.flac"
which does exactly the same in Rust and without custom scripts. But I thought I'd submit the fix anyway.