This is an archive of the discontinued LLVM Phabricator instance.

stripDebugInfo() should remove DILocation's found in !llvm.loop metadata
ClosedPublic

Authored by dsanders on Dec 20 2016, 3:36 AM.

Details

Summary

Patch by Michele Scandale
(with a small tweak to 'CHECK-NOT' the last DILocation in the test)

Diff Detail

Repository
rL LLVM

Event Timeline

dsanders updated this revision to Diff 82086.Dec 20 2016, 3:36 AM
dsanders retitled this revision from to stripDebugInfo() should remove DILocation's found in !llvm.loop metadata.
dsanders updated this object.
dsanders added a subscriber: llvm-commits.
dsanders added inline comments.
lib/IR/DebugInfo.cpp
244 ↗(On Diff #82086)

Can N->op_begin() == N->op_end() ever? If so, I think this is incorrect.
If not, maybe we should assert it?

I believe the first operand is always a self-reference (e.g. !13 in the test). I'll add an assert

dsanders updated this revision to Diff 82225.Dec 21 2016, 4:42 AM

Add assertion

This revision was automatically updated to reflect the committed changes.
vasich added a subscriber: vasich.Aug 7 2017, 1:40 AM