1 ; RUN: llc < %s -asm-verbose=false | FileCheck %s 2 ; RUN: llc < %s -asm-verbose=false -fast-isel -fast-isel-abort=1 | FileCheck %s 3 4 target datalayout = "e-m:e-p:32:32-i64:64-n32:64-S128" 5 target triple = "wasm32-unknown-unknown" 6 7 ; CHECK-LABEL: return_i32: 8 ; CHECK-NEXT: .param i32{{$}} 9 ; CHECK-NEXT: .result i32{{$}} 10 ; CHECK-NEXT: copy_local $push0=, $0 11 ; CHECK-NEXT: .endfunc{{$}} 12 define i32 @return_i32(i32 %p) { 13 ret i32 %p 14 } 15 16 ; CHECK-LABEL: return_i32_twice: 17 ; CHECK: store 18 ; CHECK-NEXT: i32.const $push[[L0:[^,]+]]=, 1{{$}} 19 ; CHECK-NEXT: return $pop[[L0]]{{$}} 20 ; CHECK: store 21 ; CHECK-NEXT: i32.const $push{{[^,]+}}=, 3{{$}} 22 ; CHECK-NEXT: .endfunc{{$}} 23 define i32 @return_i32_twice(i32 %a) { 24 %b = icmp ne i32 %a, 0 25 br i1 %b, label %true, label %false 26 27 true: 28 store i32 0, i32* null 29 ret i32 1 30 31 false: 32 store i32 2, i32* null 33 ret i32 3 34 } 35