This is an archive of the discontinued LLVM Phabricator instance.

[MergeFuncs] Call removeUsers() prior to unnamed_addr RAUW
ClosedPublic

Authored by nikic on Oct 14 2018, 12:58 PM.

Details

Summary

For unnamed_addr functions we RAUW instead of only replacing direct callers. However, functions in which replacements were performed currently are not added back to the worklist, resulting in missed merging opportunities.

Fix this by calling removeUsers() prior to RAUW.

Diff Detail

Repository
rL LLVM

Event Timeline

nikic created this revision.Oct 14 2018, 12:58 PM
nikic updated this revision to Diff 169621.Oct 14 2018, 1:01 PM

Remove some trailing semicolons in the test file ... hard to break that habit.

whitequark accepted this revision.Oct 14 2018, 7:24 PM

LGTM, thanks for fixing this!

This revision is now accepted and ready to land.Oct 14 2018, 7:24 PM
nikic added a comment.Oct 17 2018, 6:36 AM

@whitequark I don't have commit access, could I ask you to land this patch?

rkruppe added a subscriber: rkruppe.Nov 5 2018, 5:33 AM
This revision was automatically updated to reflect the committed changes.