This is an archive of the discontinued LLVM Phabricator instance.

Do not make -pass-remarks additive.
ClosedPublic

Authored by dnovillo on May 5 2014, 12:53 PM.

Details

Summary

When I initially introduced -pass-remarks, I thought it would be a
neat idea to make it additive. So, if one used it as:

$ llc -pass-remarks=inliner --pass-remarks=loop.*

the compiler would build the regular expression '(inliner)|(loop.*)'.

The more I think about it, the more I regret it. This is not how
other flags work. The standard semantics are right-to-left overrides.

This is how clang interprets -Rpass. And I think the two should be
compatible in this respect.

Diff Detail

Event Timeline

dnovillo updated this revision to Diff 9085.May 5 2014, 12:53 PM
dnovillo retitled this revision from to Do not make -pass-remarks additive..
dnovillo updated this object.
dnovillo edited the test plan for this revision. (Show Details)
dnovillo added a reviewer: qcolombet.
dnovillo added a subscriber: Unknown Object (MLST).
qcolombet accepted this revision.May 5 2014, 3:45 PM
qcolombet edited edge metadata.

Hi Diego,

Although I liked it this way, your change makes sense.

If we decide to go back, that you be easy to resurrect the previous behavior.

LGTM with maybe a test case with two options and we check that we only emit what is related to the last one.

Thanks,

-Quentin

This revision is now accepted and ready to land.May 5 2014, 3:45 PM
dnovillo closed this revision.May 6 2014, 12:24 PM