machinst x64: allow use of vector-length types

This commit is contained in:
Andrew Brown
2020-07-24 12:31:28 -07:00
parent dc6220b87c
commit 77cc2f69c1
5 changed files with 54 additions and 19 deletions

View File

@@ -93,6 +93,7 @@ fn in_int_reg(ty: types::Type) -> bool {
fn in_vec_reg(ty: types::Type) -> bool {
match ty {
types::F32 | types::F64 => true,
_ if ty.is_vector() => true,
_ => false,
}
}
@@ -365,7 +366,7 @@ impl ABIBody for X64ABIBody {
1 | 8 => Some(ExtMode::BQ),
16 => Some(ExtMode::WQ),
32 => Some(ExtMode::LQ),
64 => None,
64 | 128 => None,
_ => unreachable!(),
};