Legalize some more i8/i16 intructions (#524)
* Legalize some more i8/i16 intructions
This commit is contained in:
15
cranelift/filetests/isa/x86/legalize-urem-i8.clif
Normal file
15
cranelift/filetests/isa/x86/legalize-urem-i8.clif
Normal file
@@ -0,0 +1,15 @@
|
||||
test compile
|
||||
target x86_64
|
||||
|
||||
; regex: V=v\d+
|
||||
|
||||
function u0:0(i8, i8) -> i8 fast {
|
||||
ebb0(v0: i8, v1: i8):
|
||||
v2 = urem v0, v1
|
||||
; check: $(a=$V) = uextend.i32 v0
|
||||
; nextln: $(b=$V) = uextend.i32 v1
|
||||
; nextln: $(c=$V) = iconst.i32 0
|
||||
; nextln: $(V), $(r=$V) = x86_udivmodx $a, $c, $b
|
||||
; nextln: v2 = ireduce.i8 $r
|
||||
return v2
|
||||
}
|
||||
Reference in New Issue
Block a user