[llvm] [DebugInfo][InferAddressSpaces] Fix the missing debug location update for the new addrspacecast (PR #97038)

Shan Huang via llvm-commits llvm-commits at lists.llvm.org
Fri Jun 28 06:08:41 PDT 2024


================
@@ -0,0 +1,34 @@
+; RUN: opt -S -mtriple=amdgcn-amd-amdhsa -passes=infer-address-spaces -o - %s | FileCheck %s
+
+; Check that InferAddressSpaces's cloneInstructionWithNewAddressSpace() propagates
+; the debug location to new addrspacecast instruction which casts `%p` in the following test.
+
+ at c0 = addrspace(4) global ptr undef
----------------
Apochens wrote:

Thanks for reviewing this.

https://github.com/llvm/llvm-project/pull/97038


More information about the llvm-commits mailing list