brintos

brintos / llvm-project-archived public Read only

0
0
Text · 725 B · c86970d Raw
24 lines · plain
1; RUN: llc < %s -asm-verbose=false -disable-wasm-fallthrough-return-opt -wasm-disable-explicit-locals -wasm-keep-registers | FileCheck %s2 3; Test that the frem instruction works.4 5target triple = "wasm32-unknown-unknown"6 7; CHECK-LABEL: frem32:8; CHECK-NEXT: .functype frem32 (f32, f32) -> (f32){{$}}9; CHECK-NEXT: {{^}} call $push0=, fmodf, $0, $1{{$}}10; CHECK-NEXT: return $pop0{{$}}11define float @frem32(float %x, float %y) {12  %a = frem float %x, %y13  ret float %a14}15 16; CHECK-LABEL: frem64:17; CHECK-NEXT: .functype frem64 (f64, f64) -> (f64){{$}}18; CHECK-NEXT: {{^}} call $push0=, fmod, $0, $1{{$}}19; CHECK-NEXT: return $pop0{{$}}20define double @frem64(double %x, double %y) {21  %a = frem double %x, %y22  ret double %a23}24