This is an archive of the discontinued LLVM Phabricator instance.

[NFC][DebugInfo][RemoveDIs] Prefer iterators over instruction pointers in instcombine
ClosedPublic

Authored by jmorse on Jun 9 2023, 8:05 AM.

Details

Summary

Continuing todays theme of "Use iterators over instruction pointers", as per my proposal for how to get rid of debug intrinsics [0], instrument a bunch of call-sites in instcombine to pass around iterators instead of pointers. Again, these are all the call-sites that had to be instrumented to make a stage2clang build identically in the context of our "no dbg.values" prototype, plus a couple of other large C++ code bases I have to hand.

Patch is technically NFC and I'm not adding reviewers; this is so that people can take a look at what changes I'm proposing, and have a think about how we can go about testing them.

[0] https://discourse.llvm.org/t/rfc-instruction-api-changes-needed-to-eliminate-debug-intrinsics-from-ir/68939

Diff Detail

Event Timeline

jmorse created this revision.Jun 9 2023, 8:05 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 9 2023, 8:05 AM
Herald added a subscriber: hiraditya. · View Herald Transcript
jmorse requested review of this revision.Jun 9 2023, 8:05 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 9 2023, 8:05 AM
Orlando accepted this revision.Sep 8 2023, 1:43 AM
Orlando added a subscriber: Orlando.

LGTM

This revision is now accepted and ready to land.Sep 8 2023, 1:43 AM
This revision was landed with ongoing or failed builds.Sep 11 2023, 7:06 AM
This revision was automatically updated to reflect the committed changes.