Implemented the rest of the bitwise operations

This commit is contained in:
FernandoS27 2018-11-11 18:51:08 -04:00
parent 6790490271
commit aa3d1adbbd
2 changed files with 78 additions and 1 deletions

View file

@ -280,10 +280,30 @@ class Module {
/// The least-significant bits will be zero filled.
Id OpShiftLeftLogical(Id result_type, Id base, Id shift);
/// Does a bitwise Or between operands 1 and 2.
Id OpBitwiseOr(Id result_type, Id operand_1, Id operand_2);
/// Does a bitwise Xor between operands 1 and 2.
Id OpBitwiseXor(Id result_type, Id operand_1, Id operand_2);
/// Result is 1 if both Operand 1 and Operand 2 are 1. Result is 0 if either
/// Operand 1 or Operand 2 are 0.
Id OpBitwiseAnd(Id result_type, Id operand_1, Id operand_2);
/// Does a bitwise Not on the operand.
Id OpNot(Id result_type, Id operand);
Id OpBitFieldInsert(Id result_type, Id base, Id insert, Id offset,
Id count);
Id OpBitFieldSExtract(Id result_type, Id base, Id offset, Id count);
Id OpBitFieldUExtract(Id result_type, Id base, Id offset, Id count);
Id OpBitReverse(Id result_type, Id base);
Id OpBitCount(Id result_type, Id base);
// Arithmetic
/// Floating-point subtract of Operand from zero.