diff --git a/lib/Target/Mips/Mips16InstrInfo.td b/lib/Target/Mips/Mips16InstrInfo.td index 840dfde650a..8d8b2ed20b9 100644 --- a/lib/Target/Mips/Mips16InstrInfo.td +++ b/lib/Target/Mips/Mips16InstrInfo.td @@ -119,6 +119,7 @@ class FJAL16_ins _X, string asmstr, !strconcat(asmstr, "\t$imm\n\tnop"),[], itin> { let isCodeGenOnly=1; + let Size=6; } class FJALB16_ins _X, string asmstr, @@ -127,6 +128,7 @@ class FJALB16_ins _X, string asmstr, !strconcat(asmstr, "\t$imm\t# branch\n\tnop"),[], itin> { let isCodeGenOnly=1; + let Size=6; } // diff --git a/lib/Target/Mips/MipsConstantIslandPass.cpp b/lib/Target/Mips/MipsConstantIslandPass.cpp index 334327d3f5b..8f607b057d2 100644 --- a/lib/Target/Mips/MipsConstantIslandPass.cpp +++ b/lib/Target/Mips/MipsConstantIslandPass.cpp @@ -790,11 +790,11 @@ initializeFunctionInfo(const std::vector &CPEMIs) { Bits = 8; Scale = 4; LongFormOpcode = Mips::LwRxPcTcpX16; - LongFormBits = 16; + LongFormBits = 14; LongFormScale = 1; break; case Mips::LwRxPcTcpX16: - Bits = 16; + Bits = 14; Scale = 1; NegOk = true; break; diff --git a/test/CodeGen/Mips/const6a.ll b/test/CodeGen/Mips/const6a.ll index 8b402accc7d..d3423905873 100644 --- a/test/CodeGen/Mips/const6a.ll +++ b/test/CodeGen/Mips/const6a.ll @@ -19,7 +19,7 @@ entry: ; load-relax: $CPI0_0: ; load-relax: .4byte 3735943886 ; load-relax: .end t - call void asm sideeffect ".space 40000", ""() #1, !srcloc !1 + call void asm sideeffect ".space 10000", ""() #1, !srcloc !1 ret void }