[llvm] r269862 - [WebAssembly] Rename $discard to $drop in the assembly output.
Dan Gohman via llvm-commits
llvm-commits at lists.llvm.org
Tue May 17 16:19:05 PDT 2016
Author: djg
Date: Tue May 17 18:19:03 2016
New Revision: 269862
URL: http://llvm.org/viewvc/llvm-project?rev=269862&view=rev
Log:
[WebAssembly] Rename $discard to $drop in the assembly output.
Modified:
llvm/trunk/lib/Target/WebAssembly/InstPrinter/WebAssemblyInstPrinter.cpp
llvm/trunk/lib/Target/WebAssembly/WebAssemblyFrameLowering.cpp
llvm/trunk/lib/Target/WebAssembly/WebAssemblyPeephole.cpp
llvm/trunk/lib/Target/WebAssembly/WebAssemblyRegColoring.cpp
llvm/trunk/test/CodeGen/WebAssembly/address-offsets.ll
llvm/trunk/test/CodeGen/WebAssembly/byval.ll
llvm/trunk/test/CodeGen/WebAssembly/cfg-stackify.ll
llvm/trunk/test/CodeGen/WebAssembly/i32-load-store-alignment.ll
llvm/trunk/test/CodeGen/WebAssembly/i64-load-store-alignment.ll
llvm/trunk/test/CodeGen/WebAssembly/inline-asm.ll
llvm/trunk/test/CodeGen/WebAssembly/load-store-i1.ll
llvm/trunk/test/CodeGen/WebAssembly/mem-intrinsics.ll
llvm/trunk/test/CodeGen/WebAssembly/offset.ll
llvm/trunk/test/CodeGen/WebAssembly/reg-stackify.ll
llvm/trunk/test/CodeGen/WebAssembly/returned.ll
llvm/trunk/test/CodeGen/WebAssembly/store-results.ll
llvm/trunk/test/CodeGen/WebAssembly/store-trunc.ll
llvm/trunk/test/CodeGen/WebAssembly/store.ll
llvm/trunk/test/CodeGen/WebAssembly/unused-argument.ll
llvm/trunk/test/CodeGen/WebAssembly/userstack.ll
llvm/trunk/test/CodeGen/WebAssembly/varargs.ll
Modified: llvm/trunk/lib/Target/WebAssembly/InstPrinter/WebAssemblyInstPrinter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/WebAssembly/InstPrinter/WebAssemblyInstPrinter.cpp?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/lib/Target/WebAssembly/InstPrinter/WebAssemblyInstPrinter.cpp (original)
+++ llvm/trunk/lib/Target/WebAssembly/InstPrinter/WebAssemblyInstPrinter.cpp Tue May 17 18:19:03 2016
@@ -149,7 +149,7 @@ void WebAssemblyInstPrinter::printOperan
else if (WAReg != WebAssemblyFunctionInfo::UnusedReg)
O << "$push" << (WAReg & INT32_MAX);
else
- O << "$discard";
+ O << "$drop";
// Add a '=' suffix if this is a def.
if (OpNo < MII.get(MI->getOpcode()).getNumDefs())
O << '=';
Modified: llvm/trunk/lib/Target/WebAssembly/WebAssemblyFrameLowering.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/WebAssembly/WebAssemblyFrameLowering.cpp?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/lib/Target/WebAssembly/WebAssemblyFrameLowering.cpp (original)
+++ llvm/trunk/lib/Target/WebAssembly/WebAssemblyFrameLowering.cpp Tue May 17 18:19:03 2016
@@ -88,7 +88,7 @@ static void writeSPToMemory(unsigned Src
const TargetRegisterClass *PtrRC =
MRI.getTargetRegisterInfo()->getPointerRegClass(MF);
unsigned SPAddr = MRI.createVirtualRegister(PtrRC);
- unsigned Discard = MRI.createVirtualRegister(PtrRC);
+ unsigned Drop = MRI.createVirtualRegister(PtrRC);
const auto *TII = MF.getSubtarget<WebAssemblySubtarget>().getInstrInfo();
BuildMI(MBB, InsertAddr, DL, TII->get(WebAssembly::CONST_I32), SPAddr)
@@ -96,8 +96,7 @@ static void writeSPToMemory(unsigned Src
auto *MMO = new MachineMemOperand(MachinePointerInfo(MF.getPSVManager()
.getExternalSymbolCallEntry(ES)),
MachineMemOperand::MOStore, 4, 4);
- BuildMI(MBB, InsertStore, DL, TII->get(WebAssembly::STORE_I32),
- Discard)
+ BuildMI(MBB, InsertStore, DL, TII->get(WebAssembly::STORE_I32), Drop)
.addImm(0)
.addReg(SPAddr)
.addImm(2) // p2align
Modified: llvm/trunk/lib/Target/WebAssembly/WebAssemblyPeephole.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/WebAssembly/WebAssemblyPeephole.cpp?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/lib/Target/WebAssembly/WebAssemblyPeephole.cpp (original)
+++ llvm/trunk/lib/Target/WebAssembly/WebAssemblyPeephole.cpp Tue May 17 18:19:03 2016
@@ -55,11 +55,11 @@ static const TargetRegisterClass *GetReg
: MRI.getTargetRegisterInfo()->getMinimalPhysRegClass(RegNo);
}
-/// If desirable, rewrite NewReg to a discard register.
-static bool MaybeRewriteToDiscard(unsigned OldReg, unsigned NewReg,
- MachineOperand &MO,
- WebAssemblyFunctionInfo &MFI,
- MachineRegisterInfo &MRI) {
+/// If desirable, rewrite NewReg to a drop register.
+static bool MaybeRewriteToDrop(unsigned OldReg, unsigned NewReg,
+ MachineOperand &MO,
+ WebAssemblyFunctionInfo &MFI,
+ MachineRegisterInfo &MRI) {
bool Changed = false;
if (OldReg == NewReg) {
Changed = true;
@@ -101,12 +101,12 @@ bool WebAssemblyPeephole::runOnMachineFu
case WebAssembly::STORE_I64: {
// Store instructions return their value operand. If we ended up using
// the same register for both, replace it with a dead def so that it
- // can use $discard instead.
+ // can use $drop instead.
MachineOperand &MO = MI.getOperand(0);
unsigned OldReg = MO.getReg();
unsigned NewReg =
MI.getOperand(WebAssembly::StoreValueOperandNo).getReg();
- Changed |= MaybeRewriteToDiscard(OldReg, NewReg, MO, MFI, MRI);
+ Changed |= MaybeRewriteToDrop(OldReg, NewReg, MO, MFI, MRI);
break;
}
case WebAssembly::CALL_I32:
@@ -130,7 +130,7 @@ bool WebAssemblyPeephole::runOnMachineFu
if (GetRegClass(MRI, NewReg) != GetRegClass(MRI, OldReg))
report_fatal_error("Peephole: call to builtin function with "
"wrong signature, from/to mismatch");
- Changed |= MaybeRewriteToDiscard(OldReg, NewReg, MO, MFI, MRI);
+ Changed |= MaybeRewriteToDrop(OldReg, NewReg, MO, MFI, MRI);
}
}
}
Modified: llvm/trunk/lib/Target/WebAssembly/WebAssemblyRegColoring.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/WebAssembly/WebAssemblyRegColoring.cpp?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/lib/Target/WebAssembly/WebAssemblyRegColoring.cpp (original)
+++ llvm/trunk/lib/Target/WebAssembly/WebAssemblyRegColoring.cpp Tue May 17 18:19:03 2016
@@ -99,7 +99,7 @@ bool WebAssemblyRegColoring::runOnMachin
unsigned VReg = TargetRegisterInfo::index2VirtReg(i);
if (MFI.isVRegStackified(VReg))
continue;
- // Skip unused registers, which can use $discard.
+ // Skip unused registers, which can use $drop.
if (MRI->use_empty(VReg))
continue;
Modified: llvm/trunk/test/CodeGen/WebAssembly/address-offsets.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/address-offsets.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/address-offsets.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/address-offsets.ll Tue May 17 18:19:03 2016
@@ -353,7 +353,7 @@ define i32 @load_test21(i32* %p, i32 %n)
; CHECK-LABEL: store_test0:
; CHECK-NEXT: param i32{{$}}
; CHECK-NEXT: i32.const $push0=, 0{{$}}
-; CHECK-NEXT: i32.store $discard=, g+40($pop0), $0{{$}}
+; CHECK-NEXT: i32.store $drop=, g+40($pop0), $0{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test0(i32 %i) {
store i32 %i, i32* getelementptr inbounds ([0 x i32], [0 x i32]* @g, i32 0, i32 10), align 4
@@ -363,7 +363,7 @@ define void @store_test0(i32 %i) {
; CHECK-LABEL: store_test0_noinbounds:
; CHECK-NEXT: param i32{{$}}
; CHECK-NEXT: i32.const $push0=, 0{{$}}
-; CHECK-NEXT: i32.store $discard=, g+40($pop0), $0{{$}}
+; CHECK-NEXT: i32.store $drop=, g+40($pop0), $0{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test0_noinbounds(i32 %i) {
store i32 %i, i32* getelementptr ([0 x i32], [0 x i32]* @g, i32 0, i32 10), align 4
@@ -374,7 +374,7 @@ define void @store_test0_noinbounds(i32
; CHECK-NEXT: param i32, i32{{$}}
; CHECK-NEXT: i32.const $push0=, 2{{$}}
; CHECK-NEXT: i32.shl $push1=, $0, $pop0{{$}}
-; CHECK-NEXT: i32.store $discard=, g+40($pop1), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, g+40($pop1), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test1(i32 %n, i32 %i) {
%add = add nsw i32 %n, 10
@@ -387,7 +387,7 @@ define void @store_test1(i32 %n, i32 %i)
; CHECK-NEXT: param i32, i32{{$}}
; CHECK-NEXT: i32.const $push0=, 2{{$}}
; CHECK-NEXT: i32.shl $push1=, $0, $pop0{{$}}
-; CHECK-NEXT: i32.store $discard=, g+40($pop1), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, g+40($pop1), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test2(i32 %n, i32 %i) {
%add = add nsw i32 10, %n
@@ -400,7 +400,7 @@ define void @store_test2(i32 %n, i32 %i)
; CHECK-NEXT: param i32, i32{{$}}
; CHECK-NEXT: i32.const $push0=, 2{{$}}
; CHECK-NEXT: i32.shl $push1=, $0, $pop0{{$}}
-; CHECK-NEXT: i32.store $discard=, g+40($pop1), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, g+40($pop1), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test3(i32 %n, i32 %i) {
%add.ptr = getelementptr inbounds [0 x i32], [0 x i32]* @g, i32 0, i32 %n
@@ -413,7 +413,7 @@ define void @store_test3(i32 %n, i32 %i)
; CHECK-NEXT: param i32, i32{{$}}
; CHECK-NEXT: i32.const $push0=, 2{{$}}
; CHECK-NEXT: i32.shl $push1=, $0, $pop0{{$}}
-; CHECK-NEXT: i32.store $discard=, g+40($pop1), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, g+40($pop1), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test4(i32 %n, i32 %i) {
%add.ptr = getelementptr inbounds i32, i32* getelementptr inbounds ([0 x i32], [0 x i32]* @g, i32 0, i32 10), i32 %n
@@ -425,7 +425,7 @@ define void @store_test4(i32 %n, i32 %i)
; CHECK-NEXT: param i32, i32{{$}}
; CHECK-NEXT: i32.const $push0=, 2{{$}}
; CHECK-NEXT: i32.shl $push1=, $0, $pop0{{$}}
-; CHECK-NEXT: i32.store $discard=, g+40($pop1), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, g+40($pop1), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test5(i32 %n, i32 %i) {
%add.ptr = getelementptr inbounds i32, i32* getelementptr inbounds ([0 x i32], [0 x i32]* @g, i32 0, i32 10), i32 %n
@@ -437,7 +437,7 @@ define void @store_test5(i32 %n, i32 %i)
; CHECK-NEXT: param i32, i32{{$}}
; CHECK-NEXT: i32.const $push0=, 2{{$}}
; CHECK-NEXT: i32.shl $push1=, $0, $pop0{{$}}
-; CHECK-NEXT: i32.store $discard=, g+40($pop1), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, g+40($pop1), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test6(i32 %n, i32 %i) {
%add = add nsw i32 %n, 10
@@ -450,7 +450,7 @@ define void @store_test6(i32 %n, i32 %i)
; CHECK-NEXT: param i32, i32{{$}}
; CHECK-NEXT: i32.const $push0=, 2{{$}}
; CHECK-NEXT: i32.shl $push1=, $0, $pop0{{$}}
-; CHECK-NEXT: i32.store $discard=, g+40($pop1), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, g+40($pop1), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test7(i32 %n, i32 %i) {
%add.ptr = getelementptr inbounds [0 x i32], [0 x i32]* @g, i32 0, i32 %n
@@ -463,7 +463,7 @@ define void @store_test7(i32 %n, i32 %i)
; CHECK-NEXT: param i32, i32{{$}}
; CHECK-NEXT: i32.const $push0=, 2{{$}}
; CHECK-NEXT: i32.shl $push1=, $0, $pop0{{$}}
-; CHECK-NEXT: i32.store $discard=, g+40($pop1), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, g+40($pop1), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test8(i32 %n, i32 %i) {
%add = add nsw i32 10, %n
@@ -475,7 +475,7 @@ define void @store_test8(i32 %n, i32 %i)
; CHECK-LABEL: store_test9:
; CHECK-NEXT: param i32{{$}}
; CHECK-NEXT: i32.const $push0=, 0{{$}}
-; CHECK-NEXT: i32.store $discard=, g-40($pop0), $0{{$}}
+; CHECK-NEXT: i32.store $drop=, g-40($pop0), $0{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test9(i32 %i) {
store i32 %i, i32* getelementptr inbounds ([0 x i32], [0 x i32]* @g, i32 0, i32 1073741814), align 4
@@ -488,7 +488,7 @@ define void @store_test9(i32 %i) {
; CHECK-NEXT: i32.shl $push1=, $0, $pop0{{$}}
; CHECK-NEXT: i32.const $push2=, g-40{{$}}
; CHECK-NEXT: i32.add $push3=, $pop1, $pop2{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($pop3), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($pop3), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test10(i32 %n, i32 %i) {
%add = add nsw i32 %n, -10
@@ -499,7 +499,7 @@ define void @store_test10(i32 %n, i32 %i
; CHECK-LABEL: store_test11:
; CHECK-NEXT: param i32, i32{{$}}
-; CHECK-NEXT: i32.store $discard=, 40($0), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, 40($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test11(i32* %p, i32 %i) {
%arrayidx = getelementptr inbounds i32, i32* %p, i32 10
@@ -511,7 +511,7 @@ define void @store_test11(i32* %p, i32 %
; CHECK-NEXT: param i32, i32{{$}}
; CHECK-NEXT: i32.const $push0=, 40{{$}}
; CHECK-NEXT: i32.add $push1=, $0, $pop0{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($pop1), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($pop1), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test11_noinbounds(i32* %p, i32 %i) {
%arrayidx = getelementptr i32, i32* %p, i32 10
@@ -526,7 +526,7 @@ define void @store_test11_noinbounds(i32
; CHECK-NEXT: i32.add $push2=, $0, $pop1{{$}}
; CHECK-NEXT: i32.const $push3=, 40{{$}}
; CHECK-NEXT: i32.add $push4=, $pop2, $pop3{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($pop4), $2{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($pop4), $2{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test12(i32* %p, i32 %n, i32 %i) {
%add = add nsw i32 %n, 10
@@ -542,7 +542,7 @@ define void @store_test12(i32* %p, i32 %
; CHECK-NEXT: i32.add $push2=, $0, $pop1{{$}}
; CHECK-NEXT: i32.const $push3=, 40{{$}}
; CHECK-NEXT: i32.add $push4=, $pop2, $pop3{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($pop4), $2{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($pop4), $2{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test13(i32* %p, i32 %n, i32 %i) {
%add = add nsw i32 10, %n
@@ -556,7 +556,7 @@ define void @store_test13(i32* %p, i32 %
; CHECK-NEXT: i32.const $push0=, 2{{$}}
; CHECK-NEXT: i32.shl $push1=, $1, $pop0{{$}}
; CHECK-NEXT: i32.add $push2=, $0, $pop1{{$}}
-; CHECK-NEXT: i32.store $discard=, 40($pop2), $2{{$}}
+; CHECK-NEXT: i32.store $drop=, 40($pop2), $2{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test14(i32* %p, i32 %n, i32 %i) {
%add.ptr = getelementptr inbounds i32, i32* %p, i32 %n
@@ -572,7 +572,7 @@ define void @store_test14(i32* %p, i32 %
; CHECK-NEXT: i32.add $push2=, $0, $pop1{{$}}
; CHECK-NEXT: i32.const $push3=, 40{{$}}
; CHECK-NEXT: i32.add $push4=, $pop2, $pop3{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($pop4), $2{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($pop4), $2{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test15(i32* %p, i32 %n, i32 %i) {
%add.ptr = getelementptr inbounds i32, i32* %p, i32 10
@@ -588,7 +588,7 @@ define void @store_test15(i32* %p, i32 %
; CHECK-NEXT: i32.add $push2=, $0, $pop1{{$}}
; CHECK-NEXT: i32.const $push3=, 40{{$}}
; CHECK-NEXT: i32.add $push4=, $pop2, $pop3{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($pop4), $2{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($pop4), $2{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test16(i32* %p, i32 %n, i32 %i) {
%add.ptr = getelementptr inbounds i32, i32* %p, i32 10
@@ -604,7 +604,7 @@ define void @store_test16(i32* %p, i32 %
; CHECK-NEXT: i32.add $push2=, $0, $pop1{{$}}
; CHECK-NEXT: i32.const $push3=, 40{{$}}
; CHECK-NEXT: i32.add $push4=, $pop2, $pop3{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($pop4), $2{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($pop4), $2{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test17(i32* %p, i32 %n, i32 %i) {
%add = add nsw i32 %n, 10
@@ -618,7 +618,7 @@ define void @store_test17(i32* %p, i32 %
; CHECK-NEXT: i32.const $push0=, 2{{$}}
; CHECK-NEXT: i32.shl $push1=, $1, $pop0{{$}}
; CHECK-NEXT: i32.add $push2=, $0, $pop1{{$}}
-; CHECK-NEXT: i32.store $discard=, 40($pop2), $2{{$}}
+; CHECK-NEXT: i32.store $drop=, 40($pop2), $2{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test18(i32* %p, i32 %n, i32 %i) {
%add.ptr = getelementptr inbounds i32, i32* %p, i32 %n
@@ -634,7 +634,7 @@ define void @store_test18(i32* %p, i32 %
; CHECK-NEXT: i32.add $push2=, $0, $pop1{{$}}
; CHECK-NEXT: i32.const $push3=, 40{{$}}
; CHECK-NEXT: i32.add $push4=, $pop2, $pop3{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($pop4), $2{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($pop4), $2{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test19(i32* %p, i32 %n, i32 %i) {
%add = add nsw i32 10, %n
@@ -647,7 +647,7 @@ define void @store_test19(i32* %p, i32 %
; CHECK-NEXT: param i32, i32{{$}}
; CHECK-NEXT: i32.const $push0=, -40{{$}}
; CHECK-NEXT: i32.add $push1=, $0, $pop0{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($pop1), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($pop1), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test20(i32* %p, i32 %i) {
%arrayidx = getelementptr inbounds i32, i32* %p, i32 -10
@@ -662,7 +662,7 @@ define void @store_test20(i32* %p, i32 %
; CHECK-NEXT: i32.add $push2=, $0, $pop1{{$}}
; CHECK-NEXT: i32.const $push3=, -40{{$}}
; CHECK-NEXT: i32.add $push4=, $pop2, $pop3{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($pop4), $2{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($pop4), $2{{$}}
; CHECK-NEXT: return{{$}}
define void @store_test21(i32* %p, i32 %n, i32 %i) {
%add = add nsw i32 %n, -10
Modified: llvm/trunk/test/CodeGen/WebAssembly/byval.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/byval.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/byval.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/byval.ll Tue May 17 18:19:03 2016
@@ -34,7 +34,7 @@ define void @byval_arg(%SmallStruct* %pt
; CHECK-NEXT: tee_local $push[[L11:.+]]=, $[[SP:.+]]=, $pop[[L12]]{{$}}
; Copy the SmallStruct argument to the stack (SP+12, original SP-4)
; CHECK-NEXT: i32.load $push[[L0:.+]]=, 0($0)
- ; CHECK-NEXT: i32.store $discard=, 12($pop[[L11]]), $pop[[L0]]
+ ; CHECK-NEXT: i32.store $drop=, 12($pop[[L11]]), $pop[[L0]]
; Pass a pointer to the stack slot to the function
; CHECK-NEXT: i32.const $push[[L5:.+]]=, 12{{$}}
; CHECK-NEXT: i32.add $push[[ARG:.+]]=, $[[SP]], $pop[[L5]]{{$}}
@@ -59,7 +59,7 @@ define void @byval_arg_align8(%SmallStru
; CHECK-NEXT: tee_local $push[[L11:.+]]=, $[[SP:.+]]=, $pop[[L12]]{{$}}
; Copy the SmallStruct argument to the stack (SP+8, original SP-8)
; CHECK-NEXT: i32.load $push[[L0:.+]]=, 0($0){{$}}
- ; CHECK-NEXT: i32.store $discard=, 8($pop[[L11]]), $pop[[L0]]{{$}}
+ ; CHECK-NEXT: i32.store $drop=, 8($pop[[L11]]), $pop[[L0]]{{$}}
; Pass a pointer to the stack slot to the function
; CHECK-NEXT: i32.const $push[[L5:.+]]=, 8{{$}}
; CHECK-NEXT: i32.add $push[[ARG:.+]]=, $[[SP]], $pop[[L5]]{{$}}
@@ -79,7 +79,7 @@ define void @byval_arg_double(%AlignedSt
; Copy the AlignedStruct argument to the stack (SP+0, original SP-16)
; Just check the last load/store pair of the memcpy
; CHECK: i64.load $push[[L4:.+]]=, 0($0)
- ; CHECK-NEXT: i64.store $discard=, 0($[[SP]]), $pop[[L4]]
+ ; CHECK-NEXT: i64.store $drop=, 0($[[SP]]), $pop[[L4]]
; Pass a pointer to the stack slot to the function
; CHECK-NEXT: call ext_byval_func_alignedstruct at FUNCTION, $[[SP]]
tail call void @ext_byval_func_alignedstruct(%AlignedStruct* byval %ptr)
Modified: llvm/trunk/test/CodeGen/WebAssembly/cfg-stackify.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/cfg-stackify.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/cfg-stackify.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/cfg-stackify.ll Tue May 17 18:19:03 2016
@@ -275,13 +275,13 @@ entry:
; CHECK-LABEL: minimal_loop:
; CHECK-NOT: br
; CHECK: .LBB7_1:
-; CHECK: i32.store $discard=, 0($0), $pop{{[0-9]+}}{{$}}
+; CHECK: i32.store $drop=, 0($0), $pop{{[0-9]+}}{{$}}
; CHECK: br 0{{$}}
; CHECK: .LBB7_2:
; OPT-LABEL: minimal_loop:
; OPT-NOT: br
; OPT: .LBB7_1:
-; OPT: i32.store $discard=, 0($0), $pop{{[0-9]+}}{{$}}
+; OPT: i32.store $drop=, 0($0), $pop{{[0-9]+}}{{$}}
; OPT: br 0{{$}}
; OPT: .LBB7_2:
define i32 @minimal_loop(i32* %p) {
Modified: llvm/trunk/test/CodeGen/WebAssembly/i32-load-store-alignment.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/i32-load-store-alignment.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/i32-load-store-alignment.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/i32-load-store-alignment.ll Tue May 17 18:19:03 2016
@@ -117,7 +117,7 @@ define i16 @ldi16_a4(i16 *%p) {
; CHECK-LABEL: sti32_a1:
; CHECK-NEXT: .param i32, i32{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($0):p2align=0, $1{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($0):p2align=0, $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti32_a1(i32 *%p, i32 %v) {
store i32 %v, i32* %p, align 1
@@ -126,7 +126,7 @@ define void @sti32_a1(i32 *%p, i32 %v) {
; CHECK-LABEL: sti32_a2:
; CHECK-NEXT: .param i32, i32{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($0):p2align=1, $1{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($0):p2align=1, $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti32_a2(i32 *%p, i32 %v) {
store i32 %v, i32* %p, align 2
@@ -137,7 +137,7 @@ define void @sti32_a2(i32 *%p, i32 %v) {
; CHECK-LABEL: sti32_a4:
; CHECK-NEXT: .param i32, i32{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti32_a4(i32 *%p, i32 %v) {
store i32 %v, i32* %p, align 4
@@ -148,7 +148,7 @@ define void @sti32_a4(i32 *%p, i32 %v) {
; CHECK-LABEL: sti32:
; CHECK-NEXT: .param i32, i32{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti32(i32 *%p, i32 %v) {
store i32 %v, i32* %p
@@ -157,7 +157,7 @@ define void @sti32(i32 *%p, i32 %v) {
; CHECK-LABEL: sti32_a8:
; CHECK-NEXT: .param i32, i32{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti32_a8(i32 *%p, i32 %v) {
store i32 %v, i32* %p, align 8
@@ -168,7 +168,7 @@ define void @sti32_a8(i32 *%p, i32 %v) {
; CHECK-LABEL: sti8_a1:
; CHECK-NEXT: .param i32, i32{{$}}
-; CHECK-NEXT: i32.store8 $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i32.store8 $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti8_a1(i8 *%p, i8 %v) {
store i8 %v, i8* %p, align 1
@@ -177,7 +177,7 @@ define void @sti8_a1(i8 *%p, i8 %v) {
; CHECK-LABEL: sti8_a2:
; CHECK-NEXT: .param i32, i32{{$}}
-; CHECK-NEXT: i32.store8 $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i32.store8 $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti8_a2(i8 *%p, i8 %v) {
store i8 %v, i8* %p, align 2
@@ -186,7 +186,7 @@ define void @sti8_a2(i8 *%p, i8 %v) {
; CHECK-LABEL: sti16_a1:
; CHECK-NEXT: .param i32, i32{{$}}
-; CHECK-NEXT: i32.store16 $discard=, 0($0):p2align=0, $1{{$}}
+; CHECK-NEXT: i32.store16 $drop=, 0($0):p2align=0, $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti16_a1(i16 *%p, i16 %v) {
store i16 %v, i16* %p, align 1
@@ -195,7 +195,7 @@ define void @sti16_a1(i16 *%p, i16 %v) {
; CHECK-LABEL: sti16_a2:
; CHECK-NEXT: .param i32, i32{{$}}
-; CHECK-NEXT: i32.store16 $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i32.store16 $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti16_a2(i16 *%p, i16 %v) {
store i16 %v, i16* %p, align 2
@@ -204,7 +204,7 @@ define void @sti16_a2(i16 *%p, i16 %v) {
; CHECK-LABEL: sti16_a4:
; CHECK-NEXT: .param i32, i32{{$}}
-; CHECK-NEXT: i32.store16 $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i32.store16 $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti16_a4(i16 *%p, i16 %v) {
store i16 %v, i16* %p, align 4
Modified: llvm/trunk/test/CodeGen/WebAssembly/i64-load-store-alignment.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/i64-load-store-alignment.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/i64-load-store-alignment.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/i64-load-store-alignment.ll Tue May 17 18:19:03 2016
@@ -176,7 +176,7 @@ define i64 @ldi32_a8(i32 *%p) {
; CHECK-LABEL: sti64_a1:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store $discard=, 0($0):p2align=0, $1{{$}}
+; CHECK-NEXT: i64.store $drop=, 0($0):p2align=0, $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti64_a1(i64 *%p, i64 %v) {
store i64 %v, i64* %p, align 1
@@ -185,7 +185,7 @@ define void @sti64_a1(i64 *%p, i64 %v) {
; CHECK-LABEL: sti64_a2:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store $discard=, 0($0):p2align=1, $1{{$}}
+; CHECK-NEXT: i64.store $drop=, 0($0):p2align=1, $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti64_a2(i64 *%p, i64 %v) {
store i64 %v, i64* %p, align 2
@@ -194,7 +194,7 @@ define void @sti64_a2(i64 *%p, i64 %v) {
; CHECK-LABEL: sti64_a4:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store $discard=, 0($0):p2align=2, $1{{$}}
+; CHECK-NEXT: i64.store $drop=, 0($0):p2align=2, $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti64_a4(i64 *%p, i64 %v) {
store i64 %v, i64* %p, align 4
@@ -205,7 +205,7 @@ define void @sti64_a4(i64 *%p, i64 %v) {
; CHECK-LABEL: sti64_a8:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i64.store $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti64_a8(i64 *%p, i64 %v) {
store i64 %v, i64* %p, align 8
@@ -216,7 +216,7 @@ define void @sti64_a8(i64 *%p, i64 %v) {
; CHECK-LABEL: sti64:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i64.store $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti64(i64 *%p, i64 %v) {
store i64 %v, i64* %p
@@ -225,7 +225,7 @@ define void @sti64(i64 *%p, i64 %v) {
; CHECK-LABEL: sti64_a16:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i64.store $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti64_a16(i64 *%p, i64 %v) {
store i64 %v, i64* %p, align 16
@@ -236,7 +236,7 @@ define void @sti64_a16(i64 *%p, i64 %v)
; CHECK-LABEL: sti8_a1:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store8 $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i64.store8 $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti8_a1(i8 *%p, i64 %w) {
%v = trunc i64 %w to i8
@@ -246,7 +246,7 @@ define void @sti8_a1(i8 *%p, i64 %w) {
; CHECK-LABEL: sti8_a2:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store8 $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i64.store8 $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti8_a2(i8 *%p, i64 %w) {
%v = trunc i64 %w to i8
@@ -256,7 +256,7 @@ define void @sti8_a2(i8 *%p, i64 %w) {
; CHECK-LABEL: sti16_a1:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store16 $discard=, 0($0):p2align=0, $1{{$}}
+; CHECK-NEXT: i64.store16 $drop=, 0($0):p2align=0, $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti16_a1(i16 *%p, i64 %w) {
%v = trunc i64 %w to i16
@@ -266,7 +266,7 @@ define void @sti16_a1(i16 *%p, i64 %w) {
; CHECK-LABEL: sti16_a2:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store16 $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i64.store16 $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti16_a2(i16 *%p, i64 %w) {
%v = trunc i64 %w to i16
@@ -276,7 +276,7 @@ define void @sti16_a2(i16 *%p, i64 %w) {
; CHECK-LABEL: sti16_a4:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store16 $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i64.store16 $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti16_a4(i16 *%p, i64 %w) {
%v = trunc i64 %w to i16
@@ -286,7 +286,7 @@ define void @sti16_a4(i16 *%p, i64 %w) {
; CHECK-LABEL: sti32_a1:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store32 $discard=, 0($0):p2align=0, $1{{$}}
+; CHECK-NEXT: i64.store32 $drop=, 0($0):p2align=0, $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti32_a1(i32 *%p, i64 %w) {
%v = trunc i64 %w to i32
@@ -296,7 +296,7 @@ define void @sti32_a1(i32 *%p, i64 %w) {
; CHECK-LABEL: sti32_a2:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store32 $discard=, 0($0):p2align=1, $1{{$}}
+; CHECK-NEXT: i64.store32 $drop=, 0($0):p2align=1, $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti32_a2(i32 *%p, i64 %w) {
%v = trunc i64 %w to i32
@@ -306,7 +306,7 @@ define void @sti32_a2(i32 *%p, i64 %w) {
; CHECK-LABEL: sti32_a4:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store32 $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i64.store32 $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti32_a4(i32 *%p, i64 %w) {
%v = trunc i64 %w to i32
@@ -316,7 +316,7 @@ define void @sti32_a4(i32 *%p, i64 %w) {
; CHECK-LABEL: sti32_a8:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store32 $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i64.store32 $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti32_a8(i32 *%p, i64 %w) {
%v = trunc i64 %w to i32
Modified: llvm/trunk/test/CodeGen/WebAssembly/inline-asm.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/inline-asm.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/inline-asm.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/inline-asm.ll Tue May 17 18:19:03 2016
@@ -59,7 +59,7 @@ entry:
; CHECK-LABEL: X_i16:
; CHECK: foo $1{{$}}
-; CHECK: i32.store16 $discard=, 0($0), $1{{$}}
+; CHECK: i32.store16 $drop=, 0($0), $1{{$}}
define void @X_i16(i16 * %t) {
call void asm sideeffect "foo $0", "=*X,~{dirflag},~{fpsr},~{flags},~{memory}"(i16* %t)
ret void
@@ -67,7 +67,7 @@ define void @X_i16(i16 * %t) {
; CHECK-LABEL: X_ptr:
; CHECK: foo $1{{$}}
-; CHECK: i32.store $discard=, 0($0), $1{{$}}
+; CHECK: i32.store $drop=, 0($0), $1{{$}}
define void @X_ptr(i16 ** %t) {
call void asm sideeffect "foo $0", "=*X,~{dirflag},~{fpsr},~{flags},~{memory}"(i16** %t)
ret void
Modified: llvm/trunk/test/CodeGen/WebAssembly/load-store-i1.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/load-store-i1.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/load-store-i1.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/load-store-i1.ll Tue May 17 18:19:03 2016
@@ -52,7 +52,7 @@ define i64 @load_s_i1_i64(i1* %p) {
; CHECK-LABEL: store_i32_i1:
; CHECK: i32.const $push[[NUM0:[0-9]+]]=, 1{{$}}
; CHECK-NEXT: i32.and $push[[NUM1:[0-9]+]]=, $1, $pop[[NUM0]]{{$}}
-; CHECK-NEXT: i32.store8 $discard=, 0($0), $pop[[NUM1]]{{$}}
+; CHECK-NEXT: i32.store8 $drop=, 0($0), $pop[[NUM1]]{{$}}
define void @store_i32_i1(i1* %p, i32 %v) {
%t = trunc i32 %v to i1
store i1 %t, i1* %p
@@ -62,7 +62,7 @@ define void @store_i32_i1(i1* %p, i32 %v
; CHECK-LABEL: store_i64_i1:
; CHECK: i64.const $push[[NUM0:[0-9]+]]=, 1{{$}}
; CHECK-NEXT: i64.and $push[[NUM1:[0-9]+]]=, $1, $pop[[NUM0]]{{$}}
-; CHECK-NEXT: i64.store8 $discard=, 0($0), $pop[[NUM1]]{{$}}
+; CHECK-NEXT: i64.store8 $drop=, 0($0), $pop[[NUM1]]{{$}}
define void @store_i64_i1(i1* %p, i64 %v) {
%t = trunc i64 %v to i1
store i1 %t, i1* %p
Modified: llvm/trunk/test/CodeGen/WebAssembly/mem-intrinsics.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/mem-intrinsics.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/mem-intrinsics.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/mem-intrinsics.ll Tue May 17 18:19:03 2016
@@ -20,7 +20,7 @@ define i8* @copy_yes(i8* %dst, i8* %src,
}
; CHECK-LABEL: copy_no:
-; CHECK: i32.call $discard=, memcpy at FUNCTION, $0, $1, $2{{$}}
+; CHECK: i32.call $drop=, memcpy at FUNCTION, $0, $1, $2{{$}}
; CHECK-NEXT: return{{$}}
define void @copy_no(i8* %dst, i8* %src, i32 %len) {
call void @llvm.memcpy.p0i8.p0i8.i32(i8* %dst, i8* %src, i32 %len, i32 1, i1 false)
@@ -36,7 +36,7 @@ define i8* @move_yes(i8* %dst, i8* %src,
}
; CHECK-LABEL: move_no:
-; CHECK: i32.call $discard=, memmove at FUNCTION, $0, $1, $2{{$}}
+; CHECK: i32.call $drop=, memmove at FUNCTION, $0, $1, $2{{$}}
; CHECK-NEXT: return{{$}}
define void @move_no(i8* %dst, i8* %src, i32 %len) {
call void @llvm.memmove.p0i8.p0i8.i32(i8* %dst, i8* %src, i32 %len, i32 1, i1 false)
@@ -52,7 +52,7 @@ define i8* @set_yes(i8* %dst, i8 %src, i
}
; CHECK-LABEL: set_no:
-; CHECK: i32.call $discard=, memset at FUNCTION, $0, $1, $2{{$}}
+; CHECK: i32.call $drop=, memset at FUNCTION, $0, $1, $2{{$}}
; CHECK-NEXT: return{{$}}
define void @set_no(i8* %dst, i8 %src, i32 %len) {
call void @llvm.memset.p0i8.i32(i8* %dst, i8 %src, i32 %len, i32 1, i1 false)
@@ -61,7 +61,7 @@ define void @set_no(i8* %dst, i8 %src, i
; CHECK-LABEL: frame_index:
-; CHECK: i32.call $discard=, memset at FUNCTION, $pop{{[0-9]+}}, $pop{{[0-9]+}}, $pop{{[0-9]+}}{{$}}
+; CHECK: i32.call $drop=, memset at FUNCTION, $pop{{[0-9]+}}, $pop{{[0-9]+}}, $pop{{[0-9]+}}{{$}}
; CHECK: i32.call $push{{[0-9]+}}=, memset at FUNCTION, ${{[0-9]+}}, $pop{{[0-9]+}}, $pop{{[0-9]+}}{{$}}
; CHECK: return{{$}}
define void @frame_index() {
@@ -76,14 +76,14 @@ entry:
}
; If the result value of memset doesn't get stackified, it should be marked
-; $discard. Note that we use a call to prevent tail dup so that we can test
+; $drop. Note that we use a call to prevent tail dup so that we can test
; this specific functionality.
-; CHECK-LABEL: discard_result:
-; CHECK: i32.call $discard=, memset at FUNCTION, $0, $1, $2
+; CHECK-LABEL: drop_result:
+; CHECK: i32.call $drop=, memset at FUNCTION, $0, $1, $2
declare i8* @def()
declare void @block_tail_dup()
-define i8* @discard_result(i8* %arg, i8 %arg1, i32 %arg2, i32 %arg3, i32 %arg4) {
+define i8* @drop_result(i8* %arg, i8 %arg1, i32 %arg2, i32 %arg3, i32 %arg4) {
bb:
%tmp = icmp eq i32 %arg3, 0
br i1 %tmp, label %bb5, label %bb9
@@ -109,7 +109,7 @@ bb11:
ret i8* %tmp12
}
-; This is the same as discard_result, except we let tail dup happen, so the
+; This is the same as drop_result, except we let tail dup happen, so the
; result of the memset *is* stackified.
; CHECK-LABEL: tail_dup_to_reuse_result:
Modified: llvm/trunk/test/CodeGen/WebAssembly/offset.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/offset.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/offset.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/offset.ll Tue May 17 18:19:03 2016
@@ -139,7 +139,7 @@ define i32 @load_i32_with_folded_or_offs
; Same as above but with store.
; CHECK-LABEL: store_i32_with_folded_offset:
-; CHECK: i32.store $discard=, 24($0), $pop0{{$}}
+; CHECK: i32.store $drop=, 24($0), $pop0{{$}}
define void @store_i32_with_folded_offset(i32* %p) {
%q = ptrtoint i32* %p to i32
%r = add nuw i32 %q, 24
@@ -151,7 +151,7 @@ define void @store_i32_with_folded_offse
; Same as above but with store.
; CHECK-LABEL: store_i32_with_folded_gep_offset:
-; CHECK: i32.store $discard=, 24($0), $pop0{{$}}
+; CHECK: i32.store $drop=, 24($0), $pop0{{$}}
define void @store_i32_with_folded_gep_offset(i32* %p) {
%s = getelementptr inbounds i32, i32* %p, i32 6
store i32 0, i32* %s
@@ -163,7 +163,7 @@ define void @store_i32_with_folded_gep_o
; CHECK-LABEL: store_i32_with_unfolded_gep_negative_offset:
; CHECK: i32.const $push0=, -24{{$}}
; CHECK: i32.add $push1=, $0, $pop0{{$}}
-; CHECK: i32.store $discard=, 0($pop1), $pop2{{$}}
+; CHECK: i32.store $drop=, 0($pop1), $pop2{{$}}
define void @store_i32_with_unfolded_gep_negative_offset(i32* %p) {
%s = getelementptr inbounds i32, i32* %p, i32 -6
store i32 0, i32* %s
@@ -175,7 +175,7 @@ define void @store_i32_with_unfolded_gep
; CHECK-LABEL: store_i32_with_unfolded_offset:
; CHECK: i32.const $push0=, 24{{$}}
; CHECK: i32.add $push1=, $0, $pop0{{$}}
-; CHECK: i32.store $discard=, 0($pop1), $pop2{{$}}
+; CHECK: i32.store $drop=, 0($pop1), $pop2{{$}}
define void @store_i32_with_unfolded_offset(i32* %p) {
%q = ptrtoint i32* %p to i32
%r = add nsw i32 %q, 24
@@ -189,7 +189,7 @@ define void @store_i32_with_unfolded_off
; CHECK-LABEL: store_i32_with_unfolded_gep_offset:
; CHECK: i32.const $push0=, 24{{$}}
; CHECK: i32.add $push1=, $0, $pop0{{$}}
-; CHECK: i32.store $discard=, 0($pop1), $pop2{{$}}
+; CHECK: i32.store $drop=, 0($pop1), $pop2{{$}}
define void @store_i32_with_unfolded_gep_offset(i32* %p) {
%s = getelementptr i32, i32* %p, i32 6
store i32 0, i32* %s
@@ -199,7 +199,7 @@ define void @store_i32_with_unfolded_gep
; Same as above but with store with i64.
; CHECK-LABEL: store_i64_with_folded_offset:
-; CHECK: i64.store $discard=, 24($0), $pop0{{$}}
+; CHECK: i64.store $drop=, 24($0), $pop0{{$}}
define void @store_i64_with_folded_offset(i64* %p) {
%q = ptrtoint i64* %p to i32
%r = add nuw i32 %q, 24
@@ -211,7 +211,7 @@ define void @store_i64_with_folded_offse
; Same as above but with store with i64.
; CHECK-LABEL: store_i64_with_folded_gep_offset:
-; CHECK: i64.store $discard=, 24($0), $pop0{{$}}
+; CHECK: i64.store $drop=, 24($0), $pop0{{$}}
define void @store_i64_with_folded_gep_offset(i64* %p) {
%s = getelementptr inbounds i64, i64* %p, i32 3
store i64 0, i64* %s
@@ -223,7 +223,7 @@ define void @store_i64_with_folded_gep_o
; CHECK-LABEL: store_i64_with_unfolded_gep_negative_offset:
; CHECK: i32.const $push0=, -24{{$}}
; CHECK: i32.add $push1=, $0, $pop0{{$}}
-; CHECK: i64.store $discard=, 0($pop1), $pop2{{$}}
+; CHECK: i64.store $drop=, 0($pop1), $pop2{{$}}
define void @store_i64_with_unfolded_gep_negative_offset(i64* %p) {
%s = getelementptr inbounds i64, i64* %p, i32 -3
store i64 0, i64* %s
@@ -235,7 +235,7 @@ define void @store_i64_with_unfolded_gep
; CHECK-LABEL: store_i64_with_unfolded_offset:
; CHECK: i32.const $push0=, 24{{$}}
; CHECK: i32.add $push1=, $0, $pop0{{$}}
-; CHECK: i64.store $discard=, 0($pop1), $pop2{{$}}
+; CHECK: i64.store $drop=, 0($pop1), $pop2{{$}}
define void @store_i64_with_unfolded_offset(i64* %p) {
%q = ptrtoint i64* %p to i32
%r = add nsw i32 %q, 24
@@ -249,7 +249,7 @@ define void @store_i64_with_unfolded_off
; CHECK-LABEL: store_i64_with_unfolded_gep_offset:
; CHECK: i32.const $push0=, 24{{$}}
; CHECK: i32.add $push1=, $0, $pop0{{$}}
-; CHECK: i64.store $discard=, 0($pop1), $pop2{{$}}
+; CHECK: i64.store $drop=, 0($pop1), $pop2{{$}}
define void @store_i64_with_unfolded_gep_offset(i64* %p) {
%s = getelementptr i64, i64* %p, i32 3
store i64 0, i64* %s
@@ -257,7 +257,7 @@ define void @store_i64_with_unfolded_gep
}
; CHECK-LABEL: store_i32_with_folded_or_offset:
-; CHECK: i32.store8 $discard=, 2($pop{{[0-9]+}}), $pop{{[0-9]+}}{{$}}
+; CHECK: i32.store8 $drop=, 2($pop{{[0-9]+}}), $pop{{[0-9]+}}{{$}}
define void @store_i32_with_folded_or_offset(i32 %x) {
%and = and i32 %x, -4
%t0 = inttoptr i32 %and to i8*
@@ -289,7 +289,7 @@ define i32 @load_i32_from_global_address
; CHECK-LABEL: store_i32_to_numeric_address:
; CHECK-NEXT: i32.const $push0=, 0{{$}}
; CHECK-NEXT: i32.const $push1=, 0{{$}}
-; CHECK-NEXT: i32.store $discard=, 42($pop0), $pop1{{$}}
+; CHECK-NEXT: i32.store $drop=, 42($pop0), $pop1{{$}}
define void @store_i32_to_numeric_address() {
%s = inttoptr i32 42 to i32*
store i32 0, i32* %s
@@ -299,7 +299,7 @@ define void @store_i32_to_numeric_addres
; CHECK-LABEL: store_i32_to_global_address:
; CHECK: i32.const $push0=, 0{{$}}
; CHECK: i32.const $push1=, 0{{$}}
-; CHECK: i32.store $discard=, gv($pop0), $pop1{{$}}
+; CHECK: i32.store $drop=, gv($pop0), $pop1{{$}}
define void @store_i32_to_global_address() {
store i32 0, i32* @gv
ret void
@@ -356,7 +356,7 @@ define i32 @load_i8_u_with_folded_gep_of
; Fold an offset into a truncating store.
; CHECK-LABEL: store_i8_with_folded_offset:
-; CHECK: i32.store8 $discard=, 24($0), $pop0{{$}}
+; CHECK: i32.store8 $drop=, 24($0), $pop0{{$}}
define void @store_i8_with_folded_offset(i8* %p) {
%q = ptrtoint i8* %p to i32
%r = add nuw i32 %q, 24
@@ -368,7 +368,7 @@ define void @store_i8_with_folded_offset
; Fold a gep offset into a truncating store.
; CHECK-LABEL: store_i8_with_folded_gep_offset:
-; CHECK: i32.store8 $discard=, 24($0), $pop0{{$}}
+; CHECK: i32.store8 $drop=, 24($0), $pop0{{$}}
define void @store_i8_with_folded_gep_offset(i8* %p) {
%s = getelementptr inbounds i8, i8* %p, i32 24
store i8 0, i8* %s
@@ -382,10 +382,10 @@ define void @store_i8_with_folded_gep_of
; CHECK: i32.load $3=, 4($0){{$}}
; CHECK: i32.load $4=, 8($0){{$}}
; CHECK: i32.load $push0=, 12($0){{$}}
-; CHECK: i32.store $discard=, 12($1), $pop0{{$}}
-; CHECK: i32.store $discard=, 8($1), $4{{$}}
-; CHECK: i32.store $discard=, 4($1), $3{{$}}
-; CHECK: i32.store $discard=, 0($1), $2{{$}}
+; CHECK: i32.store $drop=, 12($1), $pop0{{$}}
+; CHECK: i32.store $drop=, 8($1), $4{{$}}
+; CHECK: i32.store $drop=, 4($1), $3{{$}}
+; CHECK: i32.store $drop=, 0($1), $2{{$}}
define void @aggregate_load_store({i32,i32,i32,i32}* %p, {i32,i32,i32,i32}* %q) {
; volatile so that things stay in order for the tests above
%t = load volatile {i32,i32,i32,i32}, {i32, i32,i32,i32}* %p
@@ -399,7 +399,7 @@ define void @aggregate_load_store({i32,i
; CHECK-LABEL: aggregate_return:
; CHECK: i64.const $push[[L0:[0-9]+]]=, 0{{$}}
; CHECK: i64.store $push[[L1:[0-9]+]]=, 8($0):p2align=2, $pop[[L0]]{{$}}
-; CHECK: i64.store $discard=, 0($0):p2align=2, $pop[[L1]]{{$}}
+; CHECK: i64.store $drop=, 0($0):p2align=2, $pop[[L1]]{{$}}
define {i32,i32,i32,i32} @aggregate_return() {
ret {i32,i32,i32,i32} zeroinitializer
}
@@ -411,9 +411,9 @@ define {i32,i32,i32,i32} @aggregate_retu
; CHECK: i32.const $push[[L0:[0-9]+]]=, 0{{$}}
; CHECK: i32.store8 $push[[L1:[0-9]+]]=, 14($0), $pop[[L0]]{{$}}
; CHECK: i32.store16 $push[[L2:[0-9]+]]=, 12($0), $pop[[L1]]{{$}}
-; CHECK: i32.store $discard=, 8($0), $pop[[L2]]{{$}}
+; CHECK: i32.store $drop=, 8($0), $pop[[L2]]{{$}}
; CHECK: i64.const $push[[L3:[0-9]+]]=, 0{{$}}
-; CHECK: i64.store $discard=, 0($0), $pop[[L3]]{{$}}
+; CHECK: i64.store $drop=, 0($0), $pop[[L3]]{{$}}
define {i64,i32,i16,i8} @aggregate_return_without_merge() {
ret {i64,i32,i16,i8} zeroinitializer
}
Modified: llvm/trunk/test/CodeGen/WebAssembly/reg-stackify.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/reg-stackify.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/reg-stackify.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/reg-stackify.ll Tue May 17 18:19:03 2016
@@ -134,7 +134,7 @@ false:
; CHECK-NEXT: br_if 0, $pop[[NUM2]]{{$}}
; CHECK-NEXT: i32.lt_u $push[[NUM3:[0-9]+]]=, $3, $0{{$}}
; CHECK-NEXT: br_if 0, $pop[[NUM3]]{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($2), $3{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($2), $3{{$}}
; CHECK-NEXT: .LBB8_3:
; CHECK-NEXT: end_block{{$}}
; CHECK-NEXT: return{{$}}
@@ -450,7 +450,7 @@ bb10:
; CHECK-LABEL: stackpointer_dependency:
; CHECK: call {{.+}}, stackpointer_callee at FUNCTION,
; CHECK: i32.const $push[[L0:.+]]=, __stack_pointer
-; CHECK-NEXT: i32.store $discard=, 0($pop[[L0]]),
+; CHECK-NEXT: i32.store $drop=, 0($pop[[L0]]),
declare i32 @stackpointer_callee(i8* readnone, i8* readnone)
declare i8* @llvm.frameaddress(i32)
define i32 @stackpointer_dependency(i8* readnone) {
Modified: llvm/trunk/test/CodeGen/WebAssembly/returned.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/returned.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/returned.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/returned.ll Tue May 17 18:19:03 2016
@@ -38,7 +38,7 @@ entry:
; CHECK-LABEL: test_constant_arg:
; CHECK-NEXT: i32.const $push0=, global{{$}}
-; CHECK-NEXT: {{^}} i32.call $discard=, returns_arg at FUNCTION, $pop0{{$}}
+; CHECK-NEXT: {{^}} i32.call $drop=, returns_arg at FUNCTION, $pop0{{$}}
; CHECK-NEXT: return{{$}}
@global = external global i32
@addr = global i32* @global
Modified: llvm/trunk/test/CodeGen/WebAssembly/store-results.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/store-results.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/store-results.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/store-results.ll Tue May 17 18:19:03 2016
@@ -26,7 +26,7 @@ entry:
@pos = global %class.Vec3 zeroinitializer, align 4
; CHECK-LABEL: foo:
-; CHECK: i32.store $discard=, pos($pop{{[0-9]+}}), $pop{{[0-9]+}}{{$}}
+; CHECK: i32.store $drop=, pos($pop{{[0-9]+}}), $pop{{[0-9]+}}{{$}}
define void @foo() {
for.body.i:
br label %for.body5.i
@@ -44,7 +44,7 @@ for.cond.cleanup4.i:
}
; CHECK-LABEL: bar:
-; CHECK: i32.store $discard=, pos($pop{{[0-9]+}}), $pop{{[0-9]+}}{{$}}
+; CHECK: i32.store $drop=, pos($pop{{[0-9]+}}), $pop{{[0-9]+}}{{$}}
define void @bar() {
for.body.i:
br label %for.body5.i
Modified: llvm/trunk/test/CodeGen/WebAssembly/store-trunc.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/store-trunc.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/store-trunc.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/store-trunc.ll Tue May 17 18:19:03 2016
@@ -6,7 +6,7 @@ target datalayout = "e-m:e-p:32:32-i64:6
target triple = "wasm32-unknown-unknown"
; CHECK-LABEL: trunc_i8_i32:
-; CHECK: i32.store8 $discard=, 0($0), $1{{$}}
+; CHECK: i32.store8 $drop=, 0($0), $1{{$}}
define void @trunc_i8_i32(i8 *%p, i32 %v) {
%t = trunc i32 %v to i8
store i8 %t, i8* %p
@@ -14,7 +14,7 @@ define void @trunc_i8_i32(i8 *%p, i32 %v
}
; CHECK-LABEL: trunc_i16_i32:
-; CHECK: i32.store16 $discard=, 0($0), $1{{$}}
+; CHECK: i32.store16 $drop=, 0($0), $1{{$}}
define void @trunc_i16_i32(i16 *%p, i32 %v) {
%t = trunc i32 %v to i16
store i16 %t, i16* %p
@@ -22,7 +22,7 @@ define void @trunc_i16_i32(i16 *%p, i32
}
; CHECK-LABEL: trunc_i8_i64:
-; CHECK: i64.store8 $discard=, 0($0), $1{{$}}
+; CHECK: i64.store8 $drop=, 0($0), $1{{$}}
define void @trunc_i8_i64(i8 *%p, i64 %v) {
%t = trunc i64 %v to i8
store i8 %t, i8* %p
@@ -30,7 +30,7 @@ define void @trunc_i8_i64(i8 *%p, i64 %v
}
; CHECK-LABEL: trunc_i16_i64:
-; CHECK: i64.store16 $discard=, 0($0), $1{{$}}
+; CHECK: i64.store16 $drop=, 0($0), $1{{$}}
define void @trunc_i16_i64(i16 *%p, i64 %v) {
%t = trunc i64 %v to i16
store i16 %t, i16* %p
@@ -38,7 +38,7 @@ define void @trunc_i16_i64(i16 *%p, i64
}
; CHECK-LABEL: trunc_i32_i64:
-; CHECK: i64.store32 $discard=, 0($0), $1{{$}}
+; CHECK: i64.store32 $drop=, 0($0), $1{{$}}
define void @trunc_i32_i64(i32 *%p, i64 %v) {
%t = trunc i64 %v to i32
store i32 %t, i32* %p
Modified: llvm/trunk/test/CodeGen/WebAssembly/store.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/store.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/store.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/store.ll Tue May 17 18:19:03 2016
@@ -8,7 +8,7 @@ target triple = "wasm32-unknown-unknown"
; CHECK-LABEL: sti32:
; CHECK-NEXT: .param i32, i32{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti32(i32 *%p, i32 %v) {
store i32 %v, i32* %p
@@ -17,7 +17,7 @@ define void @sti32(i32 *%p, i32 %v) {
; CHECK-LABEL: sti64:
; CHECK-NEXT: .param i32, i64{{$}}
-; CHECK-NEXT: i64.store $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: i64.store $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @sti64(i64 *%p, i64 %v) {
store i64 %v, i64* %p
@@ -26,7 +26,7 @@ define void @sti64(i64 *%p, i64 %v) {
; CHECK-LABEL: stf32:
; CHECK-NEXT: .param i32, f32{{$}}
-; CHECK-NEXT: f32.store $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: f32.store $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @stf32(float *%p, float %v) {
store float %v, float* %p
@@ -35,7 +35,7 @@ define void @stf32(float *%p, float %v)
; CHECK-LABEL: stf64:
; CHECK-NEXT: .param i32, f64{{$}}
-; CHECK-NEXT: f64.store $discard=, 0($0), $1{{$}}
+; CHECK-NEXT: f64.store $drop=, 0($0), $1{{$}}
; CHECK-NEXT: return{{$}}
define void @stf64(double *%p, double %v) {
store double %v, double* %p
Modified: llvm/trunk/test/CodeGen/WebAssembly/unused-argument.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/unused-argument.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/unused-argument.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/unused-argument.ll Tue May 17 18:19:03 2016
@@ -22,7 +22,7 @@ define i32 @unused_second(i32 %x, i32 %y
}
; CHECK-LABEL: call_something:
-; CHECK-NEXT: {{^}} i32.call $discard=, return_something at FUNCTION{{$}}
+; CHECK-NEXT: {{^}} i32.call $drop=, return_something at FUNCTION{{$}}
; CHECK-NEXT: return{{$}}
declare i32 @return_something()
define void @call_something() {
Modified: llvm/trunk/test/CodeGen/WebAssembly/userstack.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/userstack.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/userstack.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/userstack.ll Tue May 17 18:19:03 2016
@@ -24,7 +24,7 @@ define void @alloca32() noredzone {
; CHECK: i32.const $push[[L6:.+]]=, __stack_pointer
; CHECK-NEXT: i32.const $push[[L5:.+]]=, 16
; CHECK-NEXT: i32.add $push[[L7:.+]]=, $[[SP]], $pop[[L5]]
- ; CHECK-NEXT: i32.store $discard=, 0($pop[[L6]]), $pop[[L7]]
+ ; CHECK-NEXT: i32.store $drop=, 0($pop[[L6]]), $pop[[L7]]
ret void
}
@@ -39,10 +39,10 @@ define void @alloca3264() {
%r1 = alloca i32
%r2 = alloca double
; CHECK-NEXT: i32.const $push[[L0:.+]]=, 0
- ; CHECK-NEXT: i32.store $discard=, 12($pop[[L5]]), $pop[[L0]]
+ ; CHECK-NEXT: i32.store $drop=, 12($pop[[L5]]), $pop[[L0]]
store i32 0, i32* %r1
; CHECK-NEXT: i64.const $push[[L1:.+]]=, 0
- ; CHECK-NEXT: i64.store $discard=, 0($[[SP]]), $pop[[L1]]
+ ; CHECK-NEXT: i64.store $drop=, 0($[[SP]]), $pop[[L1]]
store double 0.0, double* %r2
; CHECK-NEXT: return
ret void
@@ -63,7 +63,7 @@ define void @allocarray() {
; CHECK-NEXT: i32.add $push[[L3:.+]]=, $[[SP]], $pop{{.+}}
; CHECK-NEXT: i32.const $push[[L1:.+]]=, 1{{$}}
; CHECK-NEXT: i32.store $push[[L0:.+]]=, 0($pop[[L3]]), $pop[[L1]]{{$}}
- ; CHECK-NEXT: i32.store $discard=, 12(${{.+}}), $pop[[L0]]{{$}}
+ ; CHECK-NEXT: i32.store $drop=, 12(${{.+}}), $pop[[L0]]{{$}}
%p = getelementptr [33 x i32], [33 x i32]* %r, i32 0, i32 0
store i32 1, i32* %p
%p2 = getelementptr [33 x i32], [33 x i32]* %r, i32 0, i32 3
@@ -72,7 +72,7 @@ define void @allocarray() {
; CHECK: i32.const $push[[L10:.+]]=, __stack_pointer
; CHECK-NEXT: i32.const $push[[L8:.+]]=, 144
; CHECK-NEXT: i32.add $push[[L19:.+]]=, $[[SP]], $pop[[L8]]
- ; CHECK-NEXT: i32.store $discard=, 0($pop[[L10]]), $pop[[L9]]
+ ; CHECK-NEXT: i32.store $drop=, 0($pop[[L10]]), $pop[[L9]]
ret void
}
@@ -125,7 +125,7 @@ define void @allocarray_inbounds() {
; CHECK: i32.const $push[[L6:.+]]=, __stack_pointer
; CHECK-NEXT: i32.const $push[[L5:.+]]=, 32
; CHECK-NEXT: i32.add $push[[L7:.+]]=, ${{.+}}, $pop[[L5]]
- ; CHECK-NEXT: i32.store $discard=, 0($pop[[L6]]), $pop[[L7]]
+ ; CHECK-NEXT: i32.store $drop=, 0($pop[[L6]]), $pop[[L7]]
ret void
}
@@ -138,13 +138,13 @@ define void @dynamic_alloca(i32 %alloc)
; Target independent codegen bumps the stack pointer.
; CHECK: i32.sub
; Check that SP is written back to memory after decrement
- ; CHECK: i32.store $discard=, 0($pop{{.+}}),
+ ; CHECK: i32.store $drop=, 0($pop{{.+}}),
%r = alloca i32, i32 %alloc
; Target-independent codegen also calculates the store addr
; CHECK: call ext_func_i32 at FUNCTION
call void @ext_func_i32(i32* %r)
; CHECK: i32.const $push[[L3:.+]]=, __stack_pointer
- ; CHECK: i32.store $discard=, 0($pop[[L3]]), $pop{{.+}}
+ ; CHECK: i32.store $drop=, 0($pop[[L3]]), $pop{{.+}}
ret void
}
@@ -158,9 +158,9 @@ define void @dynamic_alloca_redzone(i32
; CHECK: i32.sub
%r = alloca i32, i32 %alloc
; CHECK-NEXT: tee_local $push[[L8:.+]]=, $0=, $pop
- ; CHECK-NEXT: copy_local $discard=, $pop[[L8]]{{$}}
+ ; CHECK-NEXT: copy_local $drop=, $pop[[L8]]{{$}}
; CHECK-NEXT: i32.const $push[[L6:.+]]=, 0{{$}}
- ; CHECK-NEXT: i32.store $discard=, 0($0), $pop[[L6]]{{$}}
+ ; CHECK-NEXT: i32.store $drop=, 0($0), $pop[[L6]]{{$}}
store i32 0, i32* %r
; CHECK-NEXT: return
ret void
@@ -180,11 +180,11 @@ define void @dynamic_static_alloca(i32 %
; Decrement SP in the body by the dynamic amount.
; CHECK: i32.sub
; Writeback to memory.
- ; CHECK: i32.store $discard=, 0($pop{{.+}}), $pop{{.+}}
+ ; CHECK: i32.store $drop=, 0($pop{{.+}}), $pop{{.+}}
%r1 = alloca i32
%r = alloca i32, i32 %alloc
store i32 0, i32* %r
- ; CHEC: i32.store $discard=, 0($pop{{.+}}), $pop{{.+}}
+ ; CHEC: i32.store $drop=, 0($pop{{.+}}), $pop{{.+}}
ret void
}
@@ -220,7 +220,7 @@ declare i8* @llvm.frameaddress(i32)
; CHECK-NEXT: tee_local $push[[L2:.+]]=, $[[FP:.+]]=, $pop[[L4]]{{$}}
; CHECK-NEXT: call use_i8_star at FUNCTION, $pop[[L2]]
; CHECK-NEXT: i32.const $push[[L1:.+]]=, __stack_pointer
-; CHECK-NEXT: i32.store $discard=, 0($pop[[L1]]), $[[FP]]
+; CHECK-NEXT: i32.store $drop=, 0($pop[[L1]]), $[[FP]]
define void @frameaddress_0() {
%t = call i8* @llvm.frameaddress(i32 0)
call void @use_i8_star(i8* %t)
Modified: llvm/trunk/test/CodeGen/WebAssembly/varargs.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/WebAssembly/varargs.ll?rev=269862&r1=269861&r2=269862&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/WebAssembly/varargs.ll (original)
+++ llvm/trunk/test/CodeGen/WebAssembly/varargs.ll Tue May 17 18:19:03 2016
@@ -15,7 +15,7 @@ define void @start(i8** %ap, ...) {
entry:
%0 = bitcast i8** %ap to i8*
; Store the second argument (the hidden vararg buffer pointer) into ap
-; CHECK: i32.store $discard=, 0($0), $1
+; CHECK: i32.store $drop=, 0($0), $1
call void @llvm.va_start(i8* %0)
ret void
}
@@ -37,7 +37,7 @@ entry:
; CHECK-LABEL: copy:
; CHECK-NEXT: .param i32, i32{{$}}
; CHECK-NEXT: i32.load $push0=, 0($1){{$}}
-; CHECK-NEXT: i32.store $discard=, 0($0), $pop0{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($0), $pop0{{$}}
; CHECK-NEXT: return{{$}}
define void @copy(i8** %ap, i8** %bp) {
entry:
@@ -57,7 +57,7 @@ entry:
; CHECK-NEXT: tee_local $push[[NUM1:[0-9]+]]=, $1=, $pop[[NUM0]]{{$}}
; CHECK-NEXT: i32.const $push[[NUM2:[0-9]+]]=, 4{{$}}
; CHECK-NEXT: i32.add $push[[NUM3:[0-9]+]]=, $pop[[NUM1]], $pop[[NUM2]]{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($0), $pop[[NUM3]]{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($0), $pop[[NUM3]]{{$}}
; CHECK-NEXT: i32.load $push[[NUM4:[0-9]+]]=, 0($1){{$}}
; CHECK-NEXT: return $pop[[NUM4]]{{$}}
define i8 @arg_i8(i8** %ap) {
@@ -80,7 +80,7 @@ entry:
; CHECK-NEXT: tee_local $push[[NUM5:[0-9]+]]=, $1=, $pop[[NUM4]]{{$}}
; CHECK-NEXT: i32.const $push[[NUM6:[0-9]+]]=, 4{{$}}
; CHECK-NEXT: i32.add $push[[NUM7:[0-9]+]]=, $pop[[NUM5]], $pop[[NUM6]]{{$}}
-; CHECK-NEXT: i32.store $discard=, 0($0), $pop[[NUM7]]{{$}}
+; CHECK-NEXT: i32.store $drop=, 0($0), $pop[[NUM7]]{{$}}
; CHECK-NEXT: i32.load $push[[NUM8:[0-9]+]]=, 0($1){{$}}
; CHECK-NEXT: return $pop[[NUM8]]{{$}}
define i32 @arg_i32(i8** %ap) {
@@ -141,7 +141,7 @@ bb0:
bb1:
%0 = bitcast i8** %ap to i8*
; Store the second argument (the hidden vararg buffer pointer) into ap
-; CHECK: i32.store $discard=, 0($1), $2
+; CHECK: i32.store $drop=, 0($1), $2
call void @llvm.va_start(i8* %0)
ret void
}
More information about the llvm-commits
mailing list