[llvm] a961ba8 - AMDGPU: Use reportFatalUsageError for LDS mixed absolute addresses (#145135)
via llvm-commits
llvm-commits at lists.llvm.org
Sat Jun 21 07:54:31 PDT 2025
Author: Matt Arsenault
Date: 2025-06-21T23:54:27+09:00
New Revision: a961ba88e1d48b8df1531d778e904efb2839662c
URL: https://github.com/llvm/llvm-project/commit/a961ba88e1d48b8df1531d778e904efb2839662c
DIFF: https://github.com/llvm/llvm-project/commit/a961ba88e1d48b8df1531d778e904efb2839662c.diff
LOG: AMDGPU: Use reportFatalUsageError for LDS mixed absolute addresses (#145135)
Added:
Modified:
llvm/lib/Target/AMDGPU/AMDGPUMemoryUtils.cpp
llvm/test/CodeGen/AMDGPU/lds-reject-mixed-absolute-addresses.ll
Removed:
################################################################################
diff --git a/llvm/lib/Target/AMDGPU/AMDGPUMemoryUtils.cpp b/llvm/lib/Target/AMDGPU/AMDGPUMemoryUtils.cpp
index 241dbd63eb5c0..aa72c3e61f680 100644
--- a/llvm/lib/Target/AMDGPU/AMDGPUMemoryUtils.cpp
+++ b/llvm/lib/Target/AMDGPU/AMDGPUMemoryUtils.cpp
@@ -278,8 +278,8 @@ LDSUsesInfoTy getTransitiveUsesOfLDS(const CallGraph &CG, Module &M) {
}
if (HasAbsoluteGVs.has_value()) {
if (*HasAbsoluteGVs != IsAbsolute) {
- report_fatal_error(
- "Module cannot mix absolute and non-absolute LDS GVs");
+ reportFatalUsageError(
+ "module cannot mix absolute and non-absolute LDS GVs");
}
} else
HasAbsoluteGVs = IsAbsolute;
diff --git a/llvm/test/CodeGen/AMDGPU/lds-reject-mixed-absolute-addresses.ll b/llvm/test/CodeGen/AMDGPU/lds-reject-mixed-absolute-addresses.ll
index e1ee9b2df9fa8..eacf6759b039a 100644
--- a/llvm/test/CodeGen/AMDGPU/lds-reject-mixed-absolute-addresses.ll
+++ b/llvm/test/CodeGen/AMDGPU/lds-reject-mixed-absolute-addresses.ll
@@ -1,10 +1,10 @@
-; RUN: not --crash opt -S -mtriple=amdgcn-- -amdgpu-lower-module-lds < %s 2>&1 | FileCheck %s
-; RUN: not --crash opt -S -mtriple=amdgcn-- -passes=amdgpu-lower-module-lds < %s 2>&1 | FileCheck %s
+; RUN: not opt -S -mtriple=amdgcn-- -amdgpu-lower-module-lds < %s 2>&1 | FileCheck %s
+; RUN: not opt -S -mtriple=amdgcn-- -passes=amdgpu-lower-module-lds < %s 2>&1 | FileCheck %s
@var1 = addrspace(3) global i32 poison, !absolute_symbol !0
@var2 = addrspace(3) global i32 poison
-; CHECK: Module cannot mix absolute and non-absolute LDS GVs
+; CHECK: LLVM ERROR: module cannot mix absolute and non-absolute LDS GVs
define amdgpu_kernel void @kern() {
%val0 = load i32, ptr addrspace(3) @var1
%val1 = add i32 %val0, 4
More information about the llvm-commits
mailing list