Stop supporting vectors with bmask (#5948)

Co-authored-by: Jamey Sharp <jsharp@fastly.com>
This commit is contained in:
Trevor Elliott
2023-03-07 09:34:29 -08:00
committed by GitHub
parent 8bb183f16e
commit b44f67b6d7
2 changed files with 5 additions and 42 deletions

View File

@@ -2967,19 +2967,13 @@ pub(crate) fn define(
let Truthy = &TypeVar::new( let Truthy = &TypeVar::new(
"Truthy", "Truthy",
"A scalar or vector whose values are truthy", "A scalar whose values are truthy",
TypeSetBuilder::new() TypeSetBuilder::new().ints(Interval::All).build(),
.ints(Interval::All)
.simd_lanes(Interval::All)
.build(),
); );
let IntTo = &TypeVar::new( let IntTo = &TypeVar::new(
"IntTo", "IntTo",
"An integer type with the same number of lanes", "An integer type",
TypeSetBuilder::new() TypeSetBuilder::new().ints(Interval::All).build(),
.ints(Interval::All)
.simd_lanes(Interval::All)
.build(),
); );
let x = &Operand::new("x", Truthy); let x = &Operand::new("x", Truthy);
let a = &Operand::new("a", IntTo); let a = &Operand::new("a", IntTo);
@@ -2990,8 +2984,7 @@ pub(crate) fn define(
r#" r#"
Convert `x` to an integer mask. Convert `x` to an integer mask.
True maps to all 1s and false maps to all 0s. The result type must have Non-zero maps to all 1s and zero maps to all 0s.
the same number of vector lanes as the input.
"#, "#,
&formats.unary, &formats.unary,
) )

View File

@@ -1,30 +0,0 @@
test interpret
function %bmask_i8x16(i8x16) -> i8x16 {
block0(v0: i8x16):
v1 = bmask.i8x16 v0
return v1
}
; run: %bmask_i8x16([-1 0 -1 0 -1 0 -1 0 -1 0 -1 0 -1 0 -1 0]) == [-1 0 -1 0 -1 0 -1 0 -1 0 -1 0 -1 0 -1 0]
function %bmask_i16x8(i16x8) -> i16x8 {
block0(v0: i16x8):
v1 = bmask.i16x8 v0
return v1
}
; run: %bmask_i16x8([-1 0 -1 0 -1 0 -1 0]) == [-1 0 -1 0 -1 0 -1 0]
function %bmask_i32x4(i32x4) -> i32x4 {
block0(v0: i32x4):
v1 = bmask.i32x4 v0
return v1
}
; run: %bmask_i32x4([-1 0 -1 0]) == [-1 0 -1 0]
function %bmask_i64x2(i64x2) -> i64x2 {
block0(v0: i64x2):
v1 = bmask.i64x2 v0
return v1
}
; run: %bmask_i64x2([-1 0]) == [-1 0]