[llvm-dev] bugpoint and the new pass manager

David Greene via llvm-dev llvm-dev at lists.llvm.org
Wed Jan 27 08:26:49 PST 2021


Florian Hahn via llvm-dev <llvm-dev at lists.llvm.org> writes:

> FWIW I often use bugpoint’s crashing pass reduction feature (
> e.g. `bugpoint -O3 foo.bc` to reduce the sequence of passes exposing a
> crash) when investigating crashes in LLVM optimizations. This is
> unfortunately one of the features directly tied to the pass manager.

Ditto.

> My main concern is that `opt` and `bugpoint` having different defaults
> seems to have potential to be quite confusing to user (e.g. `opt
> -passes=default<O3>` crashes, but `bug point -passes=default<O3>` does
> not, `bug point -O3 ` works, but does not reproduce the failure,
> e.g. due to difference in the pipeline).

Agreed.

> I don’t know how widely used bugpoint is, but it features prominently
> in the documentation, e.g. https://llvm.org/docs/HowToSubmitABug.html
> , which is linked from the getting started page and the documentation
> sidebar.

I use bugpoint a ton.  That said, mostly I've used it for testcase
reduction and have done my own manual optimization pipeline reduction
mostly because codegen optimizations aren't as nicely layered and the
codegen pipeline can't be driven from bugpoint.

Getting codegen passes into the new pass manager has been raised
multiple times because and that would be a good thing to happen but it
doesn't begin to tackle the problem of automatic bug classification in
codegen.

> I think before switching, it would be good to at least update
> HowToSubmitABug. We should probably also add a note to Bugpoint’s docs
> and refer the the documentation for llvm-reduce. It is great if people
> take time to reduce the test cases for their bug reports and we should
> try to make the experience as smooth as possible

Yeah, we need a way to keep bug reports sane.  If llvm-reduce can do as
well or better than bugpoint, great, I'm all for it!

               -David


More information about the llvm-dev mailing list