[llvm] a4d3691 - Fix MSVC signed/unsigned comparison warning. NFCI.
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 13 02:21:06 PST 2020
Author: Simon Pilgrim
Date: 2020-11-13T10:20:48Z
New Revision: a4d3691d5530b53d195fe3073cbc301dfefe125d
URL: https://github.com/llvm/llvm-project/commit/a4d3691d5530b53d195fe3073cbc301dfefe125d
DIFF: https://github.com/llvm/llvm-project/commit/a4d3691d5530b53d195fe3073cbc301dfefe125d.diff
LOG: Fix MSVC signed/unsigned comparison warning. NFCI.
Added:
Modified:
llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp b/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp
index 5e87f2dd96cf..dc9c54e4aaac 100644
--- a/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp
+++ b/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp
@@ -1023,7 +1023,7 @@ void AMDGPUInstPrinter::printExpTgt(const MCInst *MI, unsigned OpNo,
else if (Tgt == Exp::ET_NULL)
O << " null";
else if (Tgt >= Exp::ET_POS0 &&
- Tgt <= (isGFX10(STI) ? Exp::ET_POS4 : Exp::ET_POS3))
+ Tgt <= uint32_t(isGFX10(STI) ? Exp::ET_POS4 : Exp::ET_POS3))
O << " pos" << Tgt - Exp::ET_POS0;
else if (isGFX10(STI) && Tgt == Exp::ET_PRIM)
O << " prim";
More information about the llvm-commits
mailing list