From: Dan Gohman Date: Fri, 2 Dec 2016 20:13:05 +0000 (+0000) Subject: [WebAssembly] Fix a compiler warning. NFC. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=52e39958c8f9fab06d2b4c9549cc20019f92a8b4;p=llvm [WebAssembly] Fix a compiler warning. NFC. Fix a warning about a comparison between signed and unsigned integer expressions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288532 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/WebAssembly/WebAssemblyFrameLowering.cpp b/lib/Target/WebAssembly/WebAssemblyFrameLowering.cpp index 25b203abcd6..a6a2c0bf06a 100644 --- a/lib/Target/WebAssembly/WebAssemblyFrameLowering.cpp +++ b/lib/Target/WebAssembly/WebAssemblyFrameLowering.cpp @@ -194,7 +194,7 @@ void WebAssemblyFrameLowering::emitPrologue(MachineFunction &MF, if (HasBP) { unsigned BitmaskReg = MRI.createVirtualRegister(PtrRC); unsigned Alignment = MFI.getMaxAlignment(); - assert((1 << countTrailingZeros(Alignment)) == Alignment && + assert((1u << countTrailingZeros(Alignment)) == Alignment && "Alignment must be a power of 2"); BuildMI(MBB, InsertPt, DL, TII->get(WebAssembly::CONST_I32), BitmaskReg) .addImm((int)~(Alignment - 1));