Skip to content

Conversation

@pedroclobo
Copy link
Member

Replace undef debug info with poison.

Replace `undef` debug info with `poison`.
@llvmbot
Copy link
Member

llvmbot commented Mar 11, 2025

@llvm/pr-subscribers-backend-amdgpu

Author: Pedro Lobo (pedroclobo)

Changes

Replace undef debug info with poison.


Full diff: https://github.com/llvm/llvm-project/pull/130858.diff

1 Files Affected:

  • (modified) llvm/lib/Target/AMDGPU/AMDGPULowerBufferFatPointers.cpp (+1-1)
diff --git a/llvm/lib/Target/AMDGPU/AMDGPULowerBufferFatPointers.cpp b/llvm/lib/Target/AMDGPU/AMDGPULowerBufferFatPointers.cpp
index 608b43b59eed3..5dd1fe14e5626 100644
--- a/llvm/lib/Target/AMDGPU/AMDGPULowerBufferFatPointers.cpp
+++ b/llvm/lib/Target/AMDGPU/AMDGPULowerBufferFatPointers.cpp
@@ -1620,7 +1620,7 @@ void SplitPtrStructs::killAndReplaceSplitInstructions(
         Dbg->setExpression(*RsrcExpr);
         Dbg->replaceVariableLocationOp(I, Rsrc);
       } else {
-        Dbg->replaceVariableLocationOp(I, UndefValue::get(I->getType()));
+        Dbg->replaceVariableLocationOp(I, PoisonValue::get(I->getType()));
       }
     }
 

Copy link
Contributor

@shiltian shiltian left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No test case changes?

@pedroclobo
Copy link
Member Author

No test case changes?

All tests passed on my machine. I guess there is no test coverage for this code.

@pedroclobo pedroclobo merged commit 73e23f8 into llvm:main Mar 12, 2025
13 checks passed
@pedroclobo pedroclobo deleted the amd-debug-poison branch March 12, 2025 12:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants