Description
I'm looking into adding automatic bisection to icemaker reports and it turns out to be quite difficult.
I was hoping I could do something like cargo-bisect-rustc --preserve --test-dir=/home/matthias/vcs/github/rust_bisect/foo --start 2021-01-01 --access github --regress ice -- rustc /tmp/icemaker/113793.rs -Zmir-opt-level=3
apparently this requires cargo rustc
to be a subcommand :/
When bisecting manually I used a --script
where I would just put in a simple ! rustc args | grep "panic"
command to force a bad exit code on crash, but writing, chmodding and executing a bash script which you then run as arg to cargo-bisect seems kinda silly.
I need to be able to use (prlimit run ..) rustc/rustdoc/clippy-driver <file> <args>
) to pipe through the binary, rustflags and filepath that I get from icemaker, creating an extra "cargo" project and putting the file in there, and setting its RUSTFLAGS and then running "cargo build" also does not seem like the right way.
edit: I found cargo x
which seems to be a simple passthrough, so that cargo x cmd
simply runs cmd
, maybe cargo bisect ... x rustc ..
can make it work, will try that next
Plans to just use cargo-bisect as a dependency in icemaker were quickly abolished when I saw not even the Config
struct was marked public 😆 so that would probably require a bunch of changes here and there.
It would be great to have something like a --cmd "rustc --foo --bar crash.rs" --interesting-exitcodes="101,42,134" --interesting-output="panicked" --interesting-output="stack overflow" --interesting-output="internal compiler error" to make it a bit more versatile