[llvm] 0bb49af - [AMDGPU] Fix an unused variable warning
Kazu Hirata via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 12 12:06:41 PDT 2023
Author: Kazu Hirata
Date: 2023-09-12T12:06:36-07:00
New Revision: 0bb49afeaf7c7278e9b5682ef3e24915f6adc956
URL: https://github.com/llvm/llvm-project/commit/0bb49afeaf7c7278e9b5682ef3e24915f6adc956
DIFF: https://github.com/llvm/llvm-project/commit/0bb49afeaf7c7278e9b5682ef3e24915f6adc956.diff
LOG: [AMDGPU] Fix an unused variable warning
This patch fixes:
llvm/lib/Target/AMDGPU/SIISelLowering.cpp:2493:33: error: unused
variable 'UserSGPRInfo' [-Werror,-Wunused-variable]
Added:
Modified:
llvm/lib/Target/AMDGPU/SIISelLowering.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Target/AMDGPU/SIISelLowering.cpp b/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
index 683fb5b2cd0b211..22a4d60cca39c67 100644
--- a/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
+++ b/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
@@ -2495,6 +2495,7 @@ SDValue SITargetLowering::LowerFormalArguments(
!UserSGPRInfo.hasKernargSegmentPtr() && !Info->hasWorkGroupInfo() &&
!Info->hasLDSKernelId() && !Info->hasWorkItemIDX() &&
!Info->hasWorkItemIDY() && !Info->hasWorkItemIDZ());
+ (void)UserSGPRInfo;
if (!Subtarget->enableFlatScratch())
assert(!UserSGPRInfo.hasFlatScratchInit());
if (CallConv != CallingConv::AMDGPU_CS || !Subtarget->hasArchitectedSGPRs())
More information about the llvm-commits
mailing list