<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - [Debuginfo] @llvm.dbg.value changes behavior of transformations that check for BB size"
href="https://bugs.llvm.org/show_bug.cgi?id=40634">40634</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>[Debuginfo] @llvm.dbg.value changes behavior of transformations that check for BB size
</td>
</tr>
<tr>
<th>Product</th>
<td>libraries
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>enhancement
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>DebugInfo
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>florian_hahn@apple.com
</td>
</tr>
<tr>
<th>CC</th>
<td>jdevlieghere@apple.com, keith.walker@arm.com, llvm-bugs@lists.llvm.org, paul_robinson@playstation.sony.com
</td>
</tr></table>
<p>
<div>
<pre>After skimming D57629, I had a quick look around to search for similar
problematic checks in other LLVM transformations. Below is an incomplete list
of instances I found.
diff --git a/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp
b/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp
index 1f40c8f5a4a..dd8fe342aa7 100644
--- a/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp
+++ b/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp
@@ -2383,6 +2383,7 @@ static Instruction *tryToMoveFreeBeforeNullTest(CallInst
&FI,
// this is the call to free and unconditional.
// If there are more than 2 instructions, check that they are noops
// i.e., they won't hurt the performance of the generated code.
+ // TODO
if (FreeInstrBB->size() != 2) {
for (const Instruction &Inst : *FreeInstrBB) {
if (&Inst == &FI || &Inst == FreeInstrBBTerminator)
diff --git a/llvm/lib/Transforms/Scalar/GVNSink.cpp
b/llvm/lib/Transforms/Scalar/GVNSink.cpp
index 94cc219a4a7..3aa74714414 100644
--- a/llvm/lib/Transforms/Scalar/GVNSink.cpp
+++ b/llvm/lib/Transforms/Scalar/GVNSink.cpp
@@ -133,6 +133,7 @@ public:
ActiveBlocks.insert(BB);
Insts.clear();
for (BasicBlock *BB : Blocks) {
+ // TODO
if (BB->size() <= 1) {
// Block wasn't big enough - only contained a terminator.
ActiveBlocks.remove(BB);
diff --git a/llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp
b/llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp
index 799f40d8724..4e6c35593e8 100644
--- a/llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp
+++ b/llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp
@@ -1488,6 +1488,7 @@ bool LoopIdiomRecognize::recognizePopcount() {
if (CurLoop->getNumBackEdges() != 1 || CurLoop->getNumBlocks() != 1)
return false;
+ // TODO
BasicBlock *LoopBody = *(CurLoop->block_begin());
if (LoopBody->size() >= 20) {
// The loop is too big, bail out.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>