This is an archive of the discontinued LLVM Phabricator instance.

Use WeakVH instead of WeakTrackingVH in AliasSetTracker's UnkownInsts
ClosedPublic

Authored by sanjoy on Apr 19 2017, 9:47 PM.

Details

Summary

In cases where an instruction (a call site, say) is RAUW'ed with some
other value (this is possible via the returned attribute, amongst
other things), we want the slot in UnknownInsts to point to the
original Instruction we wanted to track, not the value it got replaced
by.

Fixes PR32587.

Diff Detail

Repository
rL LLVM

Event Timeline

sanjoy created this revision.Apr 19 2017, 9:47 PM
davide accepted this revision.Apr 25 2017, 2:15 PM
davide added inline comments.
test/Analysis/AliasSet/unknown-inst-tracking.ll
1 ↗(On Diff #95883)

Can you add a comment to explain what you're testing here? I would also add some more CHECK lines as I'm not a fan of no-crash tests, but up to you.

1–2 ↗(On Diff #95883)

I wish there was a way to trigger this with a single pass, but even when I reduced the testcase I wasn't able to find it.

This revision is now accepted and ready to land.Apr 25 2017, 2:15 PM
This revision was automatically updated to reflect the committed changes.