diff options
| author | YunQiang Su <syq@debian.org> | 2026-02-05 17:09:22 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-02-05 17:09:22 +0800 |
| commit | 209ff8bf06dd12becd79c1ebb01612c021e19f6c (patch) | |
| tree | 5ece758005d928bea37782633252d5831d02b6e2 /mlir/lib/Interfaces/FunctionImplementation.cpp | |
| parent | 8949c6d86b65f6a315cd295f955fdf2e4510f7c4 (diff) | |
| download | llvm-209ff8bf06dd12becd79c1ebb01612c021e19f6c.zip llvm-209ff8bf06dd12becd79c1ebb01612c021e19f6c.tar.gz llvm-209ff8bf06dd12becd79c1ebb01612c021e19f6c.tar.bz2 | |
MIPS: Fix unsigned compare with zero in MipsSEInstrInfo::copyPhysReg (#179866)
SrcRegOff >= 0 is not needed at all for unsigned.
This fixes the warning:
```
llvm/lib/Target/Mips/MipsSEInstrInfo.cpp: In member function ‘virtual void llvm::MipsSEInstrInfo::copyPhysReg(llvm::MachineBasicBlock&, llvm::MachineBasicBlock::iterator, const llvm::DebugLoc&, llvm::Register, llvm::Register, bool, bool, bool) const’:
llvm/lib/Target/Mips/MipsSEInstrInfo.cpp:245:48: warning: comparison of unsigned expression in ‘>= 0’ is always true [-Wtype-limits]
245 | if (SrcRegOff == DestRegOff && SrcRegOff >= 0 && SrcRegOff <= 31)
| ~~~~~~~~~~^~~~
llvm/lib/Target/Mips/MipsSEInstrInfo.cpp:256:48: warning: comparison of unsigned expression in ‘>= 0’ is always true [-Wtype-limits]
256 | if (SrcRegOff == DestRegOff && SrcRegOff >= 0 && SrcRegOff <= 31)
```
Diffstat (limited to 'mlir/lib/Interfaces/FunctionImplementation.cpp')
0 files changed, 0 insertions, 0 deletions
