This is an archive of the discontinued LLVM Phabricator instance.

[ConstraintElim] Store the triple Pred + LHS + RHS in ReproducerEntry instead of CmpInst + Not
ClosedPublic

Authored by dtcxzyw on Jul 19 2023, 11:05 PM.

Details

Summary

This patch represents a condition with Pred + LHS + RHS in ReproducerEntry instead of CmpInst + Not.
It avoids creating temporary ICmpInsts in D155412.

Diff Detail

Event Timeline

dtcxzyw created this revision.Jul 19 2023, 11:05 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 19 2023, 11:05 PM
dtcxzyw requested review of this revision.Jul 19 2023, 11:05 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 19 2023, 11:05 PM
nikic accepted this revision.Jul 20 2023, 12:24 AM

LGTM

llvm/lib/Transforms/Scalar/ConstraintElimination.cpp
997

Add an icmp prefix to make it the same as the previous output?

999

You can pass false as the second arg here to avoid printing the type again, matching how icmp is usually printed.

This revision is now accepted and ready to land.Jul 20 2023, 12:24 AM
dtcxzyw updated this revision to Diff 542451.Jul 20 2023, 5:33 AM

Address comments

dtcxzyw marked 2 inline comments as done.Jul 20 2023, 5:34 AM
fhahn accepted this revision.Jul 20 2023, 7:42 AM

LGTM, thanks for the follow-up!

This revision was landed with ongoing or failed builds.Jul 20 2023, 8:23 AM
This revision was automatically updated to reflect the committed changes.