Legalize [u|s]widen_high for x86

Use `x86_palignr` and `[u|s]widen_low` for legalizing this instruction.
This commit is contained in:
Andrew Brown
2020-07-07 16:22:26 -07:00
parent c8ddf8a34c
commit f0b083c6ad
2 changed files with 41 additions and 0 deletions

View File

@@ -52,3 +52,19 @@ block0(v0:f32x4):
; nextln: v1 = iadd v12, v11
return v1
}
function %uwiden_high(i8x16) -> i16x8 {
block0(v0: i8x16):
v1 = uwiden_high v0
; check: v2 = x86_palignr v0, v0, 8
; nextln: v1 = uwiden_low v2
return v1
}
function %swiden_high(i16x8) -> i32x4 {
block0(v0: i16x8):
v1 = swiden_high v0
; check: v2 = x86_palignr v0, v0, 8
; nextln: v1 = swiden_low v2
return v1
}