This is an archive of the discontinued LLVM Phabricator instance.

[Assignment Tracking] Skip empty-metadata dbg.declares in AssignmentTrackingPass
ClosedPublic

Authored by Orlando on Apr 13 2023, 2:33 AM.

Details

Summary

Debug intrinsics sometimes end up with empty metadata location operands. The debug intrinsic interfaces return nullptr when retrieving location operand in this case.

Skip empty-metadata dbg.declares to avoid dereferencing the nullptr. This doesn't affect the final debug info in any way.

N.B. my "empty metadata is the same as poison" patch stack (D140902) hasn't landed yet as I'm focussing on assignment tracking for now.

Diff Detail

Event Timeline

Orlando created this revision.Apr 13 2023, 2:33 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 13 2023, 2:33 AM
Herald added a subscriber: hiraditya. · View Herald Transcript
Orlando requested review of this revision.Apr 13 2023, 2:33 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 13 2023, 2:33 AM
jryans accepted this revision.Apr 13 2023, 2:43 AM
jryans added a subscriber: jryans.

Looks good, thanks! 🙂

This revision is now accepted and ready to land.Apr 13 2023, 2:43 AM
This revision was landed with ongoing or failed builds.Apr 18 2023, 12:44 AM
This revision was automatically updated to reflect the committed changes.

Thanks for the review!