1 ; RUN: llc < %s -asm-verbose=false -disable-wasm-fallthrough-return-opt -wasm-disable-explicit-locals -wasm-keep-registers | FileCheck %s
3 ; Test that the frem instruction works.
5 target datalayout = "e-m:e-p:32:32-i64:64-n32:64-S128"
6 target triple = "wasm32-unknown-unknown"
9 ; CHECK-NEXT: .functype frem32 (f32, f32) -> (f32){{$}}
10 ; CHECK-NEXT: {{^}} f32.call $push0=, fmodf, $0, $1{{$}}
11 ; CHECK-NEXT: return $pop0{{$}}
12 define float @frem32(float %x, float %y) {
13 %a = frem float %x, %y
17 ; CHECK-LABEL: frem64:
18 ; CHECK-NEXT: .functype frem64 (f64, f64) -> (f64){{$}}
19 ; CHECK-NEXT: {{^}} f64.call $push0=, fmod, $0, $1{{$}}
20 ; CHECK-NEXT: return $pop0{{$}}
21 define double @frem64(double %x, double %y) {
22 %a = frem double %x, %y