-
Notifications
You must be signed in to change notification settings - Fork 13.6k
[RemoveDIs] Update DIBuilder to conditionally insert DbgRecords #84739
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
b25c546
b503e84
3964cc5
36c7aa0
a706ca6
c3cec69
f443a18
88f6e21
c6bbfe4
035630f
1f95a01
eb428e6
42f4e74
063f9cd
60f9a2f
3a15cfa
7754eb9
0a96251
44008e2
2e69a99
8b03c20
63511e0
197ab57
ef7ce1a
333bc9e
5cc4a3e
4e0bfff
905a794
a7bbba3
edecd14
25c66b1
04a4e29
e12c7dc
bf1c8c1
8ea9e72
ba210ae
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -752,8 +752,6 @@ void BasicBlock::spliceDebugInfoEmptyBlock(BasicBlock::iterator Dest, | |
// occur when a block is optimised away and the terminator has been moved | ||
// somewhere else. | ||
if (Src->empty()) { | ||
assert(Dest != end() && | ||
"Transferring trailing DPValues to another trailing position"); | ||
DPMarker *SrcTrailingDPValues = Src->getTrailingDPValues(); | ||
if (!SrcTrailingDPValues) | ||
return; | ||
|
@@ -1038,15 +1036,10 @@ void BasicBlock::insertDPValueAfter(DbgRecord *DPV, Instruction *I) { | |
|
||
void BasicBlock::insertDPValueBefore(DbgRecord *DPV, | ||
InstListType::iterator Where) { | ||
// We should never directly insert at the end of the block, new DPValues | ||
// shouldn't be generated at times when there's no terminator. | ||
assert(Where != end()); | ||
assert(Where->getParent() == this); | ||
if (!Where->DbgMarker) | ||
createMarker(Where); | ||
assert(Where == end() || Where->getParent() == this); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is the first condition in this assert meant to be inverted? I would have thought that if There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah, so this is changing the condition here to account for insertions at |
||
bool InsertAtHead = Where.getHeadBit(); | ||
createMarker(&*Where); | ||
Where->DbgMarker->insertDPValue(DPV, InsertAtHead); | ||
DPMarker *M = createMarker(Where); | ||
M->insertDPValue(DPV, InsertAtHead); | ||
} | ||
|
||
DPMarker *BasicBlock::getNextMarker(Instruction *I) { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this something that we see happen when building BBs in clang?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is hit by test
OpenMP/cancel_codegen.cpp