Added condition operand, adjusted tests to parse it & a few changes to get the kernelDG tests working

This commit is contained in:
stefandesouza
2023-10-29 16:36:00 +01:00
parent cce05e44cb
commit 78ca6fe855
20 changed files with 728 additions and 672 deletions

View File

@@ -3,7 +3,7 @@
from osaca.parser.operand import Operand
class immediateOperand(Operand):
class ImmediateOperand(Operand):
def __init__(
self,
identifier_id=None,
@@ -53,18 +53,18 @@ class immediateOperand(Operand):
def __str__(self):
return (
f"immediateOperand(identifier_id={self._identifier_id}, type_id={self._type_id}, "
f"ImmediateOperand(identifier_id={self._identifier_id}, type_id={self._type_id}, "
f"value_id={self._value_id}, shift_id={self._shift_id})"
)
def __repr__(self):
return (
f"immediateOperand(identifier_id={self._identifier_id}, type_id={self._type_id}, "
f"ImmediateOperand(identifier_id={self._identifier_id}, type_id={self._type_id}, "
f"value_id={self._value_id}, shift_id={self._shift_id})"
)
def __eq__(self, other):
if isinstance(other, immediateOperand):
if isinstance(other, ImmediateOperand):
return (
self._identifier_id == other._identifier_id
and self._type_id == other._type_id