[spv-out] Add and implement bitwise_and

This commit is contained in:
Timo de Kort authored and Dzmitry Malyshau committed 2020-11-14 12:40:02 -05:00
1 parent cbcdcf470f
commit d0de2faa73
2 files changed
+18

No files matched your search

+9
View File
@@ -696,6 +696,15 @@ pub(super) fn instruction_matrix_times_matrix(
// Bit Instructions
//
pub(super) fn instruction_bitwise_and(
result_type_id: Word,
id: Word,
operand_1: Word,
operand_2: Word,
) -> Instruction {
instruction_binary(Op::BitwiseAnd, result_type_id, id, operand_1, operand_2)
}
//
// Relational and Logical Instructions
//
+9
View File
@@ -1214,6 +1214,15 @@ impl Writer {
},
_ => unreachable!(),
},
crate::BinaryOperator::And => (
super::instructions::instruction_bitwise_and(
left_result_type_id,
id,
left_id,
right_id,
),
left_lookup_ty,
),
_ => unimplemented!("{:?}", op),
};