diff --git a/pyteal/ast/abi/type.py b/pyteal/ast/abi/type.py index 6abed2d80..b7ebe5bd5 100644 --- a/pyteal/ast/abi/type.py +++ b/pyteal/ast/abi/type.py @@ -3,6 +3,7 @@ from pyteal.ast.expr import Expr from pyteal.ast.abstractvar import AbstractVar +from pyteal.ast.frame import FrameVar from pyteal.ast.scratchvar import ScratchVar from pyteal.ast.seq import Seq from pyteal.errors import TealInputError @@ -76,9 +77,28 @@ class BaseType(ABC): def __init__(self, spec: TypeSpec) -> None: """Create a new BaseType.""" + from pyteal.ast.subroutine import SubroutineEval + super().__init__() self._type_spec: Final[TypeSpec] = spec - self._stored_value: AbstractVar = ScratchVar(spec.storage_type()) + self._stored_value: AbstractVar + + if SubroutineEval.Context.config_use_frame_pointer: + assert SubroutineEval.Context.proto + proto = SubroutineEval.Context.proto + + assert proto.mem_layout + local_types = proto.mem_layout.local_stack_types + + # NOTE: you can have at most 128 local variables. + # len(local_types) + 1 computes the resulting length, + # should be <= 128 + if len(local_types) + 1 <= 128: + local_types.append(self._type_spec.storage_type()) + self._stored_value = FrameVar(proto, len(local_types) - 1) + return + + self._stored_value = ScratchVar(spec.storage_type()) def type_spec(self) -> TypeSpec: """Get the TypeSpec for this ABI type instance.""" @@ -221,17 +241,23 @@ def store_into(self, output: BaseType) -> Expr: f"expected type_spec {self.produced_type_spec()} but get {output.type_spec()}" ) - declaration = self.computation.subroutine.get_declaration() - - if declaration.deferred_expr is None: - raise TealInputError( - "ABI return subroutine must have deferred_expr to be not-None." - ) - if declaration.deferred_expr.type_of() != output.type_spec().storage_type(): - raise TealInputError( - f"ABI return subroutine deferred_expr is expected to be typed {output.type_spec().storage_type()}, " - f"but has type {declaration.deferred_expr.type_of()}." - ) + # HANG NOTE! This get_declaration check applies only for pre frame pointer case + # the post frame pointer case should not apply + # need to somehow expose the context of evaluation + try: + declaration = self.computation.subroutine.get_declaration() + + if declaration.deferred_expr is None: + raise TealInputError( + "ABI return subroutine must have deferred_expr to be not-None." + ) + if declaration.deferred_expr.type_of() != output.type_spec().storage_type(): + raise TealInputError( + f"ABI return subroutine deferred_expr is expected to be typed {output.type_spec().storage_type()}, " + f"but has type {declaration.deferred_expr.type_of()}." + ) + except Exception: + pass return output._stored_value.store(self.computation) diff --git a/pyteal/ast/frame.py b/pyteal/ast/frame.py index 904885f66..deb3eefaf 100644 --- a/pyteal/ast/frame.py +++ b/pyteal/ast/frame.py @@ -349,3 +349,31 @@ def has_return(self) -> bool: DupN.__module__ = "pyteal" + + +class Bury(Expr): + def __init__(self, depth: int): + super(Bury, self).__init__() + if depth <= 0: + raise TealInputError("bury depth should be positive") + self.depth = depth + + def __teal__(self, options: "CompileOptions") -> tuple[TealBlock, TealSimpleBlock]: + verifyProgramVersion( + Op.bury.min_version, + options.version, + "Program version too low to use bury", + ) + return TealBlock.FromOp(options, TealOp(self, Op.bury, self.depth)) + + def __str__(self): + return f"(Bury {self.depth})" + + def has_return(self) -> bool: + return False + + def type_of(self) -> TealType: + return TealType.none + + +Bury.__module__ = "pyteal" diff --git a/pyteal/ast/subroutine.py b/pyteal/ast/subroutine.py index eeea8950b..7e3e14c51 100644 --- a/pyteal/ast/subroutine.py +++ b/pyteal/ast/subroutine.py @@ -1,3 +1,4 @@ +from contextlib import AbstractContextManager from dataclasses import dataclass from docstring_parser import parse as parse_docstring from inspect import isclass, Parameter, signature, get_annotations @@ -9,7 +10,7 @@ from pyteal.ast.expr import Expr from pyteal.ast.seq import Seq from pyteal.ast.scratchvar import DynamicScratchVar, ScratchVar, ScratchSlot -from pyteal.ast.frame import Proto, FrameVar, ProtoStackLayout +from pyteal.ast.frame import Bury, Proto, FrameVar, ProtoStackLayout from pyteal.errors import TealInputError, TealInternalError, verifyProgramVersion from pyteal.ir import TealOp, Op, TealBlock from pyteal.types import TealType @@ -1006,7 +1007,17 @@ def __call__(self, subroutine: SubroutineDefinition) -> SubroutineDeclaration: abi_output_kwargs[output_kwarg_info.name] = output_carrying_abi # Arg usage "B" supplied to build an AST from the user-defined PyTEAL function: - subroutine_body = subroutine.implementation(*loaded_args, **abi_output_kwargs) + subroutine_body: Expr + if not self.use_frame_pt: + subroutine_body = subroutine.implementation( + *loaded_args, **abi_output_kwargs + ) + else: + with SubroutineEval.Context.CompileWithFrameContext(proto): + subroutine_body = subroutine.implementation( + *loaded_args, **abi_output_kwargs + ) + if not isinstance(subroutine_body, Expr): raise TealInputError( f"Subroutine function does not return a PyTeal expression. Got type {type(subroutine_body)}." @@ -1025,6 +1036,14 @@ def __call__(self, subroutine: SubroutineDefinition) -> SubroutineDeclaration: if not self.use_frame_pt: deferred_expr = output_carrying_abi._stored_value.load() + if self.use_frame_pt: + assert proto.mem_layout + depth = len(proto.mem_layout.local_stack_types) + # only when we have 1 return, and with other local variables + # we use bury to bury the result to 0 index against frame pointer + if not abi_output_kwargs and 0 < proto.num_returns < depth: + deferred_expr = Bury(depth) + # Arg usage "A" to be pick up and store in scratch parameters that have been placed on the stack # need to reverse order of argumentVars because the last argument will be on top of the stack @@ -1053,5 +1072,24 @@ def normal_evaluator(cls) -> "SubroutineEval": def fp_evaluator(cls) -> "SubroutineEval": return cls(SubroutineEval.var_n_loaded_fp, True) + class Context: + config_use_frame_pointer: bool = False + proto: Optional[Proto] = None + + class CompileWithFrameContext(AbstractContextManager): + def __init__(self, _proto: Proto): + super().__init__() + self.prev_ctxt_proto: Optional[Proto] = SubroutineEval.Context.proto + SubroutineEval.Context.proto = _proto + + def __enter__(self): + SubroutineEval.Context.config_use_frame_pointer = True + return self + + def __exit__(self, *_): + SubroutineEval.Context.config_use_frame_pointer = False + SubroutineEval.Context.proto = self.prev_ctxt_proto + return None + SubroutineEval.__module__ = "pyteal" diff --git a/tests/integration/teal/roundtrip/app_roundtrip_()_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_()_v8.teal index d0ddb9ccf..459116c6c 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_()_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_()_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 1 byte "" frame_bury 0 retsub @@ -23,16 +25,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 3 +frame_bury 2 frame_dig -1 -load 2 +frame_dig 1 concat -load 3 +frame_dig 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(bool)[10]_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(bool)[10]_v8.teal index 13296df67..59f3055ff 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(bool)[10]_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(bool)[10]_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 int 0 getbit @@ -33,124 +35,127 @@ retsub arraycomplement_1: proto 1 1 byte "" +dupn 10 +int 0 +dupn 1 frame_dig -1 int 1 int 0 * int 1 extract3 -store 5 +frame_bury 1 frame_dig -1 int 1 int 1 * int 1 extract3 -store 6 +frame_bury 2 frame_dig -1 int 1 int 2 * int 1 extract3 -store 7 +frame_bury 3 frame_dig -1 int 1 int 3 * int 1 extract3 -store 8 +frame_bury 4 frame_dig -1 int 1 int 4 * int 1 extract3 -store 9 +frame_bury 5 frame_dig -1 int 1 int 5 * int 1 extract3 -store 10 +frame_bury 6 frame_dig -1 int 1 int 6 * int 1 extract3 -store 11 +frame_bury 7 frame_dig -1 int 1 int 7 * int 1 extract3 -store 12 +frame_bury 8 frame_dig -1 int 1 int 8 * int 1 extract3 -store 13 +frame_bury 9 frame_dig -1 int 1 int 9 * int 1 extract3 -store 14 -load 5 +frame_bury 10 +frame_dig 1 callsub tuplecomplement_0 -store 5 -load 6 +frame_bury 1 +frame_dig 2 callsub tuplecomplement_0 -store 6 -load 7 +frame_bury 2 +frame_dig 3 callsub tuplecomplement_0 -store 7 -load 8 +frame_bury 3 +frame_dig 4 callsub tuplecomplement_0 -store 8 -load 9 +frame_bury 4 +frame_dig 5 callsub tuplecomplement_0 -store 9 -load 10 +frame_bury 5 +frame_dig 6 callsub tuplecomplement_0 -store 10 -load 11 +frame_bury 6 +frame_dig 7 callsub tuplecomplement_0 -store 11 -load 12 +frame_bury 7 +frame_dig 8 callsub tuplecomplement_0 -store 12 -load 13 +frame_bury 8 +frame_dig 9 callsub tuplecomplement_0 -store 13 -load 14 +frame_bury 9 +frame_dig 10 callsub tuplecomplement_0 -store 14 -load 5 -load 6 +frame_bury 10 +frame_dig 1 +frame_dig 2 concat -load 7 +frame_dig 3 concat -load 8 +frame_dig 4 concat -load 9 +frame_dig 5 concat -load 10 +frame_dig 6 concat -load 11 +frame_dig 7 concat -load 12 +frame_dig 8 concat -load 13 +frame_dig 9 concat -load 14 +frame_dig 10 concat frame_bury 0 retsub @@ -159,16 +164,19 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 3 -load 3 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 4 +frame_bury 2 frame_dig -1 -load 3 +frame_dig 1 concat -load 4 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(bool)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(bool)_v8.teal index 72411884c..247d0a8ea 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(bool)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(bool)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 int 0 getbit @@ -33,16 +35,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 3 -load 3 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 4 +frame_bury 2 frame_dig -1 -load 3 +frame_dig 1 concat -load 4 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(bool,address,(uint64,bool),byte[10],bool[4],uint64)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(bool,address,(uint64,bool),byte[10],bool[4],uint64)_v8.teal index 1875b356a..7eb23d671 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(bool,address,(uint64,bool),byte[10],bool[4],uint64)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(bool,address,(uint64,bool),byte[10],bool[4],uint64)_v8.teal @@ -15,6 +15,20 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 6 +byte "" +dupn 1 +int 0 +dupn 97 +byte "" +dupn 1 +int 0 +dupn 5 +byte "" +dupn 1 +int 0 +dupn 9 frame_dig -1 int 0 getbit @@ -75,16 +89,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 4 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 8 -load 8 +frame_bury 2 +frame_dig 2 callsub tuplecomplement_0 -store 9 +frame_bury 4 frame_dig -1 -load 8 +frame_dig 2 concat -load 9 +frame_dig 4 concat frame_bury 0 retsub @@ -118,451 +135,453 @@ retsub arraycomplement_4: proto 1 1 byte "" +int 0 +dupn 97 frame_dig -1 int 1 int 0 * getbyte -store 12 +frame_bury 1 frame_dig -1 int 1 int 1 * getbyte -store 13 +frame_bury 2 frame_dig -1 int 1 int 2 * getbyte -store 14 +frame_bury 3 frame_dig -1 int 1 int 3 * getbyte -store 15 +frame_bury 4 frame_dig -1 int 1 int 4 * getbyte -store 16 +frame_bury 5 frame_dig -1 int 1 int 5 * getbyte -store 17 +frame_bury 6 frame_dig -1 int 1 int 6 * getbyte -store 18 +frame_bury 7 frame_dig -1 int 1 int 7 * getbyte -store 19 +frame_bury 8 frame_dig -1 int 1 int 8 * getbyte -store 20 +frame_bury 9 frame_dig -1 int 1 int 9 * getbyte -store 21 +frame_bury 10 frame_dig -1 int 1 int 10 * getbyte -store 22 +frame_bury 11 frame_dig -1 int 1 int 11 * getbyte -store 23 +frame_bury 12 frame_dig -1 int 1 int 12 * getbyte -store 24 +frame_bury 13 frame_dig -1 int 1 int 13 * getbyte -store 25 +frame_bury 14 frame_dig -1 int 1 int 14 * getbyte -store 26 +frame_bury 15 frame_dig -1 int 1 int 15 * getbyte -store 27 +frame_bury 16 frame_dig -1 int 1 int 16 * getbyte -store 28 +frame_bury 17 frame_dig -1 int 1 int 17 * getbyte -store 29 +frame_bury 18 frame_dig -1 int 1 int 18 * getbyte -store 30 +frame_bury 19 frame_dig -1 int 1 int 19 * getbyte -store 31 +frame_bury 20 frame_dig -1 int 1 int 20 * getbyte -store 32 +frame_bury 21 frame_dig -1 int 1 int 21 * getbyte -store 33 +frame_bury 22 frame_dig -1 int 1 int 22 * getbyte -store 34 +frame_bury 23 frame_dig -1 int 1 int 23 * getbyte -store 35 +frame_bury 24 frame_dig -1 int 1 int 24 * getbyte -store 36 +frame_bury 25 frame_dig -1 int 1 int 25 * getbyte -store 37 +frame_bury 26 frame_dig -1 int 1 int 26 * getbyte -store 38 +frame_bury 27 frame_dig -1 int 1 int 27 * getbyte -store 39 +frame_bury 28 frame_dig -1 int 1 int 28 * getbyte -store 40 +frame_bury 29 frame_dig -1 int 1 int 29 * getbyte -store 41 +frame_bury 30 frame_dig -1 int 1 int 30 * getbyte -store 42 +frame_bury 31 frame_dig -1 int 1 int 31 * getbyte -store 43 -load 12 +frame_bury 32 +frame_dig 1 callsub numericalcomp_3 -store 12 -load 13 +frame_bury 1 +frame_dig 2 callsub numericalcomp_3 -store 13 -load 14 +frame_bury 2 +frame_dig 3 callsub numericalcomp_3 -store 14 -load 15 +frame_bury 3 +frame_dig 4 callsub numericalcomp_3 -store 15 -load 16 +frame_bury 4 +frame_dig 5 callsub numericalcomp_3 -store 16 -load 17 +frame_bury 5 +frame_dig 6 callsub numericalcomp_3 -store 17 -load 18 +frame_bury 6 +frame_dig 7 callsub numericalcomp_3 -store 18 -load 19 +frame_bury 7 +frame_dig 8 callsub numericalcomp_3 -store 19 -load 20 +frame_bury 8 +frame_dig 9 callsub numericalcomp_3 -store 20 -load 21 +frame_bury 9 +frame_dig 10 callsub numericalcomp_3 -store 21 -load 22 +frame_bury 10 +frame_dig 11 callsub numericalcomp_3 -store 22 -load 23 +frame_bury 11 +frame_dig 12 callsub numericalcomp_3 -store 23 -load 24 +frame_bury 12 +frame_dig 13 callsub numericalcomp_3 -store 24 -load 25 +frame_bury 13 +frame_dig 14 callsub numericalcomp_3 -store 25 -load 26 +frame_bury 14 +frame_dig 15 callsub numericalcomp_3 -store 26 -load 27 +frame_bury 15 +frame_dig 16 callsub numericalcomp_3 -store 27 -load 28 +frame_bury 16 +frame_dig 17 callsub numericalcomp_3 -store 28 -load 29 +frame_bury 17 +frame_dig 18 callsub numericalcomp_3 -store 29 -load 30 +frame_bury 18 +frame_dig 19 callsub numericalcomp_3 -store 30 -load 31 +frame_bury 19 +frame_dig 20 callsub numericalcomp_3 -store 31 -load 32 +frame_bury 20 +frame_dig 21 callsub numericalcomp_3 -store 32 -load 33 +frame_bury 21 +frame_dig 22 callsub numericalcomp_3 -store 33 -load 34 +frame_bury 22 +frame_dig 23 callsub numericalcomp_3 -store 34 -load 35 +frame_bury 23 +frame_dig 24 callsub numericalcomp_3 -store 35 -load 36 +frame_bury 24 +frame_dig 25 callsub numericalcomp_3 -store 36 -load 37 +frame_bury 25 +frame_dig 26 callsub numericalcomp_3 -store 37 -load 38 +frame_bury 26 +frame_dig 27 callsub numericalcomp_3 -store 38 -load 39 +frame_bury 27 +frame_dig 28 callsub numericalcomp_3 -store 39 -load 40 +frame_bury 28 +frame_dig 29 callsub numericalcomp_3 -store 40 -load 41 +frame_bury 29 +frame_dig 30 callsub numericalcomp_3 -store 41 -load 42 +frame_bury 30 +frame_dig 31 callsub numericalcomp_3 -store 42 -load 43 +frame_bury 31 +frame_dig 32 callsub numericalcomp_3 -store 43 +frame_bury 32 byte 0x00 int 0 -load 12 +frame_dig 1 setbyte byte 0x00 int 0 -load 13 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 14 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 15 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 16 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 17 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 18 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 19 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 20 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 21 +frame_dig 10 setbyte concat byte 0x00 int 0 -load 22 +frame_dig 11 setbyte concat byte 0x00 int 0 -load 23 +frame_dig 12 setbyte concat byte 0x00 int 0 -load 24 +frame_dig 13 setbyte concat byte 0x00 int 0 -load 25 +frame_dig 14 setbyte concat byte 0x00 int 0 -load 26 +frame_dig 15 setbyte concat byte 0x00 int 0 -load 27 +frame_dig 16 setbyte concat byte 0x00 int 0 -load 28 +frame_dig 17 setbyte concat byte 0x00 int 0 -load 29 +frame_dig 18 setbyte concat byte 0x00 int 0 -load 30 +frame_dig 19 setbyte concat byte 0x00 int 0 -load 31 +frame_dig 20 setbyte concat byte 0x00 int 0 -load 32 +frame_dig 21 setbyte concat byte 0x00 int 0 -load 33 +frame_dig 22 setbyte concat byte 0x00 int 0 -load 34 +frame_dig 23 setbyte concat byte 0x00 int 0 -load 35 +frame_dig 24 setbyte concat byte 0x00 int 0 -load 36 +frame_dig 25 setbyte concat byte 0x00 int 0 -load 37 +frame_dig 26 setbyte concat byte 0x00 int 0 -load 38 +frame_dig 27 setbyte concat byte 0x00 int 0 -load 39 +frame_dig 28 setbyte concat byte 0x00 int 0 -load 40 +frame_dig 29 setbyte concat byte 0x00 int 0 -load 41 +frame_dig 30 setbyte concat byte 0x00 int 0 -load 42 +frame_dig 31 setbyte concat byte 0x00 int 0 -load 43 +frame_dig 32 setbyte concat frame_bury 0 @@ -572,25 +591,27 @@ retsub tuplecomplement_5: proto 1 1 byte "" +int 0 +dupn 5 frame_dig -1 int 0 extract_uint64 -store 10 +frame_bury 2 frame_dig -1 int 64 getbit -store 11 -load 10 +frame_bury 3 +frame_dig 2 callsub numericalcomp_11 -store 10 -load 11 +frame_bury 2 +frame_dig 3 callsub boolcomp_12 -store 11 -load 10 +frame_bury 3 +frame_dig 2 itob byte 0x00 int 0 -load 11 +frame_dig 3 setbit concat frame_bury 0 @@ -614,143 +635,145 @@ retsub arraycomplement_7: proto 1 1 byte "" +int 0 +dupn 11 frame_dig -1 int 1 int 0 * getbyte -store 44 +frame_bury 1 frame_dig -1 int 1 int 1 * getbyte -store 45 +frame_bury 2 frame_dig -1 int 1 int 2 * getbyte -store 46 +frame_bury 3 frame_dig -1 int 1 int 3 * getbyte -store 47 +frame_bury 4 frame_dig -1 int 1 int 4 * getbyte -store 48 +frame_bury 5 frame_dig -1 int 1 int 5 * getbyte -store 49 +frame_bury 6 frame_dig -1 int 1 int 6 * getbyte -store 50 +frame_bury 7 frame_dig -1 int 1 int 7 * getbyte -store 51 +frame_bury 8 frame_dig -1 int 1 int 8 * getbyte -store 52 +frame_bury 9 frame_dig -1 int 1 int 9 * getbyte -store 53 -load 44 +frame_bury 10 +frame_dig 1 callsub numericalcomp_6 -store 44 -load 45 +frame_bury 1 +frame_dig 2 callsub numericalcomp_6 -store 45 -load 46 +frame_bury 2 +frame_dig 3 callsub numericalcomp_6 -store 46 -load 47 +frame_bury 3 +frame_dig 4 callsub numericalcomp_6 -store 47 -load 48 +frame_bury 4 +frame_dig 5 callsub numericalcomp_6 -store 48 -load 49 +frame_bury 5 +frame_dig 6 callsub numericalcomp_6 -store 49 -load 50 +frame_bury 6 +frame_dig 7 callsub numericalcomp_6 -store 50 -load 51 +frame_bury 7 +frame_dig 8 callsub numericalcomp_6 -store 51 -load 52 +frame_bury 8 +frame_dig 9 callsub numericalcomp_6 -store 52 -load 53 +frame_bury 9 +frame_dig 10 callsub numericalcomp_6 -store 53 +frame_bury 10 byte 0x00 int 0 -load 44 +frame_dig 1 setbyte byte 0x00 int 0 -load 45 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 46 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 47 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 48 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 49 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 50 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 51 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 52 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 53 +frame_dig 10 setbyte concat frame_bury 0 @@ -771,46 +794,48 @@ retsub arraycomplement_9: proto 1 1 byte "" +int 0 +dupn 5 frame_dig -1 int 0 getbit -store 54 +frame_bury 1 frame_dig -1 int 1 getbit -store 55 +frame_bury 2 frame_dig -1 int 2 getbit -store 56 +frame_bury 3 frame_dig -1 int 3 getbit -store 57 -load 54 +frame_bury 4 +frame_dig 1 callsub boolcomp_8 -store 54 -load 55 +frame_bury 1 +frame_dig 2 callsub boolcomp_8 -store 55 -load 56 +frame_bury 2 +frame_dig 3 callsub boolcomp_8 -store 56 -load 57 +frame_bury 3 +frame_dig 4 callsub boolcomp_8 -store 57 +frame_bury 4 byte 0x00 int 0 -load 54 +frame_dig 1 setbit int 1 -load 55 +frame_dig 2 setbit int 2 -load 56 +frame_dig 3 setbit int 3 -load 57 +frame_dig 4 setbit frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte)_v8.teal index c91fe2871..585707784 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 5 frame_dig -1 int 0 getbit @@ -45,16 +47,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 4 -load 4 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 5 +frame_bury 2 frame_dig -1 -load 4 +frame_dig 1 concat -load 5 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string)_v8.teal index dbb2b1b5e..765aa30d1 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string)_v8.teal @@ -15,6 +15,16 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 4 +byte "" +dupn 1 +int 0 +dupn 97 +byte "" +dupn 1 +int 0 +dupn 10 frame_dig -1 int 0 getbit @@ -58,16 +68,16 @@ concat load 2 concat load 3 -store 14 -load 14 -store 13 +store 9 +load 9 +store 8 int 36 -store 12 -load 12 +frame_bury 117 +frame_dig 117 itob extract 6 0 concat -load 13 +load 8 concat frame_bury 0 retsub @@ -76,64 +86,67 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 6 -load 6 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 7 +frame_bury 2 frame_dig -1 -store 11 -load 11 -store 10 +store 7 +load 7 +store 6 int 6 -store 8 -load 8 -load 11 +frame_bury 3 +frame_dig 3 +load 7 len + -store 9 -load 9 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 8 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 7 load 6 -store 11 -load 10 -load 11 +load 7 concat -store 10 -load 9 -store 8 -load 8 -load 11 +store 6 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 7 len + -store 9 -load 9 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 8 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 7 +load 6 load 7 -store 11 -load 10 -load 11 concat -store 10 -load 9 -store 8 -load 8 +store 6 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 10 +load 6 concat frame_bury 0 retsub @@ -181,451 +194,453 @@ retsub arraycomplement_5: proto 1 1 byte "" +int 0 +dupn 97 frame_dig -1 int 1 int 0 * getbyte -store 15 +frame_bury 1 frame_dig -1 int 1 int 1 * getbyte -store 16 +frame_bury 2 frame_dig -1 int 1 int 2 * getbyte -store 17 +frame_bury 3 frame_dig -1 int 1 int 3 * getbyte -store 18 +frame_bury 4 frame_dig -1 int 1 int 4 * getbyte -store 19 +frame_bury 5 frame_dig -1 int 1 int 5 * getbyte -store 20 +frame_bury 6 frame_dig -1 int 1 int 6 * getbyte -store 21 +frame_bury 7 frame_dig -1 int 1 int 7 * getbyte -store 22 +frame_bury 8 frame_dig -1 int 1 int 8 * getbyte -store 23 +frame_bury 9 frame_dig -1 int 1 int 9 * getbyte -store 24 +frame_bury 10 frame_dig -1 int 1 int 10 * getbyte -store 25 +frame_bury 11 frame_dig -1 int 1 int 11 * getbyte -store 26 +frame_bury 12 frame_dig -1 int 1 int 12 * getbyte -store 27 +frame_bury 13 frame_dig -1 int 1 int 13 * getbyte -store 28 +frame_bury 14 frame_dig -1 int 1 int 14 * getbyte -store 29 +frame_bury 15 frame_dig -1 int 1 int 15 * getbyte -store 30 +frame_bury 16 frame_dig -1 int 1 int 16 * getbyte -store 31 +frame_bury 17 frame_dig -1 int 1 int 17 * getbyte -store 32 +frame_bury 18 frame_dig -1 int 1 int 18 * getbyte -store 33 +frame_bury 19 frame_dig -1 int 1 int 19 * getbyte -store 34 +frame_bury 20 frame_dig -1 int 1 int 20 * getbyte -store 35 +frame_bury 21 frame_dig -1 int 1 int 21 * getbyte -store 36 +frame_bury 22 frame_dig -1 int 1 int 22 * getbyte -store 37 +frame_bury 23 frame_dig -1 int 1 int 23 * getbyte -store 38 +frame_bury 24 frame_dig -1 int 1 int 24 * getbyte -store 39 +frame_bury 25 frame_dig -1 int 1 int 25 * getbyte -store 40 +frame_bury 26 frame_dig -1 int 1 int 26 * getbyte -store 41 +frame_bury 27 frame_dig -1 int 1 int 27 * getbyte -store 42 +frame_bury 28 frame_dig -1 int 1 int 28 * getbyte -store 43 +frame_bury 29 frame_dig -1 int 1 int 29 * getbyte -store 44 +frame_bury 30 frame_dig -1 int 1 int 30 * getbyte -store 45 +frame_bury 31 frame_dig -1 int 1 int 31 * getbyte -store 46 -load 15 +frame_bury 32 +frame_dig 1 callsub numericalcomp_4 -store 15 -load 16 +frame_bury 1 +frame_dig 2 callsub numericalcomp_4 -store 16 -load 17 +frame_bury 2 +frame_dig 3 callsub numericalcomp_4 -store 17 -load 18 +frame_bury 3 +frame_dig 4 callsub numericalcomp_4 -store 18 -load 19 +frame_bury 4 +frame_dig 5 callsub numericalcomp_4 -store 19 -load 20 +frame_bury 5 +frame_dig 6 callsub numericalcomp_4 -store 20 -load 21 +frame_bury 6 +frame_dig 7 callsub numericalcomp_4 -store 21 -load 22 +frame_bury 7 +frame_dig 8 callsub numericalcomp_4 -store 22 -load 23 +frame_bury 8 +frame_dig 9 callsub numericalcomp_4 -store 23 -load 24 +frame_bury 9 +frame_dig 10 callsub numericalcomp_4 -store 24 -load 25 +frame_bury 10 +frame_dig 11 callsub numericalcomp_4 -store 25 -load 26 +frame_bury 11 +frame_dig 12 callsub numericalcomp_4 -store 26 -load 27 +frame_bury 12 +frame_dig 13 callsub numericalcomp_4 -store 27 -load 28 +frame_bury 13 +frame_dig 14 callsub numericalcomp_4 -store 28 -load 29 +frame_bury 14 +frame_dig 15 callsub numericalcomp_4 -store 29 -load 30 +frame_bury 15 +frame_dig 16 callsub numericalcomp_4 -store 30 -load 31 +frame_bury 16 +frame_dig 17 callsub numericalcomp_4 -store 31 -load 32 +frame_bury 17 +frame_dig 18 callsub numericalcomp_4 -store 32 -load 33 +frame_bury 18 +frame_dig 19 callsub numericalcomp_4 -store 33 -load 34 +frame_bury 19 +frame_dig 20 callsub numericalcomp_4 -store 34 -load 35 +frame_bury 20 +frame_dig 21 callsub numericalcomp_4 -store 35 -load 36 +frame_bury 21 +frame_dig 22 callsub numericalcomp_4 -store 36 -load 37 +frame_bury 22 +frame_dig 23 callsub numericalcomp_4 -store 37 -load 38 +frame_bury 23 +frame_dig 24 callsub numericalcomp_4 -store 38 -load 39 +frame_bury 24 +frame_dig 25 callsub numericalcomp_4 -store 39 -load 40 +frame_bury 25 +frame_dig 26 callsub numericalcomp_4 -store 40 -load 41 +frame_bury 26 +frame_dig 27 callsub numericalcomp_4 -store 41 -load 42 +frame_bury 27 +frame_dig 28 callsub numericalcomp_4 -store 42 -load 43 +frame_bury 28 +frame_dig 29 callsub numericalcomp_4 -store 43 -load 44 +frame_bury 29 +frame_dig 30 callsub numericalcomp_4 -store 44 -load 45 +frame_bury 30 +frame_dig 31 callsub numericalcomp_4 -store 45 -load 46 +frame_bury 31 +frame_dig 32 callsub numericalcomp_4 -store 46 +frame_bury 32 byte 0x00 int 0 -load 15 +frame_dig 1 setbyte byte 0x00 int 0 -load 16 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 17 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 18 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 19 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 20 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 21 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 22 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 23 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 24 +frame_dig 10 setbyte concat byte 0x00 int 0 -load 25 +frame_dig 11 setbyte concat byte 0x00 int 0 -load 26 +frame_dig 12 setbyte concat byte 0x00 int 0 -load 27 +frame_dig 13 setbyte concat byte 0x00 int 0 -load 28 +frame_dig 14 setbyte concat byte 0x00 int 0 -load 29 +frame_dig 15 setbyte concat byte 0x00 int 0 -load 30 +frame_dig 16 setbyte concat byte 0x00 int 0 -load 31 +frame_dig 17 setbyte concat byte 0x00 int 0 -load 32 +frame_dig 18 setbyte concat byte 0x00 int 0 -load 33 +frame_dig 19 setbyte concat byte 0x00 int 0 -load 34 +frame_dig 20 setbyte concat byte 0x00 int 0 -load 35 +frame_dig 21 setbyte concat byte 0x00 int 0 -load 36 +frame_dig 22 setbyte concat byte 0x00 int 0 -load 37 +frame_dig 23 setbyte concat byte 0x00 int 0 -load 38 +frame_dig 24 setbyte concat byte 0x00 int 0 -load 39 +frame_dig 25 setbyte concat byte 0x00 int 0 -load 40 +frame_dig 26 setbyte concat byte 0x00 int 0 -load 41 +frame_dig 27 setbyte concat byte 0x00 int 0 -load 42 +frame_dig 28 setbyte concat byte 0x00 int 0 -load 43 +frame_dig 29 setbyte concat byte 0x00 int 0 -load 44 +frame_dig 30 setbyte concat byte 0x00 int 0 -load 45 +frame_dig 31 setbyte concat byte 0x00 int 0 -load 46 +frame_dig 32 setbyte concat frame_bury 0 @@ -635,6 +650,8 @@ retsub stringreverse_6: proto 1 1 byte "" +int 0 +dupn 8 frame_dig -1 int 1 int 0 @@ -642,7 +659,7 @@ int 0 int 2 + getbyte -store 49 +frame_bury 3 frame_dig -1 int 1 int 1 @@ -650,7 +667,7 @@ int 1 int 2 + getbyte -store 48 +frame_bury 2 frame_dig -1 int 1 int 2 @@ -658,24 +675,24 @@ int 2 int 2 + getbyte -store 47 +frame_bury 1 int 3 -store 50 -load 50 +frame_bury 9 +frame_dig 9 itob extract 6 0 byte 0x00 int 0 -load 47 +frame_dig 1 setbyte byte 0x00 int 0 -load 48 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 49 +frame_dig 3 setbyte concat concat diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string,(address,(uint32,string[],bool[2],(byte),uint8)[2],string,bool[]))[]_2_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string,(address,(uint32,string[],bool[2],(byte),uint8)[2],string,bool[]))[]_2_v8.teal index ac2ca105f..664c612c0 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string,(address,(uint32,string[],bool[2],(byte),uint8)[2],string,bool[]))[]_2_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string,(address,(uint32,string[],bool[2],(byte),uint8)[2],string,bool[]))[]_2_v8.teal @@ -15,6 +15,26 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +byte "" +dupn 3 +int 0 +dupn 3 +byte "" +dupn 1 +int 0 +dupn 97 +byte "" +dupn 1 +int 0 +dupn 8 +byte "" +dupn 1 +int 0 +byte "" +int 0 +byte "" +dupn 1 frame_dig -1 int 0 getbit @@ -70,37 +90,37 @@ concat load 2 concat load 3 -store 29 -load 29 -store 28 +store 14 +load 14 +store 13 int 38 -store 26 -load 26 -load 29 +store 11 +load 11 +load 14 len + -store 27 -load 27 +store 12 +load 12 int 65536 < assert -load 26 +load 11 itob extract 6 0 concat load 4 -store 29 -load 28 -load 29 -concat -store 28 -load 27 -store 26 -load 26 +store 14 +load 13 +load 14 +concat +store 13 +load 12 +store 11 +load 11 itob extract 6 0 concat -load 28 +load 13 concat frame_bury 0 retsub @@ -109,6 +129,9 @@ retsub arraycomplement_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 4 frame_dig -1 frame_dig -1 int 2 @@ -125,8 +148,8 @@ int 1 frame_dig -1 int 0 extract_uint16 -store 15 -load 15 +frame_bury 3 +frame_dig 3 == bnz arraycomplement_1_l5 frame_dig -1 @@ -142,7 +165,7 @@ int 2 + arraycomplement_1_l2: substring3 -store 13 +frame_bury 1 frame_dig -1 frame_dig -1 int 2 @@ -159,8 +182,8 @@ int 1 frame_dig -1 int 0 extract_uint16 -store 16 -load 16 +frame_bury 4 +frame_dig 4 == bnz arraycomplement_1_l4 frame_dig -1 @@ -185,49 +208,49 @@ len b arraycomplement_1_l2 arraycomplement_1_l6: substring3 -store 14 -load 13 +frame_bury 2 +frame_dig 1 callsub tuplecomplement_0 -store 13 -load 14 +frame_bury 1 +frame_dig 2 callsub tuplecomplement_0 -store 14 +frame_bury 2 int 2 -store 21 -load 21 +frame_bury 7 +frame_dig 7 itob extract 6 0 -load 13 -store 20 -load 20 -store 19 +frame_dig 1 +store 10 +load 10 +store 9 int 4 -store 17 -load 17 -load 20 +frame_bury 5 +frame_dig 5 +load 10 len + -store 18 -load 18 +frame_bury 6 +frame_dig 6 int 65536 < assert -load 17 +frame_dig 5 itob extract 6 0 -load 14 -store 20 -load 19 -load 20 +frame_dig 2 +store 10 +load 9 +load 10 concat -store 19 -load 18 -store 17 -load 17 +store 9 +frame_dig 6 +frame_bury 5 +frame_dig 5 itob extract 6 0 concat -load 19 +load 9 concat concat frame_bury 0 @@ -237,64 +260,67 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 7 -load 7 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 8 +frame_bury 2 frame_dig -1 -store 12 -load 12 -store 11 +store 8 +load 8 +store 7 int 6 -store 9 -load 9 -load 12 +frame_bury 3 +frame_dig 3 +load 8 len + -store 10 -load 10 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 9 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 8 load 7 -store 12 -load 11 -load 12 +load 8 concat -store 11 -load 10 -store 9 -load 9 -load 12 +store 7 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 8 len + -store 10 -load 10 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 9 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 8 +load 7 load 8 -store 12 -load 11 -load 12 concat -store 11 -load 10 -store 9 -load 9 +store 7 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 11 +load 7 concat frame_bury 0 retsub @@ -342,451 +368,453 @@ retsub arraycomplement_6: proto 1 1 byte "" +int 0 +dupn 97 frame_dig -1 int 1 int 0 * getbyte -store 30 +frame_bury 1 frame_dig -1 int 1 int 1 * getbyte -store 31 +frame_bury 2 frame_dig -1 int 1 int 2 * getbyte -store 32 +frame_bury 3 frame_dig -1 int 1 int 3 * getbyte -store 33 +frame_bury 4 frame_dig -1 int 1 int 4 * getbyte -store 34 +frame_bury 5 frame_dig -1 int 1 int 5 * getbyte -store 35 +frame_bury 6 frame_dig -1 int 1 int 6 * getbyte -store 36 +frame_bury 7 frame_dig -1 int 1 int 7 * getbyte -store 37 +frame_bury 8 frame_dig -1 int 1 int 8 * getbyte -store 38 +frame_bury 9 frame_dig -1 int 1 int 9 * getbyte -store 39 +frame_bury 10 frame_dig -1 int 1 int 10 * getbyte -store 40 +frame_bury 11 frame_dig -1 int 1 int 11 * getbyte -store 41 +frame_bury 12 frame_dig -1 int 1 int 12 * getbyte -store 42 +frame_bury 13 frame_dig -1 int 1 int 13 * getbyte -store 43 +frame_bury 14 frame_dig -1 int 1 int 14 * getbyte -store 44 +frame_bury 15 frame_dig -1 int 1 int 15 * getbyte -store 45 +frame_bury 16 frame_dig -1 int 1 int 16 * getbyte -store 46 +frame_bury 17 frame_dig -1 int 1 int 17 * getbyte -store 47 +frame_bury 18 frame_dig -1 int 1 int 18 * getbyte -store 48 +frame_bury 19 frame_dig -1 int 1 int 19 * getbyte -store 49 +frame_bury 20 frame_dig -1 int 1 int 20 * getbyte -store 50 +frame_bury 21 frame_dig -1 int 1 int 21 * getbyte -store 51 +frame_bury 22 frame_dig -1 int 1 int 22 * getbyte -store 52 +frame_bury 23 frame_dig -1 int 1 int 23 * getbyte -store 53 +frame_bury 24 frame_dig -1 int 1 int 24 * getbyte -store 54 +frame_bury 25 frame_dig -1 int 1 int 25 * getbyte -store 55 +frame_bury 26 frame_dig -1 int 1 int 26 * getbyte -store 56 +frame_bury 27 frame_dig -1 int 1 int 27 * getbyte -store 57 +frame_bury 28 frame_dig -1 int 1 int 28 * getbyte -store 58 +frame_bury 29 frame_dig -1 int 1 int 29 * getbyte -store 59 +frame_bury 30 frame_dig -1 int 1 int 30 * getbyte -store 60 +frame_bury 31 frame_dig -1 int 1 int 31 * getbyte -store 61 -load 30 +frame_bury 32 +frame_dig 1 callsub numericalcomp_5 -store 30 -load 31 +frame_bury 1 +frame_dig 2 callsub numericalcomp_5 -store 31 -load 32 +frame_bury 2 +frame_dig 3 callsub numericalcomp_5 -store 32 -load 33 +frame_bury 3 +frame_dig 4 callsub numericalcomp_5 -store 33 -load 34 +frame_bury 4 +frame_dig 5 callsub numericalcomp_5 -store 34 -load 35 +frame_bury 5 +frame_dig 6 callsub numericalcomp_5 -store 35 -load 36 +frame_bury 6 +frame_dig 7 callsub numericalcomp_5 -store 36 -load 37 +frame_bury 7 +frame_dig 8 callsub numericalcomp_5 -store 37 -load 38 +frame_bury 8 +frame_dig 9 callsub numericalcomp_5 -store 38 -load 39 +frame_bury 9 +frame_dig 10 callsub numericalcomp_5 -store 39 -load 40 +frame_bury 10 +frame_dig 11 callsub numericalcomp_5 -store 40 -load 41 +frame_bury 11 +frame_dig 12 callsub numericalcomp_5 -store 41 -load 42 +frame_bury 12 +frame_dig 13 callsub numericalcomp_5 -store 42 -load 43 +frame_bury 13 +frame_dig 14 callsub numericalcomp_5 -store 43 -load 44 +frame_bury 14 +frame_dig 15 callsub numericalcomp_5 -store 44 -load 45 +frame_bury 15 +frame_dig 16 callsub numericalcomp_5 -store 45 -load 46 +frame_bury 16 +frame_dig 17 callsub numericalcomp_5 -store 46 -load 47 +frame_bury 17 +frame_dig 18 callsub numericalcomp_5 -store 47 -load 48 +frame_bury 18 +frame_dig 19 callsub numericalcomp_5 -store 48 -load 49 +frame_bury 19 +frame_dig 20 callsub numericalcomp_5 -store 49 -load 50 +frame_bury 20 +frame_dig 21 callsub numericalcomp_5 -store 50 -load 51 +frame_bury 21 +frame_dig 22 callsub numericalcomp_5 -store 51 -load 52 +frame_bury 22 +frame_dig 23 callsub numericalcomp_5 -store 52 -load 53 +frame_bury 23 +frame_dig 24 callsub numericalcomp_5 -store 53 -load 54 +frame_bury 24 +frame_dig 25 callsub numericalcomp_5 -store 54 -load 55 +frame_bury 25 +frame_dig 26 callsub numericalcomp_5 -store 55 -load 56 +frame_bury 26 +frame_dig 27 callsub numericalcomp_5 -store 56 -load 57 +frame_bury 27 +frame_dig 28 callsub numericalcomp_5 -store 57 -load 58 +frame_bury 28 +frame_dig 29 callsub numericalcomp_5 -store 58 -load 59 +frame_bury 29 +frame_dig 30 callsub numericalcomp_5 -store 59 -load 60 +frame_bury 30 +frame_dig 31 callsub numericalcomp_5 -store 60 -load 61 +frame_bury 31 +frame_dig 32 callsub numericalcomp_5 -store 61 +frame_bury 32 byte 0x00 int 0 -load 30 +frame_dig 1 setbyte byte 0x00 int 0 -load 31 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 32 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 33 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 34 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 35 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 36 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 37 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 38 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 39 +frame_dig 10 setbyte concat byte 0x00 int 0 -load 40 +frame_dig 11 setbyte concat byte 0x00 int 0 -load 41 +frame_dig 12 setbyte concat byte 0x00 int 0 -load 42 +frame_dig 13 setbyte concat byte 0x00 int 0 -load 43 +frame_dig 14 setbyte concat byte 0x00 int 0 -load 44 +frame_dig 15 setbyte concat byte 0x00 int 0 -load 45 +frame_dig 16 setbyte concat byte 0x00 int 0 -load 46 +frame_dig 17 setbyte concat byte 0x00 int 0 -load 47 +frame_dig 18 setbyte concat byte 0x00 int 0 -load 48 +frame_dig 19 setbyte concat byte 0x00 int 0 -load 49 +frame_dig 20 setbyte concat byte 0x00 int 0 -load 50 +frame_dig 21 setbyte concat byte 0x00 int 0 -load 51 +frame_dig 22 setbyte concat byte 0x00 int 0 -load 52 +frame_dig 23 setbyte concat byte 0x00 int 0 -load 53 +frame_dig 24 setbyte concat byte 0x00 int 0 -load 54 +frame_dig 25 setbyte concat byte 0x00 int 0 -load 55 +frame_dig 26 setbyte concat byte 0x00 int 0 -load 56 +frame_dig 27 setbyte concat byte 0x00 int 0 -load 57 +frame_dig 28 setbyte concat byte 0x00 int 0 -load 58 +frame_dig 29 setbyte concat byte 0x00 int 0 -load 59 +frame_dig 30 setbyte concat byte 0x00 int 0 -load 60 +frame_dig 31 setbyte concat byte 0x00 int 0 -load 61 +frame_dig 32 setbyte concat frame_bury 0 @@ -796,6 +824,8 @@ retsub stringreverse_7: proto 1 1 byte "" +int 0 +dupn 8 frame_dig -1 int 1 int 0 @@ -803,7 +833,7 @@ int 0 int 2 + getbyte -store 64 +frame_bury 3 frame_dig -1 int 1 int 1 @@ -811,7 +841,7 @@ int 1 int 2 + getbyte -store 63 +frame_bury 2 frame_dig -1 int 1 int 2 @@ -819,24 +849,24 @@ int 2 int 2 + getbyte -store 62 +frame_bury 1 int 3 -store 65 -load 65 +frame_bury 9 +frame_dig 9 itob extract 6 0 byte 0x00 int 0 -load 62 +frame_dig 1 setbyte byte 0x00 int 0 -load 63 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 64 +frame_dig 3 setbyte concat concat @@ -847,9 +877,28 @@ retsub tuplecomplement_8: proto 1 1 byte "" +int 0 +byte "" +int 0 +byte "" +dupn 2 +int 0 +dupn 1 +byte "" +dupn 1 +int 0 +dupn 97 +byte "" +dupn 6 +int 0 +dupn 3 +byte "" +dupn 4 +int 0 +dupn 2 frame_dig -1 extract 0 32 -store 22 +frame_bury 2 frame_dig -1 frame_dig -1 int 32 @@ -858,7 +907,7 @@ frame_dig -1 int 34 extract_uint16 substring3 -store 23 +frame_bury 3 frame_dig -1 frame_dig -1 int 34 @@ -867,7 +916,7 @@ frame_dig -1 int 36 extract_uint16 substring3 -store 24 +frame_bury 4 frame_dig -1 frame_dig -1 int 36 @@ -875,73 +924,73 @@ extract_uint16 dig 1 len substring3 -store 25 -load 22 +frame_bury 5 +frame_dig 2 callsub arraycomplement_10 -store 22 -load 23 +frame_bury 2 +frame_dig 3 callsub arraycomplement_12 -store 23 -load 24 +frame_bury 3 +frame_dig 4 callsub stringreverse_13 -store 24 -load 25 +frame_bury 4 +frame_dig 5 callsub arraycomplement_15 -store 25 -load 22 -load 23 -store 74 -load 74 -store 73 +frame_bury 5 +frame_dig 2 +frame_dig 3 +store 18 +load 18 +store 17 int 38 -store 71 -load 71 -load 74 +store 15 +load 15 +load 18 len + -store 72 -load 72 +store 16 +load 16 int 65536 < assert -load 71 +load 15 itob extract 6 0 concat -load 24 -store 74 -load 73 -load 74 -concat -store 73 -load 72 -store 71 -load 71 -load 74 +frame_dig 4 +store 18 +load 17 +load 18 +concat +store 17 +load 16 +store 15 +load 15 +load 18 len + -store 72 -load 72 +store 16 +load 16 int 65536 < assert -load 71 +load 15 itob extract 6 0 concat -load 25 -store 74 -load 73 -load 74 +frame_dig 5 +store 18 +load 17 +load 18 concat -store 73 -load 72 -store 71 -load 71 +store 17 +load 16 +store 15 +load 15 itob extract 6 0 concat -load 73 +load 17 concat frame_bury 0 retsub @@ -964,451 +1013,453 @@ retsub arraycomplement_10: proto 1 1 byte "" +int 0 +dupn 97 frame_dig -1 int 1 int 0 * getbyte -store 75 +frame_bury 1 frame_dig -1 int 1 int 1 * getbyte -store 76 +frame_bury 2 frame_dig -1 int 1 int 2 * getbyte -store 77 +frame_bury 3 frame_dig -1 int 1 int 3 * getbyte -store 78 +frame_bury 4 frame_dig -1 int 1 int 4 * getbyte -store 79 +frame_bury 5 frame_dig -1 int 1 int 5 * getbyte -store 80 +frame_bury 6 frame_dig -1 int 1 int 6 * getbyte -store 81 +frame_bury 7 frame_dig -1 int 1 int 7 * getbyte -store 82 +frame_bury 8 frame_dig -1 int 1 int 8 * getbyte -store 83 +frame_bury 9 frame_dig -1 int 1 int 9 * getbyte -store 84 +frame_bury 10 frame_dig -1 int 1 int 10 * getbyte -store 85 +frame_bury 11 frame_dig -1 int 1 int 11 * getbyte -store 86 +frame_bury 12 frame_dig -1 int 1 int 12 * getbyte -store 87 +frame_bury 13 frame_dig -1 int 1 int 13 * getbyte -store 88 +frame_bury 14 frame_dig -1 int 1 int 14 * getbyte -store 89 +frame_bury 15 frame_dig -1 int 1 int 15 * getbyte -store 90 +frame_bury 16 frame_dig -1 int 1 int 16 * getbyte -store 91 +frame_bury 17 frame_dig -1 int 1 int 17 * getbyte -store 92 +frame_bury 18 frame_dig -1 int 1 int 18 * getbyte -store 93 +frame_bury 19 frame_dig -1 int 1 int 19 * getbyte -store 94 +frame_bury 20 frame_dig -1 int 1 int 20 * getbyte -store 95 +frame_bury 21 frame_dig -1 int 1 int 21 * getbyte -store 96 +frame_bury 22 frame_dig -1 int 1 int 22 * getbyte -store 97 +frame_bury 23 frame_dig -1 int 1 int 23 * getbyte -store 98 +frame_bury 24 frame_dig -1 int 1 int 24 * getbyte -store 99 +frame_bury 25 frame_dig -1 int 1 int 25 * getbyte -store 100 +frame_bury 26 frame_dig -1 int 1 int 26 * getbyte -store 101 +frame_bury 27 frame_dig -1 int 1 int 27 * getbyte -store 102 +frame_bury 28 frame_dig -1 int 1 int 28 * getbyte -store 103 +frame_bury 29 frame_dig -1 int 1 int 29 * getbyte -store 104 +frame_bury 30 frame_dig -1 int 1 int 30 * getbyte -store 105 +frame_bury 31 frame_dig -1 int 1 int 31 * getbyte -store 106 -load 75 +frame_bury 32 +frame_dig 1 callsub numericalcomp_9 -store 75 -load 76 +frame_bury 1 +frame_dig 2 callsub numericalcomp_9 -store 76 -load 77 +frame_bury 2 +frame_dig 3 callsub numericalcomp_9 -store 77 -load 78 +frame_bury 3 +frame_dig 4 callsub numericalcomp_9 -store 78 -load 79 +frame_bury 4 +frame_dig 5 callsub numericalcomp_9 -store 79 -load 80 +frame_bury 5 +frame_dig 6 callsub numericalcomp_9 -store 80 -load 81 +frame_bury 6 +frame_dig 7 callsub numericalcomp_9 -store 81 -load 82 +frame_bury 7 +frame_dig 8 callsub numericalcomp_9 -store 82 -load 83 +frame_bury 8 +frame_dig 9 callsub numericalcomp_9 -store 83 -load 84 +frame_bury 9 +frame_dig 10 callsub numericalcomp_9 -store 84 -load 85 +frame_bury 10 +frame_dig 11 callsub numericalcomp_9 -store 85 -load 86 +frame_bury 11 +frame_dig 12 callsub numericalcomp_9 -store 86 -load 87 +frame_bury 12 +frame_dig 13 callsub numericalcomp_9 -store 87 -load 88 +frame_bury 13 +frame_dig 14 callsub numericalcomp_9 -store 88 -load 89 +frame_bury 14 +frame_dig 15 callsub numericalcomp_9 -store 89 -load 90 +frame_bury 15 +frame_dig 16 callsub numericalcomp_9 -store 90 -load 91 +frame_bury 16 +frame_dig 17 callsub numericalcomp_9 -store 91 -load 92 +frame_bury 17 +frame_dig 18 callsub numericalcomp_9 -store 92 -load 93 +frame_bury 18 +frame_dig 19 callsub numericalcomp_9 -store 93 -load 94 +frame_bury 19 +frame_dig 20 callsub numericalcomp_9 -store 94 -load 95 +frame_bury 20 +frame_dig 21 callsub numericalcomp_9 -store 95 -load 96 +frame_bury 21 +frame_dig 22 callsub numericalcomp_9 -store 96 -load 97 +frame_bury 22 +frame_dig 23 callsub numericalcomp_9 -store 97 -load 98 +frame_bury 23 +frame_dig 24 callsub numericalcomp_9 -store 98 -load 99 +frame_bury 24 +frame_dig 25 callsub numericalcomp_9 -store 99 -load 100 +frame_bury 25 +frame_dig 26 callsub numericalcomp_9 -store 100 -load 101 +frame_bury 26 +frame_dig 27 callsub numericalcomp_9 -store 101 -load 102 +frame_bury 27 +frame_dig 28 callsub numericalcomp_9 -store 102 -load 103 +frame_bury 28 +frame_dig 29 callsub numericalcomp_9 -store 103 -load 104 +frame_bury 29 +frame_dig 30 callsub numericalcomp_9 -store 104 -load 105 +frame_bury 30 +frame_dig 31 callsub numericalcomp_9 -store 105 -load 106 +frame_bury 31 +frame_dig 32 callsub numericalcomp_9 -store 106 +frame_bury 32 byte 0x00 int 0 -load 75 +frame_dig 1 setbyte byte 0x00 int 0 -load 76 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 77 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 78 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 79 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 80 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 81 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 82 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 83 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 84 +frame_dig 10 setbyte concat byte 0x00 int 0 -load 85 +frame_dig 11 setbyte concat byte 0x00 int 0 -load 86 +frame_dig 12 setbyte concat byte 0x00 int 0 -load 87 +frame_dig 13 setbyte concat byte 0x00 int 0 -load 88 +frame_dig 14 setbyte concat byte 0x00 int 0 -load 89 +frame_dig 15 setbyte concat byte 0x00 int 0 -load 90 +frame_dig 16 setbyte concat byte 0x00 int 0 -load 91 +frame_dig 17 setbyte concat byte 0x00 int 0 -load 92 +frame_dig 18 setbyte concat byte 0x00 int 0 -load 93 +frame_dig 19 setbyte concat byte 0x00 int 0 -load 94 +frame_dig 20 setbyte concat byte 0x00 int 0 -load 95 +frame_dig 21 setbyte concat byte 0x00 int 0 -load 96 +frame_dig 22 setbyte concat byte 0x00 int 0 -load 97 +frame_dig 23 setbyte concat byte 0x00 int 0 -load 98 +frame_dig 24 setbyte concat byte 0x00 int 0 -load 99 +frame_dig 25 setbyte concat byte 0x00 int 0 -load 100 +frame_dig 26 setbyte concat byte 0x00 int 0 -load 101 +frame_dig 27 setbyte concat byte 0x00 int 0 -load 102 +frame_dig 28 setbyte concat byte 0x00 int 0 -load 103 +frame_dig 29 setbyte concat byte 0x00 int 0 -load 104 +frame_dig 30 setbyte concat byte 0x00 int 0 -load 105 +frame_dig 31 setbyte concat byte 0x00 int 0 -load 106 +frame_dig 32 setbyte concat frame_bury 0 @@ -1418,10 +1469,37 @@ retsub tuplecomplement_11: proto 1 1 byte "" +dupn 1 +int 0 +dupn 3 +byte "" +dupn 4 +int 0 +dupn 2 +byte "" +dupn 1 +int 0 +dupn 8 +byte "" +dupn 1 +int 0 +dupn 8 +byte "" +dupn 1 +int 0 +dupn 11 +byte "" +dupn 1 +int 0 +dupn 7 +byte "" +dupn 1 +int 0 +dupn 7 frame_dig -1 int 0 extract_uint32 -store 66 +frame_bury 3 frame_dig -1 frame_dig -1 int 4 @@ -1429,55 +1507,55 @@ extract_uint16 dig 1 len substring3 -store 67 +frame_bury 4 frame_dig -1 extract 6 1 -store 68 +frame_bury 5 frame_dig -1 extract 7 1 -store 69 +frame_bury 6 frame_dig -1 int 8 getbyte -store 70 -load 66 +frame_bury 7 +frame_dig 3 callsub numericalcomp_16 -store 66 -load 67 +frame_bury 3 +frame_dig 4 callsub arraycomplement_18 -store 67 -load 68 +frame_bury 4 +frame_dig 5 callsub arraycomplement_20 -store 68 -load 69 +frame_bury 5 +frame_dig 6 callsub tuplecomplement_21 -store 69 -load 70 +frame_bury 6 +frame_dig 7 callsub numericalcomp_22 -store 70 -load 66 +frame_bury 7 +frame_dig 3 itob extract 4 0 -load 67 -store 116 -load 116 -store 115 +frame_dig 4 +store 22 +load 22 +store 21 int 9 -store 114 -load 114 +frame_bury 68 +frame_dig 68 itob extract 6 0 concat -load 68 +frame_dig 5 concat -load 69 +frame_dig 6 concat byte 0x00 int 0 -load 70 +frame_dig 7 setbyte concat -load 115 +load 21 concat frame_bury 0 retsub @@ -1486,6 +1564,9 @@ retsub arraycomplement_12: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 frame_dig -1 int 2 @@ -1507,7 +1588,7 @@ int 2 extract_uint16 arraycomplement_12_l2: substring3 -store 107 +frame_bury 1 frame_dig -1 frame_dig -1 int 2 @@ -1538,44 +1619,44 @@ len b arraycomplement_12_l2 arraycomplement_12_l6: substring3 -store 108 -load 107 +frame_bury 2 +frame_dig 1 callsub tuplecomplement_11 -store 107 -load 108 +frame_bury 1 +frame_dig 2 callsub tuplecomplement_11 -store 108 -load 107 -store 112 -load 112 -store 111 +frame_bury 2 +frame_dig 1 +store 20 +load 20 +store 19 int 4 -store 109 -load 109 -load 112 +frame_bury 3 +frame_dig 3 +load 20 len + -store 110 -load 110 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 109 +frame_dig 3 itob extract 6 0 -load 108 -store 112 -load 111 -load 112 -concat -store 111 -load 110 -store 109 -load 109 +frame_dig 2 +store 20 +load 19 +load 20 +concat +store 19 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 111 +load 19 concat frame_bury 0 retsub @@ -1584,6 +1665,8 @@ retsub stringreverse_13: proto 1 1 byte "" +int 0 +dupn 8 frame_dig -1 int 1 int 0 @@ -1591,7 +1674,7 @@ int 0 int 2 + getbyte -store 136 +frame_bury 3 frame_dig -1 int 1 int 1 @@ -1599,7 +1682,7 @@ int 1 int 2 + getbyte -store 135 +frame_bury 2 frame_dig -1 int 1 int 2 @@ -1607,24 +1690,24 @@ int 2 int 2 + getbyte -store 134 +frame_bury 1 int 3 -store 137 -load 137 +frame_bury 9 +frame_dig 9 itob extract 6 0 byte 0x00 int 0 -load 134 +frame_dig 1 setbyte byte 0x00 int 0 -load 135 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 136 +frame_dig 3 setbyte concat concat @@ -1646,47 +1729,49 @@ retsub arraycomplement_15: proto 1 1 byte "" +int 0 +dupn 5 frame_dig -1 int 0 int 16 + getbit -store 138 +frame_bury 1 frame_dig -1 int 1 int 16 + getbit -store 139 +frame_bury 2 frame_dig -1 int 2 int 16 + getbit -store 140 -load 138 +frame_bury 3 +frame_dig 1 callsub boolcomp_14 -store 138 -load 139 +frame_bury 1 +frame_dig 2 callsub boolcomp_14 -store 139 -load 140 +frame_bury 2 +frame_dig 3 callsub boolcomp_14 -store 140 +frame_bury 3 int 3 -store 141 -load 141 +frame_bury 6 +frame_dig 6 itob extract 6 0 byte 0x00 int 0 -load 138 +frame_dig 1 setbit int 1 -load 139 +frame_dig 2 setbit int 2 -load 140 +frame_dig 3 setbit concat frame_bury 0 @@ -1710,6 +1795,8 @@ retsub stringreverse_17: proto 1 1 byte "" +int 0 +dupn 8 frame_dig -1 int 1 int 0 @@ -1717,7 +1804,7 @@ int 0 int 2 + getbyte -store 130 +frame_bury 3 frame_dig -1 int 1 int 1 @@ -1725,7 +1812,7 @@ int 1 int 2 + getbyte -store 129 +frame_bury 2 frame_dig -1 int 1 int 2 @@ -1733,24 +1820,24 @@ int 2 int 2 + getbyte -store 128 +frame_bury 1 int 3 -store 131 -load 131 +frame_bury 9 +frame_dig 9 itob extract 6 0 byte 0x00 int 0 -load 128 +frame_dig 1 setbyte byte 0x00 int 0 -load 129 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 130 +frame_dig 3 setbyte concat concat @@ -1761,6 +1848,21 @@ retsub arraycomplement_18: proto 1 1 byte "" +dupn 3 +int 0 +dupn 2 +byte "" +dupn 1 +int 0 +dupn 8 +byte "" +dupn 1 +int 0 +dupn 8 +byte "" +dupn 1 +int 0 +dupn 11 frame_dig -1 frame_dig -1 int 2 @@ -1777,8 +1879,8 @@ int 1 frame_dig -1 int 0 extract_uint16 -store 120 -load 120 +frame_bury 4 +frame_dig 4 == bnz arraycomplement_18_l8 frame_dig -1 @@ -1794,7 +1896,7 @@ int 2 + arraycomplement_18_l2: substring3 -store 117 +frame_bury 1 frame_dig -1 frame_dig -1 int 2 @@ -1811,8 +1913,8 @@ int 1 frame_dig -1 int 0 extract_uint16 -store 121 -load 121 +frame_bury 5 +frame_dig 5 == bnz arraycomplement_18_l7 frame_dig -1 @@ -1828,7 +1930,7 @@ int 2 + arraycomplement_18_l4: substring3 -store 118 +frame_bury 2 frame_dig -1 frame_dig -1 int 2 @@ -1845,8 +1947,8 @@ int 1 frame_dig -1 int 0 extract_uint16 -store 122 -load 122 +frame_bury 6 +frame_dig 6 == bnz arraycomplement_18_l6 frame_dig -1 @@ -1875,73 +1977,73 @@ len b arraycomplement_18_l2 arraycomplement_18_l9: substring3 -store 119 -load 117 +frame_bury 3 +frame_dig 1 callsub stringreverse_17 -store 117 -load 118 +frame_bury 1 +frame_dig 2 callsub stringreverse_17 -store 118 -load 119 +frame_bury 2 +frame_dig 3 callsub stringreverse_17 -store 119 +frame_bury 3 int 3 -store 127 -load 127 +frame_bury 42 +frame_dig 42 itob extract 6 0 -load 117 -store 126 -load 126 -store 125 +frame_dig 1 +store 24 +load 24 +store 23 int 6 -store 123 -load 123 -load 126 +frame_bury 40 +frame_dig 40 +load 24 len + -store 124 -load 124 +frame_bury 41 +frame_dig 41 int 65536 < assert -load 123 +frame_dig 40 itob extract 6 0 -load 118 -store 126 -load 125 -load 126 -concat -store 125 -load 124 -store 123 -load 123 -load 126 +frame_dig 2 +store 24 +load 23 +load 24 +concat +store 23 +frame_dig 41 +frame_bury 40 +frame_dig 40 +load 24 len + -store 124 -load 124 +frame_bury 41 +frame_dig 41 int 65536 < assert -load 123 +frame_dig 40 itob extract 6 0 concat -load 119 -store 126 -load 125 -load 126 +frame_dig 3 +store 24 +load 23 +load 24 concat -store 125 -load 124 -store 123 -load 123 +store 23 +frame_dig 41 +frame_bury 40 +frame_dig 40 itob extract 6 0 concat -load 125 +load 23 concat concat frame_bury 0 @@ -1962,26 +2064,28 @@ retsub arraycomplement_20: proto 1 1 byte "" +int 0 +dupn 7 frame_dig -1 int 0 getbit -store 132 +frame_bury 1 frame_dig -1 int 1 getbit -store 133 -load 132 +frame_bury 2 +frame_dig 1 callsub boolcomp_19 -store 132 -load 133 +frame_bury 1 +frame_dig 2 callsub boolcomp_19 -store 133 +frame_bury 2 byte 0x00 int 0 -load 132 +frame_dig 1 setbit int 1 -load 133 +frame_dig 2 setbit frame_bury 0 retsub @@ -1990,16 +2094,18 @@ retsub tuplecomplement_21: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 int 0 getbyte -store 113 -load 113 +frame_bury 3 +frame_dig 3 callsub numericalcomp_23 -store 113 +frame_bury 3 byte 0x00 int 0 -load 113 +frame_dig 3 setbyte frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string,uint64)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string,uint64)_v8.teal index ac3980f9e..87a31aea2 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string,uint64)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(bool,byte,address,string,uint64)_v8.teal @@ -15,6 +15,16 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 4 +byte "" +dupn 1 +int 0 +dupn 97 +byte "" +dupn 1 +int 0 +dupn 12 frame_dig -1 int 0 getbit @@ -65,19 +75,19 @@ concat load 2 concat load 3 -store 15 -load 15 -store 14 +store 10 +load 10 +store 9 int 44 -store 13 -load 13 +frame_bury 119 +frame_dig 119 itob extract 6 0 concat load 4 itob concat -load 14 +load 9 concat frame_bury 0 retsub @@ -86,64 +96,67 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 7 -load 7 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 8 +frame_bury 2 frame_dig -1 -store 12 -load 12 -store 11 +store 8 +load 8 +store 7 int 6 -store 9 -load 9 -load 12 +frame_bury 3 +frame_dig 3 +load 8 len + -store 10 -load 10 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 9 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 8 load 7 -store 12 -load 11 -load 12 +load 8 concat -store 11 -load 10 -store 9 -load 9 -load 12 +store 7 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 8 len + -store 10 -load 10 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 9 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 8 +load 7 load 8 -store 12 -load 11 -load 12 concat -store 11 -load 10 -store 9 -load 9 +store 7 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 11 +load 7 concat frame_bury 0 retsub @@ -191,451 +204,453 @@ retsub arraycomplement_5: proto 1 1 byte "" +int 0 +dupn 97 frame_dig -1 int 1 int 0 * getbyte -store 16 +frame_bury 1 frame_dig -1 int 1 int 1 * getbyte -store 17 +frame_bury 2 frame_dig -1 int 1 int 2 * getbyte -store 18 +frame_bury 3 frame_dig -1 int 1 int 3 * getbyte -store 19 +frame_bury 4 frame_dig -1 int 1 int 4 * getbyte -store 20 +frame_bury 5 frame_dig -1 int 1 int 5 * getbyte -store 21 +frame_bury 6 frame_dig -1 int 1 int 6 * getbyte -store 22 +frame_bury 7 frame_dig -1 int 1 int 7 * getbyte -store 23 +frame_bury 8 frame_dig -1 int 1 int 8 * getbyte -store 24 +frame_bury 9 frame_dig -1 int 1 int 9 * getbyte -store 25 +frame_bury 10 frame_dig -1 int 1 int 10 * getbyte -store 26 +frame_bury 11 frame_dig -1 int 1 int 11 * getbyte -store 27 +frame_bury 12 frame_dig -1 int 1 int 12 * getbyte -store 28 +frame_bury 13 frame_dig -1 int 1 int 13 * getbyte -store 29 +frame_bury 14 frame_dig -1 int 1 int 14 * getbyte -store 30 +frame_bury 15 frame_dig -1 int 1 int 15 * getbyte -store 31 +frame_bury 16 frame_dig -1 int 1 int 16 * getbyte -store 32 +frame_bury 17 frame_dig -1 int 1 int 17 * getbyte -store 33 +frame_bury 18 frame_dig -1 int 1 int 18 * getbyte -store 34 +frame_bury 19 frame_dig -1 int 1 int 19 * getbyte -store 35 +frame_bury 20 frame_dig -1 int 1 int 20 * getbyte -store 36 +frame_bury 21 frame_dig -1 int 1 int 21 * getbyte -store 37 +frame_bury 22 frame_dig -1 int 1 int 22 * getbyte -store 38 +frame_bury 23 frame_dig -1 int 1 int 23 * getbyte -store 39 +frame_bury 24 frame_dig -1 int 1 int 24 * getbyte -store 40 +frame_bury 25 frame_dig -1 int 1 int 25 * getbyte -store 41 +frame_bury 26 frame_dig -1 int 1 int 26 * getbyte -store 42 +frame_bury 27 frame_dig -1 int 1 int 27 * getbyte -store 43 +frame_bury 28 frame_dig -1 int 1 int 28 * getbyte -store 44 +frame_bury 29 frame_dig -1 int 1 int 29 * getbyte -store 45 +frame_bury 30 frame_dig -1 int 1 int 30 * getbyte -store 46 +frame_bury 31 frame_dig -1 int 1 int 31 * getbyte -store 47 -load 16 +frame_bury 32 +frame_dig 1 callsub numericalcomp_4 -store 16 -load 17 +frame_bury 1 +frame_dig 2 callsub numericalcomp_4 -store 17 -load 18 +frame_bury 2 +frame_dig 3 callsub numericalcomp_4 -store 18 -load 19 +frame_bury 3 +frame_dig 4 callsub numericalcomp_4 -store 19 -load 20 +frame_bury 4 +frame_dig 5 callsub numericalcomp_4 -store 20 -load 21 +frame_bury 5 +frame_dig 6 callsub numericalcomp_4 -store 21 -load 22 +frame_bury 6 +frame_dig 7 callsub numericalcomp_4 -store 22 -load 23 +frame_bury 7 +frame_dig 8 callsub numericalcomp_4 -store 23 -load 24 +frame_bury 8 +frame_dig 9 callsub numericalcomp_4 -store 24 -load 25 +frame_bury 9 +frame_dig 10 callsub numericalcomp_4 -store 25 -load 26 +frame_bury 10 +frame_dig 11 callsub numericalcomp_4 -store 26 -load 27 +frame_bury 11 +frame_dig 12 callsub numericalcomp_4 -store 27 -load 28 +frame_bury 12 +frame_dig 13 callsub numericalcomp_4 -store 28 -load 29 +frame_bury 13 +frame_dig 14 callsub numericalcomp_4 -store 29 -load 30 +frame_bury 14 +frame_dig 15 callsub numericalcomp_4 -store 30 -load 31 +frame_bury 15 +frame_dig 16 callsub numericalcomp_4 -store 31 -load 32 +frame_bury 16 +frame_dig 17 callsub numericalcomp_4 -store 32 -load 33 +frame_bury 17 +frame_dig 18 callsub numericalcomp_4 -store 33 -load 34 +frame_bury 18 +frame_dig 19 callsub numericalcomp_4 -store 34 -load 35 +frame_bury 19 +frame_dig 20 callsub numericalcomp_4 -store 35 -load 36 +frame_bury 20 +frame_dig 21 callsub numericalcomp_4 -store 36 -load 37 +frame_bury 21 +frame_dig 22 callsub numericalcomp_4 -store 37 -load 38 +frame_bury 22 +frame_dig 23 callsub numericalcomp_4 -store 38 -load 39 +frame_bury 23 +frame_dig 24 callsub numericalcomp_4 -store 39 -load 40 +frame_bury 24 +frame_dig 25 callsub numericalcomp_4 -store 40 -load 41 +frame_bury 25 +frame_dig 26 callsub numericalcomp_4 -store 41 -load 42 +frame_bury 26 +frame_dig 27 callsub numericalcomp_4 -store 42 -load 43 +frame_bury 27 +frame_dig 28 callsub numericalcomp_4 -store 43 -load 44 +frame_bury 28 +frame_dig 29 callsub numericalcomp_4 -store 44 -load 45 +frame_bury 29 +frame_dig 30 callsub numericalcomp_4 -store 45 -load 46 +frame_bury 30 +frame_dig 31 callsub numericalcomp_4 -store 46 -load 47 +frame_bury 31 +frame_dig 32 callsub numericalcomp_4 -store 47 +frame_bury 32 byte 0x00 int 0 -load 16 +frame_dig 1 setbyte byte 0x00 int 0 -load 17 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 18 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 19 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 20 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 21 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 22 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 23 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 24 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 25 +frame_dig 10 setbyte concat byte 0x00 int 0 -load 26 +frame_dig 11 setbyte concat byte 0x00 int 0 -load 27 +frame_dig 12 setbyte concat byte 0x00 int 0 -load 28 +frame_dig 13 setbyte concat byte 0x00 int 0 -load 29 +frame_dig 14 setbyte concat byte 0x00 int 0 -load 30 +frame_dig 15 setbyte concat byte 0x00 int 0 -load 31 +frame_dig 16 setbyte concat byte 0x00 int 0 -load 32 +frame_dig 17 setbyte concat byte 0x00 int 0 -load 33 +frame_dig 18 setbyte concat byte 0x00 int 0 -load 34 +frame_dig 19 setbyte concat byte 0x00 int 0 -load 35 +frame_dig 20 setbyte concat byte 0x00 int 0 -load 36 +frame_dig 21 setbyte concat byte 0x00 int 0 -load 37 +frame_dig 22 setbyte concat byte 0x00 int 0 -load 38 +frame_dig 23 setbyte concat byte 0x00 int 0 -load 39 +frame_dig 24 setbyte concat byte 0x00 int 0 -load 40 +frame_dig 25 setbyte concat byte 0x00 int 0 -load 41 +frame_dig 26 setbyte concat byte 0x00 int 0 -load 42 +frame_dig 27 setbyte concat byte 0x00 int 0 -load 43 +frame_dig 28 setbyte concat byte 0x00 int 0 -load 44 +frame_dig 29 setbyte concat byte 0x00 int 0 -load 45 +frame_dig 30 setbyte concat byte 0x00 int 0 -load 46 +frame_dig 31 setbyte concat byte 0x00 int 0 -load 47 +frame_dig 32 setbyte concat frame_bury 0 @@ -645,6 +660,8 @@ retsub stringreverse_6: proto 1 1 byte "" +int 0 +dupn 8 frame_dig -1 int 1 int 0 @@ -652,7 +669,7 @@ int 0 int 2 + getbyte -store 50 +frame_bury 3 frame_dig -1 int 1 int 1 @@ -660,7 +677,7 @@ int 1 int 2 + getbyte -store 49 +frame_bury 2 frame_dig -1 int 1 int 2 @@ -668,24 +685,24 @@ int 2 int 2 + getbyte -store 48 +frame_bury 1 int 3 -store 51 -load 51 +frame_bury 9 +frame_dig 9 itob extract 6 0 byte 0x00 int 0 -load 48 +frame_dig 1 setbyte byte 0x00 int 0 -load 49 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 50 +frame_dig 3 setbyte concat concat diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(bool,uint64,uint32)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(bool,uint64,uint32)_v8.teal index 8f04b8ad0..3b5d822da 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(bool,uint64,uint32)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(bool,uint64,uint32)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 7 frame_dig -1 int 0 getbit @@ -54,16 +56,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 5 -load 5 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 6 +frame_bury 2 frame_dig -1 -load 5 +frame_dig 1 concat -load 6 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(byte)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(byte)_v8.teal index 4a8d567ff..a6f374016 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(byte)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(byte)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 int 0 getbyte @@ -33,16 +35,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 3 -load 3 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 4 +frame_bury 2 frame_dig -1 -load 3 +frame_dig 1 concat -load 4 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(byte,bool,uint64)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(byte,bool,uint64)_v8.teal index a5fb0355f..8c66003b1 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(byte,bool,uint64)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(byte,bool,uint64)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 7 frame_dig -1 int 0 getbyte @@ -55,16 +57,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 5 -load 5 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 6 +frame_bury 2 frame_dig -1 -load 5 +frame_dig 1 concat -load 6 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(byte[4],(bool,bool),uint64,address)[]_7_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(byte[4],(bool,bool),uint64,address)[]_7_v8.teal index 064b29fc8..93f1d6568 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(byte[4],(bool,bool),uint64,address)[]_7_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(byte[4],(bool,bool),uint64,address)[]_7_v8.teal @@ -15,6 +15,20 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 3 +byte "" +dupn 1 +int 0 +dupn 13 +byte "" +dupn 1 +int 0 +dupn 7 +byte "" +dupn 1 +int 0 +dupn 94 frame_dig -1 extract 0 4 store 0 @@ -55,6 +69,9 @@ retsub arraycomplement_1: proto 1 1 byte "" +dupn 7 +int 0 +dupn 9 frame_dig -1 int 45 int 0 @@ -63,7 +80,7 @@ int 2 + int 45 extract3 -store 12 +frame_bury 1 frame_dig -1 int 45 int 1 @@ -72,7 +89,7 @@ int 2 + int 45 extract3 -store 13 +frame_bury 2 frame_dig -1 int 45 int 2 @@ -81,7 +98,7 @@ int 2 + int 45 extract3 -store 14 +frame_bury 3 frame_dig -1 int 45 int 3 @@ -90,7 +107,7 @@ int 2 + int 45 extract3 -store 15 +frame_bury 4 frame_dig -1 int 45 int 4 @@ -99,7 +116,7 @@ int 2 + int 45 extract3 -store 16 +frame_bury 5 frame_dig -1 int 45 int 5 @@ -108,7 +125,7 @@ int 2 + int 45 extract3 -store 17 +frame_bury 6 frame_dig -1 int 45 int 6 @@ -117,45 +134,45 @@ int 2 + int 45 extract3 -store 18 -load 12 +frame_bury 7 +frame_dig 1 callsub tuplecomplement_0 -store 12 -load 13 +frame_bury 1 +frame_dig 2 callsub tuplecomplement_0 -store 13 -load 14 +frame_bury 2 +frame_dig 3 callsub tuplecomplement_0 -store 14 -load 15 +frame_bury 3 +frame_dig 4 callsub tuplecomplement_0 -store 15 -load 16 +frame_bury 4 +frame_dig 5 callsub tuplecomplement_0 -store 16 -load 17 +frame_bury 5 +frame_dig 6 callsub tuplecomplement_0 -store 17 -load 18 +frame_bury 6 +frame_dig 7 callsub tuplecomplement_0 -store 18 +frame_bury 7 int 7 -store 19 -load 19 +frame_bury 17 +frame_dig 17 itob extract 6 0 -load 12 -load 13 +frame_dig 1 +frame_dig 2 concat -load 14 +frame_dig 3 concat -load 15 +frame_dig 4 concat -load 16 +frame_dig 5 concat -load 17 +frame_dig 6 concat -load 18 +frame_dig 7 concat concat frame_bury 0 @@ -165,64 +182,67 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 6 -load 6 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 7 +frame_bury 2 frame_dig -1 -store 11 -load 11 -store 10 +store 7 +load 7 +store 6 int 6 -store 8 -load 8 -load 11 +frame_bury 3 +frame_dig 3 +load 7 len + -store 9 -load 9 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 8 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 7 load 6 -store 11 -load 10 -load 11 -concat -store 10 -load 9 -store 8 -load 8 -load 11 +load 7 +concat +store 6 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 7 len + -store 9 -load 9 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 8 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 7 +load 6 load 7 -store 11 -load 10 -load 11 -concat -store 10 -load 9 -store 8 -load 8 +concat +store 6 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 10 +load 6 concat frame_bury 0 retsub @@ -245,59 +265,61 @@ retsub arraycomplement_4: proto 1 1 byte "" +int 0 +dupn 13 frame_dig -1 int 1 int 0 * getbyte -store 22 +frame_bury 1 frame_dig -1 int 1 int 1 * getbyte -store 23 +frame_bury 2 frame_dig -1 int 1 int 2 * getbyte -store 24 +frame_bury 3 frame_dig -1 int 1 int 3 * getbyte -store 25 -load 22 +frame_bury 4 +frame_dig 1 callsub numericalcomp_3 -store 22 -load 23 +frame_bury 1 +frame_dig 2 callsub numericalcomp_3 -store 23 -load 24 +frame_bury 2 +frame_dig 3 callsub numericalcomp_3 -store 24 -load 25 +frame_bury 3 +frame_dig 4 callsub numericalcomp_3 -store 25 +frame_bury 4 byte 0x00 int 0 -load 22 +frame_dig 1 setbyte byte 0x00 int 0 -load 23 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 24 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 25 +frame_dig 4 setbyte concat frame_bury 0 @@ -307,26 +329,28 @@ retsub tuplecomplement_5: proto 1 1 byte "" +int 0 +dupn 5 frame_dig -1 int 0 getbit -store 20 +frame_bury 2 frame_dig -1 int 1 getbit -store 21 -load 20 +frame_bury 3 +frame_dig 2 callsub boolcomp_9 -store 20 -load 21 +frame_bury 2 +frame_dig 3 callsub boolcomp_10 -store 21 +frame_bury 3 byte 0x00 int 0 -load 20 +frame_dig 2 setbit int 1 -load 21 +frame_dig 3 setbit frame_bury 0 retsub @@ -359,451 +383,453 @@ retsub arraycomplement_8: proto 1 1 byte "" +int 0 +dupn 97 frame_dig -1 int 1 int 0 * getbyte -store 26 +frame_bury 1 frame_dig -1 int 1 int 1 * getbyte -store 27 +frame_bury 2 frame_dig -1 int 1 int 2 * getbyte -store 28 +frame_bury 3 frame_dig -1 int 1 int 3 * getbyte -store 29 +frame_bury 4 frame_dig -1 int 1 int 4 * getbyte -store 30 +frame_bury 5 frame_dig -1 int 1 int 5 * getbyte -store 31 +frame_bury 6 frame_dig -1 int 1 int 6 * getbyte -store 32 +frame_bury 7 frame_dig -1 int 1 int 7 * getbyte -store 33 +frame_bury 8 frame_dig -1 int 1 int 8 * getbyte -store 34 +frame_bury 9 frame_dig -1 int 1 int 9 * getbyte -store 35 +frame_bury 10 frame_dig -1 int 1 int 10 * getbyte -store 36 +frame_bury 11 frame_dig -1 int 1 int 11 * getbyte -store 37 +frame_bury 12 frame_dig -1 int 1 int 12 * getbyte -store 38 +frame_bury 13 frame_dig -1 int 1 int 13 * getbyte -store 39 +frame_bury 14 frame_dig -1 int 1 int 14 * getbyte -store 40 +frame_bury 15 frame_dig -1 int 1 int 15 * getbyte -store 41 +frame_bury 16 frame_dig -1 int 1 int 16 * getbyte -store 42 +frame_bury 17 frame_dig -1 int 1 int 17 * getbyte -store 43 +frame_bury 18 frame_dig -1 int 1 int 18 * getbyte -store 44 +frame_bury 19 frame_dig -1 int 1 int 19 * getbyte -store 45 +frame_bury 20 frame_dig -1 int 1 int 20 * getbyte -store 46 +frame_bury 21 frame_dig -1 int 1 int 21 * getbyte -store 47 +frame_bury 22 frame_dig -1 int 1 int 22 * getbyte -store 48 +frame_bury 23 frame_dig -1 int 1 int 23 * getbyte -store 49 +frame_bury 24 frame_dig -1 int 1 int 24 * getbyte -store 50 +frame_bury 25 frame_dig -1 int 1 int 25 * getbyte -store 51 +frame_bury 26 frame_dig -1 int 1 int 26 * getbyte -store 52 +frame_bury 27 frame_dig -1 int 1 int 27 * getbyte -store 53 +frame_bury 28 frame_dig -1 int 1 int 28 * getbyte -store 54 +frame_bury 29 frame_dig -1 int 1 int 29 * getbyte -store 55 +frame_bury 30 frame_dig -1 int 1 int 30 * getbyte -store 56 +frame_bury 31 frame_dig -1 int 1 int 31 * getbyte -store 57 -load 26 +frame_bury 32 +frame_dig 1 callsub numericalcomp_7 -store 26 -load 27 +frame_bury 1 +frame_dig 2 callsub numericalcomp_7 -store 27 -load 28 +frame_bury 2 +frame_dig 3 callsub numericalcomp_7 -store 28 -load 29 +frame_bury 3 +frame_dig 4 callsub numericalcomp_7 -store 29 -load 30 +frame_bury 4 +frame_dig 5 callsub numericalcomp_7 -store 30 -load 31 +frame_bury 5 +frame_dig 6 callsub numericalcomp_7 -store 31 -load 32 +frame_bury 6 +frame_dig 7 callsub numericalcomp_7 -store 32 -load 33 +frame_bury 7 +frame_dig 8 callsub numericalcomp_7 -store 33 -load 34 +frame_bury 8 +frame_dig 9 callsub numericalcomp_7 -store 34 -load 35 +frame_bury 9 +frame_dig 10 callsub numericalcomp_7 -store 35 -load 36 +frame_bury 10 +frame_dig 11 callsub numericalcomp_7 -store 36 -load 37 +frame_bury 11 +frame_dig 12 callsub numericalcomp_7 -store 37 -load 38 +frame_bury 12 +frame_dig 13 callsub numericalcomp_7 -store 38 -load 39 +frame_bury 13 +frame_dig 14 callsub numericalcomp_7 -store 39 -load 40 +frame_bury 14 +frame_dig 15 callsub numericalcomp_7 -store 40 -load 41 +frame_bury 15 +frame_dig 16 callsub numericalcomp_7 -store 41 -load 42 +frame_bury 16 +frame_dig 17 callsub numericalcomp_7 -store 42 -load 43 +frame_bury 17 +frame_dig 18 callsub numericalcomp_7 -store 43 -load 44 +frame_bury 18 +frame_dig 19 callsub numericalcomp_7 -store 44 -load 45 +frame_bury 19 +frame_dig 20 callsub numericalcomp_7 -store 45 -load 46 +frame_bury 20 +frame_dig 21 callsub numericalcomp_7 -store 46 -load 47 +frame_bury 21 +frame_dig 22 callsub numericalcomp_7 -store 47 -load 48 +frame_bury 22 +frame_dig 23 callsub numericalcomp_7 -store 48 -load 49 +frame_bury 23 +frame_dig 24 callsub numericalcomp_7 -store 49 -load 50 +frame_bury 24 +frame_dig 25 callsub numericalcomp_7 -store 50 -load 51 +frame_bury 25 +frame_dig 26 callsub numericalcomp_7 -store 51 -load 52 +frame_bury 26 +frame_dig 27 callsub numericalcomp_7 -store 52 -load 53 +frame_bury 27 +frame_dig 28 callsub numericalcomp_7 -store 53 -load 54 +frame_bury 28 +frame_dig 29 callsub numericalcomp_7 -store 54 -load 55 +frame_bury 29 +frame_dig 30 callsub numericalcomp_7 -store 55 -load 56 +frame_bury 30 +frame_dig 31 callsub numericalcomp_7 -store 56 -load 57 +frame_bury 31 +frame_dig 32 callsub numericalcomp_7 -store 57 +frame_bury 32 byte 0x00 int 0 -load 26 +frame_dig 1 setbyte byte 0x00 int 0 -load 27 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 28 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 29 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 30 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 31 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 32 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 33 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 34 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 35 +frame_dig 10 setbyte concat byte 0x00 int 0 -load 36 +frame_dig 11 setbyte concat byte 0x00 int 0 -load 37 +frame_dig 12 setbyte concat byte 0x00 int 0 -load 38 +frame_dig 13 setbyte concat byte 0x00 int 0 -load 39 +frame_dig 14 setbyte concat byte 0x00 int 0 -load 40 +frame_dig 15 setbyte concat byte 0x00 int 0 -load 41 +frame_dig 16 setbyte concat byte 0x00 int 0 -load 42 +frame_dig 17 setbyte concat byte 0x00 int 0 -load 43 +frame_dig 18 setbyte concat byte 0x00 int 0 -load 44 +frame_dig 19 setbyte concat byte 0x00 int 0 -load 45 +frame_dig 20 setbyte concat byte 0x00 int 0 -load 46 +frame_dig 21 setbyte concat byte 0x00 int 0 -load 47 +frame_dig 22 setbyte concat byte 0x00 int 0 -load 48 +frame_dig 23 setbyte concat byte 0x00 int 0 -load 49 +frame_dig 24 setbyte concat byte 0x00 int 0 -load 50 +frame_dig 25 setbyte concat byte 0x00 int 0 -load 51 +frame_dig 26 setbyte concat byte 0x00 int 0 -load 52 +frame_dig 27 setbyte concat byte 0x00 int 0 -load 53 +frame_dig 28 setbyte concat byte 0x00 int 0 -load 54 +frame_dig 29 setbyte concat byte 0x00 int 0 -load 55 +frame_dig 30 setbyte concat byte 0x00 int 0 -load 56 +frame_dig 31 setbyte concat byte 0x00 int 0 -load 57 +frame_dig 32 setbyte concat frame_bury 0 diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(uint16)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(uint16)_v8.teal index 3a683e4cf..e22555fe3 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(uint16)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(uint16)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 int 0 extract_uint16 @@ -32,16 +34,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 3 -load 3 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 4 +frame_bury 2 frame_dig -1 -load 3 +frame_dig 1 concat -load 4 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(uint16,uint8,byte)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(uint16,uint8,byte)_v8.teal index 47ddf0b4c..e8b2a9f45 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(uint16,uint8,byte)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(uint16,uint8,byte)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 7 frame_dig -1 int 0 extract_uint16 @@ -56,16 +58,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 5 -load 5 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 6 +frame_bury 2 frame_dig -1 -load 5 +frame_dig 1 concat -load 6 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(uint32)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(uint32)_v8.teal index a4b6b04a2..dd6a75d9f 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(uint32)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(uint32)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 int 0 extract_uint32 @@ -32,16 +34,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 3 -load 3 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 4 +frame_bury 2 frame_dig -1 -load 3 +frame_dig 1 concat -load 4 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(uint32,uint16,uint8)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(uint32,uint16,uint8)_v8.teal index 8a165cddc..002d38421 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(uint32,uint16,uint8)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(uint32,uint16,uint8)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 7 frame_dig -1 int 0 extract_uint32 @@ -55,16 +57,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 5 -load 5 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 6 +frame_bury 2 frame_dig -1 -load 5 +frame_dig 1 concat -load 6 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(uint64)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(uint64)_v8.teal index 5ba9c63c6..da53cd891 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(uint64)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(uint64)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 btoi store 0 @@ -30,16 +32,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 3 -load 3 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 4 +frame_bury 2 frame_dig -1 -load 3 +frame_dig 1 concat -load 4 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(uint64,uint32,uint16)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(uint64,uint32,uint16)_v8.teal index 33a5fb36c..ae607acd0 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(uint64,uint32,uint16)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(uint64,uint32,uint16)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 7 frame_dig -1 int 0 extract_uint64 @@ -53,16 +55,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 5 -load 5 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 6 +frame_bury 2 frame_dig -1 -load 5 +frame_dig 1 concat -load 6 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(uint8)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(uint8)_v8.teal index 4a8d567ff..a6f374016 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(uint8)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(uint8)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 int 0 getbyte @@ -33,16 +35,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 3 -load 3 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 4 +frame_bury 2 frame_dig -1 -load 3 +frame_dig 1 concat -load 4 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_(uint8,byte,bool)_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_(uint8,byte,bool)_v8.teal index 853a8b269..f14028d0a 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_(uint8,byte,bool)_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_(uint8,byte,bool)_v8.teal @@ -15,6 +15,8 @@ return tuplecomplement_0: proto 1 1 byte "" +int 0 +dupn 7 frame_dig -1 int 0 getbyte @@ -57,16 +59,19 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub tuplecomplement_0 -store 5 -load 5 +frame_bury 1 +frame_dig 1 callsub tuplecomplement_0 -store 6 +frame_bury 2 frame_dig -1 -load 5 +frame_dig 1 concat -load 6 +frame_dig 2 concat frame_bury 0 retsub diff --git a/tests/integration/teal/roundtrip/app_roundtrip_address[]_10_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_address[]_10_v8.teal index d58d71f84..de35e5e09 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_address[]_10_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_address[]_10_v8.teal @@ -29,451 +29,453 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 33 frame_dig -1 int 1 int 0 * getbyte -store 19 +frame_bury 1 frame_dig -1 int 1 int 1 * getbyte -store 20 +frame_bury 2 frame_dig -1 int 1 int 2 * getbyte -store 21 +frame_bury 3 frame_dig -1 int 1 int 3 * getbyte -store 22 +frame_bury 4 frame_dig -1 int 1 int 4 * getbyte -store 23 +frame_bury 5 frame_dig -1 int 1 int 5 * getbyte -store 24 +frame_bury 6 frame_dig -1 int 1 int 6 * getbyte -store 25 +frame_bury 7 frame_dig -1 int 1 int 7 * getbyte -store 26 +frame_bury 8 frame_dig -1 int 1 int 8 * getbyte -store 27 +frame_bury 9 frame_dig -1 int 1 int 9 * getbyte -store 28 +frame_bury 10 frame_dig -1 int 1 int 10 * getbyte -store 29 +frame_bury 11 frame_dig -1 int 1 int 11 * getbyte -store 30 +frame_bury 12 frame_dig -1 int 1 int 12 * getbyte -store 31 +frame_bury 13 frame_dig -1 int 1 int 13 * getbyte -store 32 +frame_bury 14 frame_dig -1 int 1 int 14 * getbyte -store 33 +frame_bury 15 frame_dig -1 int 1 int 15 * getbyte -store 34 +frame_bury 16 frame_dig -1 int 1 int 16 * getbyte -store 35 +frame_bury 17 frame_dig -1 int 1 int 17 * getbyte -store 36 +frame_bury 18 frame_dig -1 int 1 int 18 * getbyte -store 37 +frame_bury 19 frame_dig -1 int 1 int 19 * getbyte -store 38 +frame_bury 20 frame_dig -1 int 1 int 20 * getbyte -store 39 +frame_bury 21 frame_dig -1 int 1 int 21 * getbyte -store 40 +frame_bury 22 frame_dig -1 int 1 int 22 * getbyte -store 41 +frame_bury 23 frame_dig -1 int 1 int 23 * getbyte -store 42 +frame_bury 24 frame_dig -1 int 1 int 24 * getbyte -store 43 +frame_bury 25 frame_dig -1 int 1 int 25 * getbyte -store 44 +frame_bury 26 frame_dig -1 int 1 int 26 * getbyte -store 45 +frame_bury 27 frame_dig -1 int 1 int 27 * getbyte -store 46 +frame_bury 28 frame_dig -1 int 1 int 28 * getbyte -store 47 +frame_bury 29 frame_dig -1 int 1 int 29 * getbyte -store 48 +frame_bury 30 frame_dig -1 int 1 int 30 * getbyte -store 49 +frame_bury 31 frame_dig -1 int 1 int 31 * getbyte -store 50 -load 19 +frame_bury 32 +frame_dig 1 callsub numericalcomp_0 -store 19 -load 20 +frame_bury 1 +frame_dig 2 callsub numericalcomp_0 -store 20 -load 21 +frame_bury 2 +frame_dig 3 callsub numericalcomp_0 -store 21 -load 22 +frame_bury 3 +frame_dig 4 callsub numericalcomp_0 -store 22 -load 23 +frame_bury 4 +frame_dig 5 callsub numericalcomp_0 -store 23 -load 24 +frame_bury 5 +frame_dig 6 callsub numericalcomp_0 -store 24 -load 25 +frame_bury 6 +frame_dig 7 callsub numericalcomp_0 -store 25 -load 26 +frame_bury 7 +frame_dig 8 callsub numericalcomp_0 -store 26 -load 27 +frame_bury 8 +frame_dig 9 callsub numericalcomp_0 -store 27 -load 28 +frame_bury 9 +frame_dig 10 callsub numericalcomp_0 -store 28 -load 29 +frame_bury 10 +frame_dig 11 callsub numericalcomp_0 -store 29 -load 30 +frame_bury 11 +frame_dig 12 callsub numericalcomp_0 -store 30 -load 31 +frame_bury 12 +frame_dig 13 callsub numericalcomp_0 -store 31 -load 32 +frame_bury 13 +frame_dig 14 callsub numericalcomp_0 -store 32 -load 33 +frame_bury 14 +frame_dig 15 callsub numericalcomp_0 -store 33 -load 34 +frame_bury 15 +frame_dig 16 callsub numericalcomp_0 -store 34 -load 35 +frame_bury 16 +frame_dig 17 callsub numericalcomp_0 -store 35 -load 36 +frame_bury 17 +frame_dig 18 callsub numericalcomp_0 -store 36 -load 37 +frame_bury 18 +frame_dig 19 callsub numericalcomp_0 -store 37 -load 38 +frame_bury 19 +frame_dig 20 callsub numericalcomp_0 -store 38 -load 39 +frame_bury 20 +frame_dig 21 callsub numericalcomp_0 -store 39 -load 40 +frame_bury 21 +frame_dig 22 callsub numericalcomp_0 -store 40 -load 41 +frame_bury 22 +frame_dig 23 callsub numericalcomp_0 -store 41 -load 42 +frame_bury 23 +frame_dig 24 callsub numericalcomp_0 -store 42 -load 43 +frame_bury 24 +frame_dig 25 callsub numericalcomp_0 -store 43 -load 44 +frame_bury 25 +frame_dig 26 callsub numericalcomp_0 -store 44 -load 45 +frame_bury 26 +frame_dig 27 callsub numericalcomp_0 -store 45 -load 46 +frame_bury 27 +frame_dig 28 callsub numericalcomp_0 -store 46 -load 47 +frame_bury 28 +frame_dig 29 callsub numericalcomp_0 -store 47 -load 48 +frame_bury 29 +frame_dig 30 callsub numericalcomp_0 -store 48 -load 49 +frame_bury 30 +frame_dig 31 callsub numericalcomp_0 -store 49 -load 50 +frame_bury 31 +frame_dig 32 callsub numericalcomp_0 -store 50 +frame_bury 32 byte 0x00 int 0 -load 19 +frame_dig 1 setbyte byte 0x00 int 0 -load 20 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 21 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 22 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 23 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 24 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 25 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 26 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 27 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 28 +frame_dig 10 setbyte concat byte 0x00 int 0 -load 29 +frame_dig 11 setbyte concat byte 0x00 int 0 -load 30 +frame_dig 12 setbyte concat byte 0x00 int 0 -load 31 +frame_dig 13 setbyte concat byte 0x00 int 0 -load 32 +frame_dig 14 setbyte concat byte 0x00 int 0 -load 33 +frame_dig 15 setbyte concat byte 0x00 int 0 -load 34 +frame_dig 16 setbyte concat byte 0x00 int 0 -load 35 +frame_dig 17 setbyte concat byte 0x00 int 0 -load 36 +frame_dig 18 setbyte concat byte 0x00 int 0 -load 37 +frame_dig 19 setbyte concat byte 0x00 int 0 -load 38 +frame_dig 20 setbyte concat byte 0x00 int 0 -load 39 +frame_dig 21 setbyte concat byte 0x00 int 0 -load 40 +frame_dig 22 setbyte concat byte 0x00 int 0 -load 41 +frame_dig 23 setbyte concat byte 0x00 int 0 -load 42 +frame_dig 24 setbyte concat byte 0x00 int 0 -load 43 +frame_dig 25 setbyte concat byte 0x00 int 0 -load 44 +frame_dig 26 setbyte concat byte 0x00 int 0 -load 45 +frame_dig 27 setbyte concat byte 0x00 int 0 -load 46 +frame_dig 28 setbyte concat byte 0x00 int 0 -load 47 +frame_dig 29 setbyte concat byte 0x00 int 0 -load 48 +frame_dig 30 setbyte concat byte 0x00 int 0 -load 49 +frame_dig 31 setbyte concat byte 0x00 int 0 -load 50 +frame_dig 32 setbyte concat frame_bury 0 @@ -483,6 +485,9 @@ retsub arraycomplement_2: proto 1 1 byte "" +dupn 10 +int 0 +dupn 12 frame_dig -1 int 32 int 0 @@ -491,7 +496,7 @@ int 2 + int 32 extract3 -store 8 +frame_bury 1 frame_dig -1 int 32 int 1 @@ -500,7 +505,7 @@ int 2 + int 32 extract3 -store 9 +frame_bury 2 frame_dig -1 int 32 int 2 @@ -509,7 +514,7 @@ int 2 + int 32 extract3 -store 10 +frame_bury 3 frame_dig -1 int 32 int 3 @@ -518,7 +523,7 @@ int 2 + int 32 extract3 -store 11 +frame_bury 4 frame_dig -1 int 32 int 4 @@ -527,7 +532,7 @@ int 2 + int 32 extract3 -store 12 +frame_bury 5 frame_dig -1 int 32 int 5 @@ -536,7 +541,7 @@ int 2 + int 32 extract3 -store 13 +frame_bury 6 frame_dig -1 int 32 int 6 @@ -545,7 +550,7 @@ int 2 + int 32 extract3 -store 14 +frame_bury 7 frame_dig -1 int 32 int 7 @@ -554,7 +559,7 @@ int 2 + int 32 extract3 -store 15 +frame_bury 8 frame_dig -1 int 32 int 8 @@ -563,7 +568,7 @@ int 2 + int 32 extract3 -store 16 +frame_bury 9 frame_dig -1 int 32 int 9 @@ -572,60 +577,60 @@ int 2 + int 32 extract3 -store 17 -load 8 +frame_bury 10 +frame_dig 1 callsub arraycomplement_1 -store 8 -load 9 +frame_bury 1 +frame_dig 2 callsub arraycomplement_1 -store 9 -load 10 +frame_bury 2 +frame_dig 3 callsub arraycomplement_1 -store 10 -load 11 +frame_bury 3 +frame_dig 4 callsub arraycomplement_1 -store 11 -load 12 +frame_bury 4 +frame_dig 5 callsub arraycomplement_1 -store 12 -load 13 +frame_bury 5 +frame_dig 6 callsub arraycomplement_1 -store 13 -load 14 +frame_bury 6 +frame_dig 7 callsub arraycomplement_1 -store 14 -load 15 +frame_bury 7 +frame_dig 8 callsub arraycomplement_1 -store 15 -load 16 +frame_bury 8 +frame_dig 9 callsub arraycomplement_1 -store 16 -load 17 +frame_bury 9 +frame_dig 10 callsub arraycomplement_1 -store 17 +frame_bury 10 int 10 -store 18 -load 18 +frame_bury 23 +frame_dig 23 itob extract 6 0 -load 8 -load 9 +frame_dig 1 +frame_dig 2 concat -load 10 +frame_dig 3 concat -load 11 +frame_dig 4 concat -load 12 +frame_dig 5 concat -load 13 +frame_dig 6 concat -load 14 +frame_dig 7 concat -load 15 +frame_dig 8 concat -load 16 +frame_dig 9 concat -load 17 +frame_dig 10 concat concat frame_bury 0 @@ -635,64 +640,67 @@ retsub roundtripper_3: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_2 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_2 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 -concat -store 6 -load 5 -store 4 -load 4 -load 7 +load 3 +concat +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 -concat -store 6 -load 5 -store 4 -load 4 +concat +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_address_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_address_v8.teal index 0ebe72b72..272928083 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_address_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_address_v8.teal @@ -29,451 +29,453 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 33 frame_dig -1 int 1 int 0 * getbyte -store 4 +frame_bury 1 frame_dig -1 int 1 int 1 * getbyte -store 5 +frame_bury 2 frame_dig -1 int 1 int 2 * getbyte -store 6 +frame_bury 3 frame_dig -1 int 1 int 3 * getbyte -store 7 +frame_bury 4 frame_dig -1 int 1 int 4 * getbyte -store 8 +frame_bury 5 frame_dig -1 int 1 int 5 * getbyte -store 9 +frame_bury 6 frame_dig -1 int 1 int 6 * getbyte -store 10 +frame_bury 7 frame_dig -1 int 1 int 7 * getbyte -store 11 +frame_bury 8 frame_dig -1 int 1 int 8 * getbyte -store 12 +frame_bury 9 frame_dig -1 int 1 int 9 * getbyte -store 13 +frame_bury 10 frame_dig -1 int 1 int 10 * getbyte -store 14 +frame_bury 11 frame_dig -1 int 1 int 11 * getbyte -store 15 +frame_bury 12 frame_dig -1 int 1 int 12 * getbyte -store 16 +frame_bury 13 frame_dig -1 int 1 int 13 * getbyte -store 17 +frame_bury 14 frame_dig -1 int 1 int 14 * getbyte -store 18 +frame_bury 15 frame_dig -1 int 1 int 15 * getbyte -store 19 +frame_bury 16 frame_dig -1 int 1 int 16 * getbyte -store 20 +frame_bury 17 frame_dig -1 int 1 int 17 * getbyte -store 21 +frame_bury 18 frame_dig -1 int 1 int 18 * getbyte -store 22 +frame_bury 19 frame_dig -1 int 1 int 19 * getbyte -store 23 +frame_bury 20 frame_dig -1 int 1 int 20 * getbyte -store 24 +frame_bury 21 frame_dig -1 int 1 int 21 * getbyte -store 25 +frame_bury 22 frame_dig -1 int 1 int 22 * getbyte -store 26 +frame_bury 23 frame_dig -1 int 1 int 23 * getbyte -store 27 +frame_bury 24 frame_dig -1 int 1 int 24 * getbyte -store 28 +frame_bury 25 frame_dig -1 int 1 int 25 * getbyte -store 29 +frame_bury 26 frame_dig -1 int 1 int 26 * getbyte -store 30 +frame_bury 27 frame_dig -1 int 1 int 27 * getbyte -store 31 +frame_bury 28 frame_dig -1 int 1 int 28 * getbyte -store 32 +frame_bury 29 frame_dig -1 int 1 int 29 * getbyte -store 33 +frame_bury 30 frame_dig -1 int 1 int 30 * getbyte -store 34 +frame_bury 31 frame_dig -1 int 1 int 31 * getbyte -store 35 -load 4 +frame_bury 32 +frame_dig 1 callsub numericalcomp_0 -store 4 -load 5 +frame_bury 1 +frame_dig 2 callsub numericalcomp_0 -store 5 -load 6 +frame_bury 2 +frame_dig 3 callsub numericalcomp_0 -store 6 -load 7 +frame_bury 3 +frame_dig 4 callsub numericalcomp_0 -store 7 -load 8 +frame_bury 4 +frame_dig 5 callsub numericalcomp_0 -store 8 -load 9 +frame_bury 5 +frame_dig 6 callsub numericalcomp_0 -store 9 -load 10 +frame_bury 6 +frame_dig 7 callsub numericalcomp_0 -store 10 -load 11 +frame_bury 7 +frame_dig 8 callsub numericalcomp_0 -store 11 -load 12 +frame_bury 8 +frame_dig 9 callsub numericalcomp_0 -store 12 -load 13 +frame_bury 9 +frame_dig 10 callsub numericalcomp_0 -store 13 -load 14 +frame_bury 10 +frame_dig 11 callsub numericalcomp_0 -store 14 -load 15 +frame_bury 11 +frame_dig 12 callsub numericalcomp_0 -store 15 -load 16 +frame_bury 12 +frame_dig 13 callsub numericalcomp_0 -store 16 -load 17 +frame_bury 13 +frame_dig 14 callsub numericalcomp_0 -store 17 -load 18 +frame_bury 14 +frame_dig 15 callsub numericalcomp_0 -store 18 -load 19 +frame_bury 15 +frame_dig 16 callsub numericalcomp_0 -store 19 -load 20 +frame_bury 16 +frame_dig 17 callsub numericalcomp_0 -store 20 -load 21 +frame_bury 17 +frame_dig 18 callsub numericalcomp_0 -store 21 -load 22 +frame_bury 18 +frame_dig 19 callsub numericalcomp_0 -store 22 -load 23 +frame_bury 19 +frame_dig 20 callsub numericalcomp_0 -store 23 -load 24 +frame_bury 20 +frame_dig 21 callsub numericalcomp_0 -store 24 -load 25 +frame_bury 21 +frame_dig 22 callsub numericalcomp_0 -store 25 -load 26 +frame_bury 22 +frame_dig 23 callsub numericalcomp_0 -store 26 -load 27 +frame_bury 23 +frame_dig 24 callsub numericalcomp_0 -store 27 -load 28 +frame_bury 24 +frame_dig 25 callsub numericalcomp_0 -store 28 -load 29 +frame_bury 25 +frame_dig 26 callsub numericalcomp_0 -store 29 -load 30 +frame_bury 26 +frame_dig 27 callsub numericalcomp_0 -store 30 -load 31 +frame_bury 27 +frame_dig 28 callsub numericalcomp_0 -store 31 -load 32 +frame_bury 28 +frame_dig 29 callsub numericalcomp_0 -store 32 -load 33 +frame_bury 29 +frame_dig 30 callsub numericalcomp_0 -store 33 -load 34 +frame_bury 30 +frame_dig 31 callsub numericalcomp_0 -store 34 -load 35 +frame_bury 31 +frame_dig 32 callsub numericalcomp_0 -store 35 +frame_bury 32 byte 0x00 int 0 -load 4 +frame_dig 1 setbyte byte 0x00 int 0 -load 5 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 6 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 7 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 8 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 9 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 10 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 11 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 12 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 13 +frame_dig 10 setbyte concat byte 0x00 int 0 -load 14 +frame_dig 11 setbyte concat byte 0x00 int 0 -load 15 +frame_dig 12 setbyte concat byte 0x00 int 0 -load 16 +frame_dig 13 setbyte concat byte 0x00 int 0 -load 17 +frame_dig 14 setbyte concat byte 0x00 int 0 -load 18 +frame_dig 15 setbyte concat byte 0x00 int 0 -load 19 +frame_dig 16 setbyte concat byte 0x00 int 0 -load 20 +frame_dig 17 setbyte concat byte 0x00 int 0 -load 21 +frame_dig 18 setbyte concat byte 0x00 int 0 -load 22 +frame_dig 19 setbyte concat byte 0x00 int 0 -load 23 +frame_dig 20 setbyte concat byte 0x00 int 0 -load 24 +frame_dig 21 setbyte concat byte 0x00 int 0 -load 25 +frame_dig 22 setbyte concat byte 0x00 int 0 -load 26 +frame_dig 23 setbyte concat byte 0x00 int 0 -load 27 +frame_dig 24 setbyte concat byte 0x00 int 0 -load 28 +frame_dig 25 setbyte concat byte 0x00 int 0 -load 29 +frame_dig 26 setbyte concat byte 0x00 int 0 -load 30 +frame_dig 27 setbyte concat byte 0x00 int 0 -load 31 +frame_dig 28 setbyte concat byte 0x00 int 0 -load 32 +frame_dig 29 setbyte concat byte 0x00 int 0 -load 33 +frame_dig 30 setbyte concat byte 0x00 int 0 -load 34 +frame_dig 31 setbyte concat byte 0x00 int 0 -load 35 +frame_dig 32 setbyte concat frame_bury 0 @@ -483,16 +485,19 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 3 +frame_bury 2 frame_dig -1 -load 2 +frame_dig 1 concat -load 3 +frame_dig 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_bool[1]_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_bool[1]_v8.teal index 3458bde41..c8dd10f81 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_bool[1]_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_bool[1]_v8.teal @@ -26,16 +26,18 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 2 frame_dig -1 int 0 getbit -store 4 -load 4 +frame_bury 1 +frame_dig 1 callsub boolcomp_0 -store 4 +frame_bury 1 byte 0x00 int 0 -load 4 +frame_dig 1 setbit frame_bury 0 retsub @@ -44,16 +46,19 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 3 +frame_bury 2 frame_dig -1 -load 2 +frame_dig 1 concat -load 3 +frame_dig 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_bool[3][]_11_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_bool[3][]_11_v8.teal index 64bd1f049..cfc8dd12f 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_bool[3][]_11_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_bool[3][]_11_v8.teal @@ -26,36 +26,38 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 4 frame_dig -1 int 0 getbit -store 20 +frame_bury 1 frame_dig -1 int 1 getbit -store 21 +frame_bury 2 frame_dig -1 int 2 getbit -store 22 -load 20 +frame_bury 3 +frame_dig 1 callsub boolcomp_0 -store 20 -load 21 +frame_bury 1 +frame_dig 2 callsub boolcomp_0 -store 21 -load 22 +frame_bury 2 +frame_dig 3 callsub boolcomp_0 -store 22 +frame_bury 3 byte 0x00 int 0 -load 20 +frame_dig 1 setbit int 1 -load 21 +frame_dig 2 setbit int 2 -load 22 +frame_dig 3 setbit frame_bury 0 retsub @@ -64,6 +66,9 @@ retsub arraycomplement_2: proto 1 1 byte "" +dupn 11 +int 0 +dupn 13 frame_dig -1 int 1 int 0 @@ -72,7 +77,7 @@ int 2 + int 1 extract3 -store 8 +frame_bury 1 frame_dig -1 int 1 int 1 @@ -81,7 +86,7 @@ int 2 + int 1 extract3 -store 9 +frame_bury 2 frame_dig -1 int 1 int 2 @@ -90,7 +95,7 @@ int 2 + int 1 extract3 -store 10 +frame_bury 3 frame_dig -1 int 1 int 3 @@ -99,7 +104,7 @@ int 2 + int 1 extract3 -store 11 +frame_bury 4 frame_dig -1 int 1 int 4 @@ -108,7 +113,7 @@ int 2 + int 1 extract3 -store 12 +frame_bury 5 frame_dig -1 int 1 int 5 @@ -117,7 +122,7 @@ int 2 + int 1 extract3 -store 13 +frame_bury 6 frame_dig -1 int 1 int 6 @@ -126,7 +131,7 @@ int 2 + int 1 extract3 -store 14 +frame_bury 7 frame_dig -1 int 1 int 7 @@ -135,7 +140,7 @@ int 2 + int 1 extract3 -store 15 +frame_bury 8 frame_dig -1 int 1 int 8 @@ -144,7 +149,7 @@ int 2 + int 1 extract3 -store 16 +frame_bury 9 frame_dig -1 int 1 int 9 @@ -153,7 +158,7 @@ int 2 + int 1 extract3 -store 17 +frame_bury 10 frame_dig -1 int 1 int 10 @@ -162,65 +167,65 @@ int 2 + int 1 extract3 -store 18 -load 8 +frame_bury 11 +frame_dig 1 callsub arraycomplement_1 -store 8 -load 9 +frame_bury 1 +frame_dig 2 callsub arraycomplement_1 -store 9 -load 10 +frame_bury 2 +frame_dig 3 callsub arraycomplement_1 -store 10 -load 11 +frame_bury 3 +frame_dig 4 callsub arraycomplement_1 -store 11 -load 12 +frame_bury 4 +frame_dig 5 callsub arraycomplement_1 -store 12 -load 13 +frame_bury 5 +frame_dig 6 callsub arraycomplement_1 -store 13 -load 14 +frame_bury 6 +frame_dig 7 callsub arraycomplement_1 -store 14 -load 15 +frame_bury 7 +frame_dig 8 callsub arraycomplement_1 -store 15 -load 16 +frame_bury 8 +frame_dig 9 callsub arraycomplement_1 -store 16 -load 17 +frame_bury 9 +frame_dig 10 callsub arraycomplement_1 -store 17 -load 18 +frame_bury 10 +frame_dig 11 callsub arraycomplement_1 -store 18 +frame_bury 11 int 11 -store 19 -load 19 +frame_bury 25 +frame_dig 25 itob extract 6 0 -load 8 -load 9 +frame_dig 1 +frame_dig 2 concat -load 10 +frame_dig 3 concat -load 11 +frame_dig 4 concat -load 12 +frame_dig 5 concat -load 13 +frame_dig 6 concat -load 14 +frame_dig 7 concat -load 15 +frame_dig 8 concat -load 16 +frame_dig 9 concat -load 17 +frame_dig 10 concat -load 18 +frame_dig 11 concat concat frame_bury 0 @@ -230,64 +235,67 @@ retsub roundtripper_3: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_2 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_2 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 +load 3 concat -store 6 -load 5 -store 4 -load 4 -load 7 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 concat -store 6 -load 5 -store 4 -load 4 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_bool[42]_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_bool[42]_v8.teal index a215df488..b23cad207 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_bool[42]_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_bool[42]_v8.teal @@ -26,426 +26,428 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 43 frame_dig -1 int 0 getbit -store 4 +frame_bury 1 frame_dig -1 int 1 getbit -store 5 +frame_bury 2 frame_dig -1 int 2 getbit -store 6 +frame_bury 3 frame_dig -1 int 3 getbit -store 7 +frame_bury 4 frame_dig -1 int 4 getbit -store 8 +frame_bury 5 frame_dig -1 int 5 getbit -store 9 +frame_bury 6 frame_dig -1 int 6 getbit -store 10 +frame_bury 7 frame_dig -1 int 7 getbit -store 11 +frame_bury 8 frame_dig -1 int 8 getbit -store 12 +frame_bury 9 frame_dig -1 int 9 getbit -store 13 +frame_bury 10 frame_dig -1 int 10 getbit -store 14 +frame_bury 11 frame_dig -1 int 11 getbit -store 15 +frame_bury 12 frame_dig -1 int 12 getbit -store 16 +frame_bury 13 frame_dig -1 int 13 getbit -store 17 +frame_bury 14 frame_dig -1 int 14 getbit -store 18 +frame_bury 15 frame_dig -1 int 15 getbit -store 19 +frame_bury 16 frame_dig -1 int 16 getbit -store 20 +frame_bury 17 frame_dig -1 int 17 getbit -store 21 +frame_bury 18 frame_dig -1 int 18 getbit -store 22 +frame_bury 19 frame_dig -1 int 19 getbit -store 23 +frame_bury 20 frame_dig -1 int 20 getbit -store 24 +frame_bury 21 frame_dig -1 int 21 getbit -store 25 +frame_bury 22 frame_dig -1 int 22 getbit -store 26 +frame_bury 23 frame_dig -1 int 23 getbit -store 27 +frame_bury 24 frame_dig -1 int 24 getbit -store 28 +frame_bury 25 frame_dig -1 int 25 getbit -store 29 +frame_bury 26 frame_dig -1 int 26 getbit -store 30 +frame_bury 27 frame_dig -1 int 27 getbit -store 31 +frame_bury 28 frame_dig -1 int 28 getbit -store 32 +frame_bury 29 frame_dig -1 int 29 getbit -store 33 +frame_bury 30 frame_dig -1 int 30 getbit -store 34 +frame_bury 31 frame_dig -1 int 31 getbit -store 35 +frame_bury 32 frame_dig -1 int 32 getbit -store 36 +frame_bury 33 frame_dig -1 int 33 getbit -store 37 +frame_bury 34 frame_dig -1 int 34 getbit -store 38 +frame_bury 35 frame_dig -1 int 35 getbit -store 39 +frame_bury 36 frame_dig -1 int 36 getbit -store 40 +frame_bury 37 frame_dig -1 int 37 getbit -store 41 +frame_bury 38 frame_dig -1 int 38 getbit -store 42 +frame_bury 39 frame_dig -1 int 39 getbit -store 43 +frame_bury 40 frame_dig -1 int 40 getbit -store 44 +frame_bury 41 frame_dig -1 int 41 getbit -store 45 -load 4 +frame_bury 42 +frame_dig 1 callsub boolcomp_0 -store 4 -load 5 +frame_bury 1 +frame_dig 2 callsub boolcomp_0 -store 5 -load 6 +frame_bury 2 +frame_dig 3 callsub boolcomp_0 -store 6 -load 7 +frame_bury 3 +frame_dig 4 callsub boolcomp_0 -store 7 -load 8 +frame_bury 4 +frame_dig 5 callsub boolcomp_0 -store 8 -load 9 +frame_bury 5 +frame_dig 6 callsub boolcomp_0 -store 9 -load 10 +frame_bury 6 +frame_dig 7 callsub boolcomp_0 -store 10 -load 11 +frame_bury 7 +frame_dig 8 callsub boolcomp_0 -store 11 -load 12 +frame_bury 8 +frame_dig 9 callsub boolcomp_0 -store 12 -load 13 +frame_bury 9 +frame_dig 10 callsub boolcomp_0 -store 13 -load 14 +frame_bury 10 +frame_dig 11 callsub boolcomp_0 -store 14 -load 15 +frame_bury 11 +frame_dig 12 callsub boolcomp_0 -store 15 -load 16 +frame_bury 12 +frame_dig 13 callsub boolcomp_0 -store 16 -load 17 +frame_bury 13 +frame_dig 14 callsub boolcomp_0 -store 17 -load 18 +frame_bury 14 +frame_dig 15 callsub boolcomp_0 -store 18 -load 19 +frame_bury 15 +frame_dig 16 callsub boolcomp_0 -store 19 -load 20 +frame_bury 16 +frame_dig 17 callsub boolcomp_0 -store 20 -load 21 +frame_bury 17 +frame_dig 18 callsub boolcomp_0 -store 21 -load 22 +frame_bury 18 +frame_dig 19 callsub boolcomp_0 -store 22 -load 23 +frame_bury 19 +frame_dig 20 callsub boolcomp_0 -store 23 -load 24 +frame_bury 20 +frame_dig 21 callsub boolcomp_0 -store 24 -load 25 +frame_bury 21 +frame_dig 22 callsub boolcomp_0 -store 25 -load 26 +frame_bury 22 +frame_dig 23 callsub boolcomp_0 -store 26 -load 27 +frame_bury 23 +frame_dig 24 callsub boolcomp_0 -store 27 -load 28 +frame_bury 24 +frame_dig 25 callsub boolcomp_0 -store 28 -load 29 +frame_bury 25 +frame_dig 26 callsub boolcomp_0 -store 29 -load 30 +frame_bury 26 +frame_dig 27 callsub boolcomp_0 -store 30 -load 31 +frame_bury 27 +frame_dig 28 callsub boolcomp_0 -store 31 -load 32 +frame_bury 28 +frame_dig 29 callsub boolcomp_0 -store 32 -load 33 +frame_bury 29 +frame_dig 30 callsub boolcomp_0 -store 33 -load 34 +frame_bury 30 +frame_dig 31 callsub boolcomp_0 -store 34 -load 35 +frame_bury 31 +frame_dig 32 callsub boolcomp_0 -store 35 -load 36 +frame_bury 32 +frame_dig 33 callsub boolcomp_0 -store 36 -load 37 +frame_bury 33 +frame_dig 34 callsub boolcomp_0 -store 37 -load 38 +frame_bury 34 +frame_dig 35 callsub boolcomp_0 -store 38 -load 39 +frame_bury 35 +frame_dig 36 callsub boolcomp_0 -store 39 -load 40 +frame_bury 36 +frame_dig 37 callsub boolcomp_0 -store 40 -load 41 +frame_bury 37 +frame_dig 38 callsub boolcomp_0 -store 41 -load 42 +frame_bury 38 +frame_dig 39 callsub boolcomp_0 -store 42 -load 43 +frame_bury 39 +frame_dig 40 callsub boolcomp_0 -store 43 -load 44 +frame_bury 40 +frame_dig 41 callsub boolcomp_0 -store 44 -load 45 +frame_bury 41 +frame_dig 42 callsub boolcomp_0 -store 45 +frame_bury 42 byte 0x000000000000 int 0 -load 4 +frame_dig 1 setbit int 1 -load 5 +frame_dig 2 setbit int 2 -load 6 +frame_dig 3 setbit int 3 -load 7 +frame_dig 4 setbit int 4 -load 8 +frame_dig 5 setbit int 5 -load 9 +frame_dig 6 setbit int 6 -load 10 +frame_dig 7 setbit int 7 -load 11 +frame_dig 8 setbit int 8 -load 12 +frame_dig 9 setbit int 9 -load 13 +frame_dig 10 setbit int 10 -load 14 +frame_dig 11 setbit int 11 -load 15 +frame_dig 12 setbit int 12 -load 16 +frame_dig 13 setbit int 13 -load 17 +frame_dig 14 setbit int 14 -load 18 +frame_dig 15 setbit int 15 -load 19 +frame_dig 16 setbit int 16 -load 20 +frame_dig 17 setbit int 17 -load 21 +frame_dig 18 setbit int 18 -load 22 +frame_dig 19 setbit int 19 -load 23 +frame_dig 20 setbit int 20 -load 24 +frame_dig 21 setbit int 21 -load 25 +frame_dig 22 setbit int 22 -load 26 +frame_dig 23 setbit int 23 -load 27 +frame_dig 24 setbit int 24 -load 28 +frame_dig 25 setbit int 25 -load 29 +frame_dig 26 setbit int 26 -load 30 +frame_dig 27 setbit int 27 -load 31 +frame_dig 28 setbit int 28 -load 32 +frame_dig 29 setbit int 29 -load 33 +frame_dig 30 setbit int 30 -load 34 +frame_dig 31 setbit int 31 -load 35 +frame_dig 32 setbit int 32 -load 36 +frame_dig 33 setbit int 33 -load 37 +frame_dig 34 setbit int 34 -load 38 +frame_dig 35 setbit int 35 -load 39 +frame_dig 36 setbit int 36 -load 40 +frame_dig 37 setbit int 37 -load 41 +frame_dig 38 setbit int 38 -load 42 +frame_dig 39 setbit int 39 -load 43 +frame_dig 40 setbit int 40 -load 44 +frame_dig 41 setbit int 41 -load 45 +frame_dig 42 setbit frame_bury 0 retsub @@ -454,16 +456,19 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 3 +frame_bury 2 frame_dig -1 -load 2 +frame_dig 1 concat -load 3 +frame_dig 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_bool[]_0_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_bool[]_0_v8.teal index 87f935c92..173e4c5c5 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_bool[]_0_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_bool[]_0_v8.teal @@ -16,8 +16,10 @@ arraycomplement_0: proto 1 1 byte "" int 0 -store 8 -load 8 +dupn 2 +int 0 +frame_bury 3 +frame_dig 3 itob extract 6 0 byte "" @@ -29,64 +31,67 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_0 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 +load 3 concat -store 6 -load 5 -store 4 -load 4 -load 7 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 concat -store 6 -load 5 -store 4 -load 4 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_bool[]_1_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_bool[]_1_v8.teal index 9b403483f..11c2891c5 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_bool[]_1_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_bool[]_1_v8.teal @@ -26,23 +26,25 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 int 0 int 16 + getbit -store 8 -load 8 +frame_bury 1 +frame_dig 1 callsub boolcomp_0 -store 8 +frame_bury 1 int 1 -store 9 -load 9 +frame_bury 4 +frame_dig 4 itob extract 6 0 byte 0x00 int 0 -load 8 +frame_dig 1 setbit concat frame_bury 0 @@ -52,64 +54,67 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 +load 3 concat -store 6 -load 5 -store 4 -load 4 -load 7 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 concat -store 6 -load 5 -store 4 -load 4 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_bool[]_42_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_bool[]_42_v8.teal index a2a6821c4..2e8a85c04 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_bool[]_42_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_bool[]_42_v8.teal @@ -26,515 +26,517 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 44 frame_dig -1 int 0 int 16 + getbit -store 8 +frame_bury 1 frame_dig -1 int 1 int 16 + getbit -store 9 +frame_bury 2 frame_dig -1 int 2 int 16 + getbit -store 10 +frame_bury 3 frame_dig -1 int 3 int 16 + getbit -store 11 +frame_bury 4 frame_dig -1 int 4 int 16 + getbit -store 12 +frame_bury 5 frame_dig -1 int 5 int 16 + getbit -store 13 +frame_bury 6 frame_dig -1 int 6 int 16 + getbit -store 14 +frame_bury 7 frame_dig -1 int 7 int 16 + getbit -store 15 +frame_bury 8 frame_dig -1 int 8 int 16 + getbit -store 16 +frame_bury 9 frame_dig -1 int 9 int 16 + getbit -store 17 +frame_bury 10 frame_dig -1 int 10 int 16 + getbit -store 18 +frame_bury 11 frame_dig -1 int 11 int 16 + getbit -store 19 +frame_bury 12 frame_dig -1 int 12 int 16 + getbit -store 20 +frame_bury 13 frame_dig -1 int 13 int 16 + getbit -store 21 +frame_bury 14 frame_dig -1 int 14 int 16 + getbit -store 22 +frame_bury 15 frame_dig -1 int 15 int 16 + getbit -store 23 +frame_bury 16 frame_dig -1 int 16 int 16 + getbit -store 24 +frame_bury 17 frame_dig -1 int 17 int 16 + getbit -store 25 +frame_bury 18 frame_dig -1 int 18 int 16 + getbit -store 26 +frame_bury 19 frame_dig -1 int 19 int 16 + getbit -store 27 +frame_bury 20 frame_dig -1 int 20 int 16 + getbit -store 28 +frame_bury 21 frame_dig -1 int 21 int 16 + getbit -store 29 +frame_bury 22 frame_dig -1 int 22 int 16 + getbit -store 30 +frame_bury 23 frame_dig -1 int 23 int 16 + getbit -store 31 +frame_bury 24 frame_dig -1 int 24 int 16 + getbit -store 32 +frame_bury 25 frame_dig -1 int 25 int 16 + getbit -store 33 +frame_bury 26 frame_dig -1 int 26 int 16 + getbit -store 34 +frame_bury 27 frame_dig -1 int 27 int 16 + getbit -store 35 +frame_bury 28 frame_dig -1 int 28 int 16 + getbit -store 36 +frame_bury 29 frame_dig -1 int 29 int 16 + getbit -store 37 +frame_bury 30 frame_dig -1 int 30 int 16 + getbit -store 38 +frame_bury 31 frame_dig -1 int 31 int 16 + getbit -store 39 +frame_bury 32 frame_dig -1 int 32 int 16 + getbit -store 40 +frame_bury 33 frame_dig -1 int 33 int 16 + getbit -store 41 +frame_bury 34 frame_dig -1 int 34 int 16 + getbit -store 42 +frame_bury 35 frame_dig -1 int 35 int 16 + getbit -store 43 +frame_bury 36 frame_dig -1 int 36 int 16 + getbit -store 44 +frame_bury 37 frame_dig -1 int 37 int 16 + getbit -store 45 +frame_bury 38 frame_dig -1 int 38 int 16 + getbit -store 46 +frame_bury 39 frame_dig -1 int 39 int 16 + getbit -store 47 +frame_bury 40 frame_dig -1 int 40 int 16 + getbit -store 48 +frame_bury 41 frame_dig -1 int 41 int 16 + getbit -store 49 -load 8 +frame_bury 42 +frame_dig 1 callsub boolcomp_0 -store 8 -load 9 +frame_bury 1 +frame_dig 2 callsub boolcomp_0 -store 9 -load 10 +frame_bury 2 +frame_dig 3 callsub boolcomp_0 -store 10 -load 11 +frame_bury 3 +frame_dig 4 callsub boolcomp_0 -store 11 -load 12 +frame_bury 4 +frame_dig 5 callsub boolcomp_0 -store 12 -load 13 +frame_bury 5 +frame_dig 6 callsub boolcomp_0 -store 13 -load 14 +frame_bury 6 +frame_dig 7 callsub boolcomp_0 -store 14 -load 15 +frame_bury 7 +frame_dig 8 callsub boolcomp_0 -store 15 -load 16 +frame_bury 8 +frame_dig 9 callsub boolcomp_0 -store 16 -load 17 +frame_bury 9 +frame_dig 10 callsub boolcomp_0 -store 17 -load 18 +frame_bury 10 +frame_dig 11 callsub boolcomp_0 -store 18 -load 19 +frame_bury 11 +frame_dig 12 callsub boolcomp_0 -store 19 -load 20 +frame_bury 12 +frame_dig 13 callsub boolcomp_0 -store 20 -load 21 +frame_bury 13 +frame_dig 14 callsub boolcomp_0 -store 21 -load 22 +frame_bury 14 +frame_dig 15 callsub boolcomp_0 -store 22 -load 23 +frame_bury 15 +frame_dig 16 callsub boolcomp_0 -store 23 -load 24 +frame_bury 16 +frame_dig 17 callsub boolcomp_0 -store 24 -load 25 +frame_bury 17 +frame_dig 18 callsub boolcomp_0 -store 25 -load 26 +frame_bury 18 +frame_dig 19 callsub boolcomp_0 -store 26 -load 27 +frame_bury 19 +frame_dig 20 callsub boolcomp_0 -store 27 -load 28 +frame_bury 20 +frame_dig 21 callsub boolcomp_0 -store 28 -load 29 +frame_bury 21 +frame_dig 22 callsub boolcomp_0 -store 29 -load 30 +frame_bury 22 +frame_dig 23 callsub boolcomp_0 -store 30 -load 31 +frame_bury 23 +frame_dig 24 callsub boolcomp_0 -store 31 -load 32 +frame_bury 24 +frame_dig 25 callsub boolcomp_0 -store 32 -load 33 +frame_bury 25 +frame_dig 26 callsub boolcomp_0 -store 33 -load 34 +frame_bury 26 +frame_dig 27 callsub boolcomp_0 -store 34 -load 35 +frame_bury 27 +frame_dig 28 callsub boolcomp_0 -store 35 -load 36 +frame_bury 28 +frame_dig 29 callsub boolcomp_0 -store 36 -load 37 +frame_bury 29 +frame_dig 30 callsub boolcomp_0 -store 37 -load 38 +frame_bury 30 +frame_dig 31 callsub boolcomp_0 -store 38 -load 39 +frame_bury 31 +frame_dig 32 callsub boolcomp_0 -store 39 -load 40 +frame_bury 32 +frame_dig 33 callsub boolcomp_0 -store 40 -load 41 +frame_bury 33 +frame_dig 34 callsub boolcomp_0 -store 41 -load 42 +frame_bury 34 +frame_dig 35 callsub boolcomp_0 -store 42 -load 43 +frame_bury 35 +frame_dig 36 callsub boolcomp_0 -store 43 -load 44 +frame_bury 36 +frame_dig 37 callsub boolcomp_0 -store 44 -load 45 +frame_bury 37 +frame_dig 38 callsub boolcomp_0 -store 45 -load 46 +frame_bury 38 +frame_dig 39 callsub boolcomp_0 -store 46 -load 47 +frame_bury 39 +frame_dig 40 callsub boolcomp_0 -store 47 -load 48 +frame_bury 40 +frame_dig 41 callsub boolcomp_0 -store 48 -load 49 +frame_bury 41 +frame_dig 42 callsub boolcomp_0 -store 49 +frame_bury 42 int 42 -store 50 -load 50 +frame_bury 45 +frame_dig 45 itob extract 6 0 byte 0x000000000000 int 0 -load 8 +frame_dig 1 setbit int 1 -load 9 +frame_dig 2 setbit int 2 -load 10 +frame_dig 3 setbit int 3 -load 11 +frame_dig 4 setbit int 4 -load 12 +frame_dig 5 setbit int 5 -load 13 +frame_dig 6 setbit int 6 -load 14 +frame_dig 7 setbit int 7 -load 15 +frame_dig 8 setbit int 8 -load 16 +frame_dig 9 setbit int 9 -load 17 +frame_dig 10 setbit int 10 -load 18 +frame_dig 11 setbit int 11 -load 19 +frame_dig 12 setbit int 12 -load 20 +frame_dig 13 setbit int 13 -load 21 +frame_dig 14 setbit int 14 -load 22 +frame_dig 15 setbit int 15 -load 23 +frame_dig 16 setbit int 16 -load 24 +frame_dig 17 setbit int 17 -load 25 +frame_dig 18 setbit int 18 -load 26 +frame_dig 19 setbit int 19 -load 27 +frame_dig 20 setbit int 20 -load 28 +frame_dig 21 setbit int 21 -load 29 +frame_dig 22 setbit int 22 -load 30 +frame_dig 23 setbit int 23 -load 31 +frame_dig 24 setbit int 24 -load 32 +frame_dig 25 setbit int 25 -load 33 +frame_dig 26 setbit int 26 -load 34 +frame_dig 27 setbit int 27 -load 35 +frame_dig 28 setbit int 28 -load 36 +frame_dig 29 setbit int 29 -load 37 +frame_dig 30 setbit int 30 -load 38 +frame_dig 31 setbit int 31 -load 39 +frame_dig 32 setbit int 32 -load 40 +frame_dig 33 setbit int 33 -load 41 +frame_dig 34 setbit int 34 -load 42 +frame_dig 35 setbit int 35 -load 43 +frame_dig 36 setbit int 36 -load 44 +frame_dig 37 setbit int 37 -load 45 +frame_dig 38 setbit int 38 -load 46 +frame_dig 39 setbit int 39 -load 47 +frame_dig 40 setbit int 40 -load 48 +frame_dig 41 setbit int 41 -load 49 +frame_dig 42 setbit concat frame_bury 0 @@ -544,64 +546,67 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 +load 3 concat -store 6 -load 5 -store 4 -load 4 -load 7 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 concat -store 6 -load 5 -store 4 -load 4 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_bool_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_bool_v8.teal index 5e08ac3d2..2a8a7572c 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_bool_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_bool_v8.teal @@ -30,21 +30,23 @@ retsub roundtripper_1: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 callsub boolcomp_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub boolcomp_0 -store 3 +frame_bury 2 byte 0x00 int 0 frame_dig -1 setbit int 1 -load 2 +frame_dig 1 setbit int 2 -load 3 +frame_dig 2 setbit frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_byte[16]_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_byte[16]_v8.teal index 86fa73f5a..345b09fcc 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_byte[16]_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_byte[16]_v8.teal @@ -29,227 +29,229 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 17 frame_dig -1 int 1 int 0 * getbyte -store 4 +frame_bury 1 frame_dig -1 int 1 int 1 * getbyte -store 5 +frame_bury 2 frame_dig -1 int 1 int 2 * getbyte -store 6 +frame_bury 3 frame_dig -1 int 1 int 3 * getbyte -store 7 +frame_bury 4 frame_dig -1 int 1 int 4 * getbyte -store 8 +frame_bury 5 frame_dig -1 int 1 int 5 * getbyte -store 9 +frame_bury 6 frame_dig -1 int 1 int 6 * getbyte -store 10 +frame_bury 7 frame_dig -1 int 1 int 7 * getbyte -store 11 +frame_bury 8 frame_dig -1 int 1 int 8 * getbyte -store 12 +frame_bury 9 frame_dig -1 int 1 int 9 * getbyte -store 13 +frame_bury 10 frame_dig -1 int 1 int 10 * getbyte -store 14 +frame_bury 11 frame_dig -1 int 1 int 11 * getbyte -store 15 +frame_bury 12 frame_dig -1 int 1 int 12 * getbyte -store 16 +frame_bury 13 frame_dig -1 int 1 int 13 * getbyte -store 17 +frame_bury 14 frame_dig -1 int 1 int 14 * getbyte -store 18 +frame_bury 15 frame_dig -1 int 1 int 15 * getbyte -store 19 -load 4 +frame_bury 16 +frame_dig 1 callsub numericalcomp_0 -store 4 -load 5 +frame_bury 1 +frame_dig 2 callsub numericalcomp_0 -store 5 -load 6 +frame_bury 2 +frame_dig 3 callsub numericalcomp_0 -store 6 -load 7 +frame_bury 3 +frame_dig 4 callsub numericalcomp_0 -store 7 -load 8 +frame_bury 4 +frame_dig 5 callsub numericalcomp_0 -store 8 -load 9 +frame_bury 5 +frame_dig 6 callsub numericalcomp_0 -store 9 -load 10 +frame_bury 6 +frame_dig 7 callsub numericalcomp_0 -store 10 -load 11 +frame_bury 7 +frame_dig 8 callsub numericalcomp_0 -store 11 -load 12 +frame_bury 8 +frame_dig 9 callsub numericalcomp_0 -store 12 -load 13 +frame_bury 9 +frame_dig 10 callsub numericalcomp_0 -store 13 -load 14 +frame_bury 10 +frame_dig 11 callsub numericalcomp_0 -store 14 -load 15 +frame_bury 11 +frame_dig 12 callsub numericalcomp_0 -store 15 -load 16 +frame_bury 12 +frame_dig 13 callsub numericalcomp_0 -store 16 -load 17 +frame_bury 13 +frame_dig 14 callsub numericalcomp_0 -store 17 -load 18 +frame_bury 14 +frame_dig 15 callsub numericalcomp_0 -store 18 -load 19 +frame_bury 15 +frame_dig 16 callsub numericalcomp_0 -store 19 +frame_bury 16 byte 0x00 int 0 -load 4 +frame_dig 1 setbyte byte 0x00 int 0 -load 5 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 6 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 7 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 8 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 9 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 10 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 11 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 12 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 13 +frame_dig 10 setbyte concat byte 0x00 int 0 -load 14 +frame_dig 11 setbyte concat byte 0x00 int 0 -load 15 +frame_dig 12 setbyte concat byte 0x00 int 0 -load 16 +frame_dig 13 setbyte concat byte 0x00 int 0 -load 17 +frame_dig 14 setbyte concat byte 0x00 int 0 -load 18 +frame_dig 15 setbyte concat byte 0x00 int 0 -load 19 +frame_dig 16 setbyte concat frame_bury 0 @@ -259,16 +261,19 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 3 +frame_bury 2 frame_dig -1 -load 2 +frame_dig 1 concat -load 3 +frame_dig 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_byte[]_36_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_byte[]_36_v8.teal index 3b92e3e84..1b999bd87 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_byte[]_36_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_byte[]_36_v8.teal @@ -29,6 +29,8 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 74 frame_dig -1 int 1 int 0 @@ -36,7 +38,7 @@ int 0 int 2 + getbyte -store 8 +frame_bury 1 frame_dig -1 int 1 int 1 @@ -44,7 +46,7 @@ int 1 int 2 + getbyte -store 9 +frame_bury 2 frame_dig -1 int 1 int 2 @@ -52,7 +54,7 @@ int 2 int 2 + getbyte -store 10 +frame_bury 3 frame_dig -1 int 1 int 3 @@ -60,7 +62,7 @@ int 3 int 2 + getbyte -store 11 +frame_bury 4 frame_dig -1 int 1 int 4 @@ -68,7 +70,7 @@ int 4 int 2 + getbyte -store 12 +frame_bury 5 frame_dig -1 int 1 int 5 @@ -76,7 +78,7 @@ int 5 int 2 + getbyte -store 13 +frame_bury 6 frame_dig -1 int 1 int 6 @@ -84,7 +86,7 @@ int 6 int 2 + getbyte -store 14 +frame_bury 7 frame_dig -1 int 1 int 7 @@ -92,7 +94,7 @@ int 7 int 2 + getbyte -store 15 +frame_bury 8 frame_dig -1 int 1 int 8 @@ -100,7 +102,7 @@ int 8 int 2 + getbyte -store 16 +frame_bury 9 frame_dig -1 int 1 int 9 @@ -108,7 +110,7 @@ int 9 int 2 + getbyte -store 17 +frame_bury 10 frame_dig -1 int 1 int 10 @@ -116,7 +118,7 @@ int 10 int 2 + getbyte -store 18 +frame_bury 11 frame_dig -1 int 1 int 11 @@ -124,7 +126,7 @@ int 11 int 2 + getbyte -store 19 +frame_bury 12 frame_dig -1 int 1 int 12 @@ -132,7 +134,7 @@ int 12 int 2 + getbyte -store 20 +frame_bury 13 frame_dig -1 int 1 int 13 @@ -140,7 +142,7 @@ int 13 int 2 + getbyte -store 21 +frame_bury 14 frame_dig -1 int 1 int 14 @@ -148,7 +150,7 @@ int 14 int 2 + getbyte -store 22 +frame_bury 15 frame_dig -1 int 1 int 15 @@ -156,7 +158,7 @@ int 15 int 2 + getbyte -store 23 +frame_bury 16 frame_dig -1 int 1 int 16 @@ -164,7 +166,7 @@ int 16 int 2 + getbyte -store 24 +frame_bury 17 frame_dig -1 int 1 int 17 @@ -172,7 +174,7 @@ int 17 int 2 + getbyte -store 25 +frame_bury 18 frame_dig -1 int 1 int 18 @@ -180,7 +182,7 @@ int 18 int 2 + getbyte -store 26 +frame_bury 19 frame_dig -1 int 1 int 19 @@ -188,7 +190,7 @@ int 19 int 2 + getbyte -store 27 +frame_bury 20 frame_dig -1 int 1 int 20 @@ -196,7 +198,7 @@ int 20 int 2 + getbyte -store 28 +frame_bury 21 frame_dig -1 int 1 int 21 @@ -204,7 +206,7 @@ int 21 int 2 + getbyte -store 29 +frame_bury 22 frame_dig -1 int 1 int 22 @@ -212,7 +214,7 @@ int 22 int 2 + getbyte -store 30 +frame_bury 23 frame_dig -1 int 1 int 23 @@ -220,7 +222,7 @@ int 23 int 2 + getbyte -store 31 +frame_bury 24 frame_dig -1 int 1 int 24 @@ -228,7 +230,7 @@ int 24 int 2 + getbyte -store 32 +frame_bury 25 frame_dig -1 int 1 int 25 @@ -236,7 +238,7 @@ int 25 int 2 + getbyte -store 33 +frame_bury 26 frame_dig -1 int 1 int 26 @@ -244,7 +246,7 @@ int 26 int 2 + getbyte -store 34 +frame_bury 27 frame_dig -1 int 1 int 27 @@ -252,7 +254,7 @@ int 27 int 2 + getbyte -store 35 +frame_bury 28 frame_dig -1 int 1 int 28 @@ -260,7 +262,7 @@ int 28 int 2 + getbyte -store 36 +frame_bury 29 frame_dig -1 int 1 int 29 @@ -268,7 +270,7 @@ int 29 int 2 + getbyte -store 37 +frame_bury 30 frame_dig -1 int 1 int 30 @@ -276,7 +278,7 @@ int 30 int 2 + getbyte -store 38 +frame_bury 31 frame_dig -1 int 1 int 31 @@ -284,7 +286,7 @@ int 31 int 2 + getbyte -store 39 +frame_bury 32 frame_dig -1 int 1 int 32 @@ -292,7 +294,7 @@ int 32 int 2 + getbyte -store 40 +frame_bury 33 frame_dig -1 int 1 int 33 @@ -300,7 +302,7 @@ int 33 int 2 + getbyte -store 41 +frame_bury 34 frame_dig -1 int 1 int 34 @@ -308,7 +310,7 @@ int 34 int 2 + getbyte -store 42 +frame_bury 35 frame_dig -1 int 1 int 35 @@ -316,297 +318,297 @@ int 35 int 2 + getbyte -store 43 -load 8 +frame_bury 36 +frame_dig 1 callsub numericalcomp_0 -store 8 -load 9 +frame_bury 1 +frame_dig 2 callsub numericalcomp_0 -store 9 -load 10 +frame_bury 2 +frame_dig 3 callsub numericalcomp_0 -store 10 -load 11 +frame_bury 3 +frame_dig 4 callsub numericalcomp_0 -store 11 -load 12 +frame_bury 4 +frame_dig 5 callsub numericalcomp_0 -store 12 -load 13 +frame_bury 5 +frame_dig 6 callsub numericalcomp_0 -store 13 -load 14 +frame_bury 6 +frame_dig 7 callsub numericalcomp_0 -store 14 -load 15 +frame_bury 7 +frame_dig 8 callsub numericalcomp_0 -store 15 -load 16 +frame_bury 8 +frame_dig 9 callsub numericalcomp_0 -store 16 -load 17 +frame_bury 9 +frame_dig 10 callsub numericalcomp_0 -store 17 -load 18 +frame_bury 10 +frame_dig 11 callsub numericalcomp_0 -store 18 -load 19 +frame_bury 11 +frame_dig 12 callsub numericalcomp_0 -store 19 -load 20 +frame_bury 12 +frame_dig 13 callsub numericalcomp_0 -store 20 -load 21 +frame_bury 13 +frame_dig 14 callsub numericalcomp_0 -store 21 -load 22 +frame_bury 14 +frame_dig 15 callsub numericalcomp_0 -store 22 -load 23 +frame_bury 15 +frame_dig 16 callsub numericalcomp_0 -store 23 -load 24 +frame_bury 16 +frame_dig 17 callsub numericalcomp_0 -store 24 -load 25 +frame_bury 17 +frame_dig 18 callsub numericalcomp_0 -store 25 -load 26 +frame_bury 18 +frame_dig 19 callsub numericalcomp_0 -store 26 -load 27 +frame_bury 19 +frame_dig 20 callsub numericalcomp_0 -store 27 -load 28 +frame_bury 20 +frame_dig 21 callsub numericalcomp_0 -store 28 -load 29 +frame_bury 21 +frame_dig 22 callsub numericalcomp_0 -store 29 -load 30 +frame_bury 22 +frame_dig 23 callsub numericalcomp_0 -store 30 -load 31 +frame_bury 23 +frame_dig 24 callsub numericalcomp_0 -store 31 -load 32 +frame_bury 24 +frame_dig 25 callsub numericalcomp_0 -store 32 -load 33 +frame_bury 25 +frame_dig 26 callsub numericalcomp_0 -store 33 -load 34 +frame_bury 26 +frame_dig 27 callsub numericalcomp_0 -store 34 -load 35 +frame_bury 27 +frame_dig 28 callsub numericalcomp_0 -store 35 -load 36 +frame_bury 28 +frame_dig 29 callsub numericalcomp_0 -store 36 -load 37 +frame_bury 29 +frame_dig 30 callsub numericalcomp_0 -store 37 -load 38 +frame_bury 30 +frame_dig 31 callsub numericalcomp_0 -store 38 -load 39 +frame_bury 31 +frame_dig 32 callsub numericalcomp_0 -store 39 -load 40 +frame_bury 32 +frame_dig 33 callsub numericalcomp_0 -store 40 -load 41 +frame_bury 33 +frame_dig 34 callsub numericalcomp_0 -store 41 -load 42 +frame_bury 34 +frame_dig 35 callsub numericalcomp_0 -store 42 -load 43 +frame_bury 35 +frame_dig 36 callsub numericalcomp_0 -store 43 +frame_bury 36 int 36 -store 44 -load 44 +frame_bury 75 +frame_dig 75 itob extract 6 0 byte 0x00 int 0 -load 8 +frame_dig 1 setbyte byte 0x00 int 0 -load 9 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 10 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 11 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 12 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 13 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 14 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 15 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 16 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 17 +frame_dig 10 setbyte concat byte 0x00 int 0 -load 18 +frame_dig 11 setbyte concat byte 0x00 int 0 -load 19 +frame_dig 12 setbyte concat byte 0x00 int 0 -load 20 +frame_dig 13 setbyte concat byte 0x00 int 0 -load 21 +frame_dig 14 setbyte concat byte 0x00 int 0 -load 22 +frame_dig 15 setbyte concat byte 0x00 int 0 -load 23 +frame_dig 16 setbyte concat byte 0x00 int 0 -load 24 +frame_dig 17 setbyte concat byte 0x00 int 0 -load 25 +frame_dig 18 setbyte concat byte 0x00 int 0 -load 26 +frame_dig 19 setbyte concat byte 0x00 int 0 -load 27 +frame_dig 20 setbyte concat byte 0x00 int 0 -load 28 +frame_dig 21 setbyte concat byte 0x00 int 0 -load 29 +frame_dig 22 setbyte concat byte 0x00 int 0 -load 30 +frame_dig 23 setbyte concat byte 0x00 int 0 -load 31 +frame_dig 24 setbyte concat byte 0x00 int 0 -load 32 +frame_dig 25 setbyte concat byte 0x00 int 0 -load 33 +frame_dig 26 setbyte concat byte 0x00 int 0 -load 34 +frame_dig 27 setbyte concat byte 0x00 int 0 -load 35 +frame_dig 28 setbyte concat byte 0x00 int 0 -load 36 +frame_dig 29 setbyte concat byte 0x00 int 0 -load 37 +frame_dig 30 setbyte concat byte 0x00 int 0 -load 38 +frame_dig 31 setbyte concat byte 0x00 int 0 -load 39 +frame_dig 32 setbyte concat byte 0x00 int 0 -load 40 +frame_dig 33 setbyte concat byte 0x00 int 0 -load 41 +frame_dig 34 setbyte concat byte 0x00 int 0 -load 42 +frame_dig 35 setbyte concat byte 0x00 int 0 -load 43 +frame_dig 36 setbyte concat concat @@ -617,64 +619,67 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 -concat -store 6 -load 5 -store 4 -load 4 -load 7 +load 3 +concat +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 -concat -store 6 -load 5 -store 4 -load 4 +concat +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_byte_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_byte_v8.teal index c7dfcc09f..58daf6eb2 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_byte_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_byte_v8.teal @@ -31,24 +31,26 @@ retsub roundtripper_1: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 callsub numericalcomp_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub numericalcomp_0 -store 3 +frame_bury 2 byte 0x00 int 0 frame_dig -1 setbyte byte 0x00 int 0 -load 2 +frame_dig 1 setbyte concat byte 0x00 int 0 -load 3 +frame_dig 2 setbyte concat frame_bury 0 diff --git a/tests/integration/teal/roundtrip/app_roundtrip_string_0_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_string_0_v8.teal index f6742b7c1..235d01ed3 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_string_0_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_string_0_v8.teal @@ -16,8 +16,10 @@ stringreverse_0: proto 1 1 byte "" int 0 -store 8 -load 8 +dupn 2 +int 0 +frame_bury 3 +frame_dig 3 itob extract 6 0 byte "" @@ -29,64 +31,67 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub stringreverse_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub stringreverse_0 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 +load 3 concat -store 6 -load 5 -store 4 -load 4 -load 7 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 concat -store 6 -load 5 -store 4 -load 4 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_string_13_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_string_13_v8.teal index 4e608a404..63c41ab5a 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_string_13_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_string_13_v8.teal @@ -15,6 +15,8 @@ return stringreverse_0: proto 1 1 byte "" +int 0 +dupn 28 frame_dig -1 int 1 int 0 @@ -22,7 +24,7 @@ int 0 int 2 + getbyte -store 20 +frame_bury 13 frame_dig -1 int 1 int 1 @@ -30,7 +32,7 @@ int 1 int 2 + getbyte -store 19 +frame_bury 12 frame_dig -1 int 1 int 2 @@ -38,7 +40,7 @@ int 2 int 2 + getbyte -store 18 +frame_bury 11 frame_dig -1 int 1 int 3 @@ -46,7 +48,7 @@ int 3 int 2 + getbyte -store 17 +frame_bury 10 frame_dig -1 int 1 int 4 @@ -54,7 +56,7 @@ int 4 int 2 + getbyte -store 16 +frame_bury 9 frame_dig -1 int 1 int 5 @@ -62,7 +64,7 @@ int 5 int 2 + getbyte -store 15 +frame_bury 8 frame_dig -1 int 1 int 6 @@ -70,7 +72,7 @@ int 6 int 2 + getbyte -store 14 +frame_bury 7 frame_dig -1 int 1 int 7 @@ -78,7 +80,7 @@ int 7 int 2 + getbyte -store 13 +frame_bury 6 frame_dig -1 int 1 int 8 @@ -86,7 +88,7 @@ int 8 int 2 + getbyte -store 12 +frame_bury 5 frame_dig -1 int 1 int 9 @@ -94,7 +96,7 @@ int 9 int 2 + getbyte -store 11 +frame_bury 4 frame_dig -1 int 1 int 10 @@ -102,7 +104,7 @@ int 10 int 2 + getbyte -store 10 +frame_bury 3 frame_dig -1 int 1 int 11 @@ -110,7 +112,7 @@ int 11 int 2 + getbyte -store 9 +frame_bury 2 frame_dig -1 int 1 int 12 @@ -118,74 +120,74 @@ int 12 int 2 + getbyte -store 8 +frame_bury 1 int 13 -store 21 -load 21 +frame_bury 29 +frame_dig 29 itob extract 6 0 byte 0x00 int 0 -load 8 +frame_dig 1 setbyte byte 0x00 int 0 -load 9 +frame_dig 2 setbyte concat byte 0x00 int 0 -load 10 +frame_dig 3 setbyte concat byte 0x00 int 0 -load 11 +frame_dig 4 setbyte concat byte 0x00 int 0 -load 12 +frame_dig 5 setbyte concat byte 0x00 int 0 -load 13 +frame_dig 6 setbyte concat byte 0x00 int 0 -load 14 +frame_dig 7 setbyte concat byte 0x00 int 0 -load 15 +frame_dig 8 setbyte concat byte 0x00 int 0 -load 16 +frame_dig 9 setbyte concat byte 0x00 int 0 -load 17 +frame_dig 10 setbyte concat byte 0x00 int 0 -load 18 +frame_dig 11 setbyte concat byte 0x00 int 0 -load 19 +frame_dig 12 setbyte concat byte 0x00 int 0 -load 20 +frame_dig 13 setbyte concat concat @@ -196,64 +198,67 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub stringreverse_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub stringreverse_0 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 +load 3 concat -store 6 -load 5 -store 4 -load 4 -load 7 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 concat -store 6 -load 5 -store 4 -load 4 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_string_1_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_string_1_v8.teal index 8a72badb8..290537714 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_string_1_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_string_1_v8.teal @@ -15,6 +15,8 @@ return stringreverse_0: proto 1 1 byte "" +int 0 +dupn 4 frame_dig -1 int 1 int 0 @@ -22,15 +24,15 @@ int 0 int 2 + getbyte -store 8 +frame_bury 1 int 1 -store 9 -load 9 +frame_bury 5 +frame_dig 5 itob extract 6 0 byte 0x00 int 0 -load 8 +frame_dig 1 setbyte concat frame_bury 0 @@ -40,64 +42,67 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub stringreverse_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub stringreverse_0 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 +load 3 concat -store 6 -load 5 -store 4 -load 4 -load 7 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 concat -store 6 -load 5 -store 4 -load 4 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_uint16_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_uint16_v8.teal index 2baecd50a..4a27045bf 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_uint16_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_uint16_v8.teal @@ -31,20 +31,22 @@ retsub roundtripper_1: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 callsub numericalcomp_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub numericalcomp_0 -store 3 +frame_bury 2 frame_dig -1 itob extract 6 0 -load 2 +frame_dig 1 itob extract 6 0 concat -load 3 +frame_dig 2 itob extract 6 0 concat diff --git a/tests/integration/teal/roundtrip/app_roundtrip_uint32_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_uint32_v8.teal index d495dae9d..ce183aab6 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_uint32_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_uint32_v8.teal @@ -31,20 +31,22 @@ retsub roundtripper_1: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 callsub numericalcomp_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub numericalcomp_0 -store 3 +frame_bury 2 frame_dig -1 itob extract 4 0 -load 2 +frame_dig 1 itob extract 4 0 concat -load 3 +frame_dig 2 itob extract 4 0 concat diff --git a/tests/integration/teal/roundtrip/app_roundtrip_uint64[1]_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_uint64[1]_v8.teal index 48d881ec6..603cd4a6a 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_uint64[1]_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_uint64[1]_v8.teal @@ -25,16 +25,18 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 2 frame_dig -1 int 8 int 0 * extract_uint64 -store 4 -load 4 +frame_bury 1 +frame_dig 1 callsub numericalcomp_0 -store 4 -load 4 +frame_bury 1 +frame_dig 1 itob frame_bury 0 retsub @@ -43,16 +45,19 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 3 +frame_bury 2 frame_dig -1 -load 2 +frame_dig 1 concat -load 3 +frame_dig 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_uint64[42]_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_uint64[42]_v8.teal index 9126983f1..ac132adf3 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_uint64[42]_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_uint64[42]_v8.teal @@ -25,507 +25,509 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 43 frame_dig -1 int 8 int 0 * extract_uint64 -store 4 +frame_bury 1 frame_dig -1 int 8 int 1 * extract_uint64 -store 5 +frame_bury 2 frame_dig -1 int 8 int 2 * extract_uint64 -store 6 +frame_bury 3 frame_dig -1 int 8 int 3 * extract_uint64 -store 7 +frame_bury 4 frame_dig -1 int 8 int 4 * extract_uint64 -store 8 +frame_bury 5 frame_dig -1 int 8 int 5 * extract_uint64 -store 9 +frame_bury 6 frame_dig -1 int 8 int 6 * extract_uint64 -store 10 +frame_bury 7 frame_dig -1 int 8 int 7 * extract_uint64 -store 11 +frame_bury 8 frame_dig -1 int 8 int 8 * extract_uint64 -store 12 +frame_bury 9 frame_dig -1 int 8 int 9 * extract_uint64 -store 13 +frame_bury 10 frame_dig -1 int 8 int 10 * extract_uint64 -store 14 +frame_bury 11 frame_dig -1 int 8 int 11 * extract_uint64 -store 15 +frame_bury 12 frame_dig -1 int 8 int 12 * extract_uint64 -store 16 +frame_bury 13 frame_dig -1 int 8 int 13 * extract_uint64 -store 17 +frame_bury 14 frame_dig -1 int 8 int 14 * extract_uint64 -store 18 +frame_bury 15 frame_dig -1 int 8 int 15 * extract_uint64 -store 19 +frame_bury 16 frame_dig -1 int 8 int 16 * extract_uint64 -store 20 +frame_bury 17 frame_dig -1 int 8 int 17 * extract_uint64 -store 21 +frame_bury 18 frame_dig -1 int 8 int 18 * extract_uint64 -store 22 +frame_bury 19 frame_dig -1 int 8 int 19 * extract_uint64 -store 23 +frame_bury 20 frame_dig -1 int 8 int 20 * extract_uint64 -store 24 +frame_bury 21 frame_dig -1 int 8 int 21 * extract_uint64 -store 25 +frame_bury 22 frame_dig -1 int 8 int 22 * extract_uint64 -store 26 +frame_bury 23 frame_dig -1 int 8 int 23 * extract_uint64 -store 27 +frame_bury 24 frame_dig -1 int 8 int 24 * extract_uint64 -store 28 +frame_bury 25 frame_dig -1 int 8 int 25 * extract_uint64 -store 29 +frame_bury 26 frame_dig -1 int 8 int 26 * extract_uint64 -store 30 +frame_bury 27 frame_dig -1 int 8 int 27 * extract_uint64 -store 31 +frame_bury 28 frame_dig -1 int 8 int 28 * extract_uint64 -store 32 +frame_bury 29 frame_dig -1 int 8 int 29 * extract_uint64 -store 33 +frame_bury 30 frame_dig -1 int 8 int 30 * extract_uint64 -store 34 +frame_bury 31 frame_dig -1 int 8 int 31 * extract_uint64 -store 35 +frame_bury 32 frame_dig -1 int 8 int 32 * extract_uint64 -store 36 +frame_bury 33 frame_dig -1 int 8 int 33 * extract_uint64 -store 37 +frame_bury 34 frame_dig -1 int 8 int 34 * extract_uint64 -store 38 +frame_bury 35 frame_dig -1 int 8 int 35 * extract_uint64 -store 39 +frame_bury 36 frame_dig -1 int 8 int 36 * extract_uint64 -store 40 +frame_bury 37 frame_dig -1 int 8 int 37 * extract_uint64 -store 41 +frame_bury 38 frame_dig -1 int 8 int 38 * extract_uint64 -store 42 +frame_bury 39 frame_dig -1 int 8 int 39 * extract_uint64 -store 43 +frame_bury 40 frame_dig -1 int 8 int 40 * extract_uint64 -store 44 +frame_bury 41 frame_dig -1 int 8 int 41 * extract_uint64 -store 45 -load 4 +frame_bury 42 +frame_dig 1 callsub numericalcomp_0 -store 4 -load 5 +frame_bury 1 +frame_dig 2 callsub numericalcomp_0 -store 5 -load 6 +frame_bury 2 +frame_dig 3 callsub numericalcomp_0 -store 6 -load 7 +frame_bury 3 +frame_dig 4 callsub numericalcomp_0 -store 7 -load 8 +frame_bury 4 +frame_dig 5 callsub numericalcomp_0 -store 8 -load 9 +frame_bury 5 +frame_dig 6 callsub numericalcomp_0 -store 9 -load 10 +frame_bury 6 +frame_dig 7 callsub numericalcomp_0 -store 10 -load 11 +frame_bury 7 +frame_dig 8 callsub numericalcomp_0 -store 11 -load 12 +frame_bury 8 +frame_dig 9 callsub numericalcomp_0 -store 12 -load 13 +frame_bury 9 +frame_dig 10 callsub numericalcomp_0 -store 13 -load 14 +frame_bury 10 +frame_dig 11 callsub numericalcomp_0 -store 14 -load 15 +frame_bury 11 +frame_dig 12 callsub numericalcomp_0 -store 15 -load 16 +frame_bury 12 +frame_dig 13 callsub numericalcomp_0 -store 16 -load 17 +frame_bury 13 +frame_dig 14 callsub numericalcomp_0 -store 17 -load 18 +frame_bury 14 +frame_dig 15 callsub numericalcomp_0 -store 18 -load 19 +frame_bury 15 +frame_dig 16 callsub numericalcomp_0 -store 19 -load 20 +frame_bury 16 +frame_dig 17 callsub numericalcomp_0 -store 20 -load 21 +frame_bury 17 +frame_dig 18 callsub numericalcomp_0 -store 21 -load 22 +frame_bury 18 +frame_dig 19 callsub numericalcomp_0 -store 22 -load 23 +frame_bury 19 +frame_dig 20 callsub numericalcomp_0 -store 23 -load 24 +frame_bury 20 +frame_dig 21 callsub numericalcomp_0 -store 24 -load 25 +frame_bury 21 +frame_dig 22 callsub numericalcomp_0 -store 25 -load 26 +frame_bury 22 +frame_dig 23 callsub numericalcomp_0 -store 26 -load 27 +frame_bury 23 +frame_dig 24 callsub numericalcomp_0 -store 27 -load 28 +frame_bury 24 +frame_dig 25 callsub numericalcomp_0 -store 28 -load 29 +frame_bury 25 +frame_dig 26 callsub numericalcomp_0 -store 29 -load 30 +frame_bury 26 +frame_dig 27 callsub numericalcomp_0 -store 30 -load 31 +frame_bury 27 +frame_dig 28 callsub numericalcomp_0 -store 31 -load 32 +frame_bury 28 +frame_dig 29 callsub numericalcomp_0 -store 32 -load 33 +frame_bury 29 +frame_dig 30 callsub numericalcomp_0 -store 33 -load 34 +frame_bury 30 +frame_dig 31 callsub numericalcomp_0 -store 34 -load 35 +frame_bury 31 +frame_dig 32 callsub numericalcomp_0 -store 35 -load 36 +frame_bury 32 +frame_dig 33 callsub numericalcomp_0 -store 36 -load 37 +frame_bury 33 +frame_dig 34 callsub numericalcomp_0 -store 37 -load 38 +frame_bury 34 +frame_dig 35 callsub numericalcomp_0 -store 38 -load 39 +frame_bury 35 +frame_dig 36 callsub numericalcomp_0 -store 39 -load 40 +frame_bury 36 +frame_dig 37 callsub numericalcomp_0 -store 40 -load 41 +frame_bury 37 +frame_dig 38 callsub numericalcomp_0 -store 41 -load 42 +frame_bury 38 +frame_dig 39 callsub numericalcomp_0 -store 42 -load 43 +frame_bury 39 +frame_dig 40 callsub numericalcomp_0 -store 43 -load 44 +frame_bury 40 +frame_dig 41 callsub numericalcomp_0 -store 44 -load 45 +frame_bury 41 +frame_dig 42 callsub numericalcomp_0 -store 45 -load 4 +frame_bury 42 +frame_dig 1 itob -load 5 +frame_dig 2 itob concat -load 6 +frame_dig 3 itob concat -load 7 +frame_dig 4 itob concat -load 8 +frame_dig 5 itob concat -load 9 +frame_dig 6 itob concat -load 10 +frame_dig 7 itob concat -load 11 +frame_dig 8 itob concat -load 12 +frame_dig 9 itob concat -load 13 +frame_dig 10 itob concat -load 14 +frame_dig 11 itob concat -load 15 +frame_dig 12 itob concat -load 16 +frame_dig 13 itob concat -load 17 +frame_dig 14 itob concat -load 18 +frame_dig 15 itob concat -load 19 +frame_dig 16 itob concat -load 20 +frame_dig 17 itob concat -load 21 +frame_dig 18 itob concat -load 22 +frame_dig 19 itob concat -load 23 +frame_dig 20 itob concat -load 24 +frame_dig 21 itob concat -load 25 +frame_dig 22 itob concat -load 26 +frame_dig 23 itob concat -load 27 +frame_dig 24 itob concat -load 28 +frame_dig 25 itob concat -load 29 +frame_dig 26 itob concat -load 30 +frame_dig 27 itob concat -load 31 +frame_dig 28 itob concat -load 32 +frame_dig 29 itob concat -load 33 +frame_dig 30 itob concat -load 34 +frame_dig 31 itob concat -load 35 +frame_dig 32 itob concat -load 36 +frame_dig 33 itob concat -load 37 +frame_dig 34 itob concat -load 38 +frame_dig 35 itob concat -load 39 +frame_dig 36 itob concat -load 40 +frame_dig 37 itob concat -load 41 +frame_dig 38 itob concat -load 42 +frame_dig 39 itob concat -load 43 +frame_dig 40 itob concat -load 44 +frame_dig 41 itob concat -load 45 +frame_dig 42 itob concat frame_bury 0 @@ -535,16 +537,19 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 3 +frame_bury 2 frame_dig -1 -load 2 +frame_dig 1 concat -load 3 +frame_dig 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_0_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_0_v8.teal index 87f935c92..173e4c5c5 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_0_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_0_v8.teal @@ -16,8 +16,10 @@ arraycomplement_0: proto 1 1 byte "" int 0 -store 8 -load 8 +dupn 2 +int 0 +frame_bury 3 +frame_dig 3 itob extract 6 0 byte "" @@ -29,64 +31,67 @@ retsub roundtripper_1: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_0 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 +load 3 concat -store 6 -load 5 -store 4 -load 4 -load 7 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 concat -store 6 -load 5 -store 4 -load 4 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_1_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_1_v8.teal index fb4caf8bd..2c095611e 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_1_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_1_v8.teal @@ -25,6 +25,8 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 4 frame_dig -1 int 8 int 0 @@ -32,16 +34,16 @@ int 0 int 2 + extract_uint64 -store 8 -load 8 +frame_bury 1 +frame_dig 1 callsub numericalcomp_0 -store 8 +frame_bury 1 int 1 -store 9 -load 9 +frame_bury 5 +frame_dig 5 itob extract 6 0 -load 8 +frame_dig 1 itob concat frame_bury 0 @@ -51,64 +53,67 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 +load 3 concat -store 6 -load 5 -store 4 -load 4 -load 7 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 concat -store 6 -load 5 -store 4 -load 4 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_42_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_42_v8.teal index cf61ff80f..c05b53930 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_42_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_uint64[]_42_v8.teal @@ -25,6 +25,8 @@ retsub arraycomplement_1: proto 1 1 byte "" +int 0 +dupn 86 frame_dig -1 int 8 int 0 @@ -32,7 +34,7 @@ int 0 int 2 + extract_uint64 -store 8 +frame_bury 1 frame_dig -1 int 8 int 1 @@ -40,7 +42,7 @@ int 1 int 2 + extract_uint64 -store 9 +frame_bury 2 frame_dig -1 int 8 int 2 @@ -48,7 +50,7 @@ int 2 int 2 + extract_uint64 -store 10 +frame_bury 3 frame_dig -1 int 8 int 3 @@ -56,7 +58,7 @@ int 3 int 2 + extract_uint64 -store 11 +frame_bury 4 frame_dig -1 int 8 int 4 @@ -64,7 +66,7 @@ int 4 int 2 + extract_uint64 -store 12 +frame_bury 5 frame_dig -1 int 8 int 5 @@ -72,7 +74,7 @@ int 5 int 2 + extract_uint64 -store 13 +frame_bury 6 frame_dig -1 int 8 int 6 @@ -80,7 +82,7 @@ int 6 int 2 + extract_uint64 -store 14 +frame_bury 7 frame_dig -1 int 8 int 7 @@ -88,7 +90,7 @@ int 7 int 2 + extract_uint64 -store 15 +frame_bury 8 frame_dig -1 int 8 int 8 @@ -96,7 +98,7 @@ int 8 int 2 + extract_uint64 -store 16 +frame_bury 9 frame_dig -1 int 8 int 9 @@ -104,7 +106,7 @@ int 9 int 2 + extract_uint64 -store 17 +frame_bury 10 frame_dig -1 int 8 int 10 @@ -112,7 +114,7 @@ int 10 int 2 + extract_uint64 -store 18 +frame_bury 11 frame_dig -1 int 8 int 11 @@ -120,7 +122,7 @@ int 11 int 2 + extract_uint64 -store 19 +frame_bury 12 frame_dig -1 int 8 int 12 @@ -128,7 +130,7 @@ int 12 int 2 + extract_uint64 -store 20 +frame_bury 13 frame_dig -1 int 8 int 13 @@ -136,7 +138,7 @@ int 13 int 2 + extract_uint64 -store 21 +frame_bury 14 frame_dig -1 int 8 int 14 @@ -144,7 +146,7 @@ int 14 int 2 + extract_uint64 -store 22 +frame_bury 15 frame_dig -1 int 8 int 15 @@ -152,7 +154,7 @@ int 15 int 2 + extract_uint64 -store 23 +frame_bury 16 frame_dig -1 int 8 int 16 @@ -160,7 +162,7 @@ int 16 int 2 + extract_uint64 -store 24 +frame_bury 17 frame_dig -1 int 8 int 17 @@ -168,7 +170,7 @@ int 17 int 2 + extract_uint64 -store 25 +frame_bury 18 frame_dig -1 int 8 int 18 @@ -176,7 +178,7 @@ int 18 int 2 + extract_uint64 -store 26 +frame_bury 19 frame_dig -1 int 8 int 19 @@ -184,7 +186,7 @@ int 19 int 2 + extract_uint64 -store 27 +frame_bury 20 frame_dig -1 int 8 int 20 @@ -192,7 +194,7 @@ int 20 int 2 + extract_uint64 -store 28 +frame_bury 21 frame_dig -1 int 8 int 21 @@ -200,7 +202,7 @@ int 21 int 2 + extract_uint64 -store 29 +frame_bury 22 frame_dig -1 int 8 int 22 @@ -208,7 +210,7 @@ int 22 int 2 + extract_uint64 -store 30 +frame_bury 23 frame_dig -1 int 8 int 23 @@ -216,7 +218,7 @@ int 23 int 2 + extract_uint64 -store 31 +frame_bury 24 frame_dig -1 int 8 int 24 @@ -224,7 +226,7 @@ int 24 int 2 + extract_uint64 -store 32 +frame_bury 25 frame_dig -1 int 8 int 25 @@ -232,7 +234,7 @@ int 25 int 2 + extract_uint64 -store 33 +frame_bury 26 frame_dig -1 int 8 int 26 @@ -240,7 +242,7 @@ int 26 int 2 + extract_uint64 -store 34 +frame_bury 27 frame_dig -1 int 8 int 27 @@ -248,7 +250,7 @@ int 27 int 2 + extract_uint64 -store 35 +frame_bury 28 frame_dig -1 int 8 int 28 @@ -256,7 +258,7 @@ int 28 int 2 + extract_uint64 -store 36 +frame_bury 29 frame_dig -1 int 8 int 29 @@ -264,7 +266,7 @@ int 29 int 2 + extract_uint64 -store 37 +frame_bury 30 frame_dig -1 int 8 int 30 @@ -272,7 +274,7 @@ int 30 int 2 + extract_uint64 -store 38 +frame_bury 31 frame_dig -1 int 8 int 31 @@ -280,7 +282,7 @@ int 31 int 2 + extract_uint64 -store 39 +frame_bury 32 frame_dig -1 int 8 int 32 @@ -288,7 +290,7 @@ int 32 int 2 + extract_uint64 -store 40 +frame_bury 33 frame_dig -1 int 8 int 33 @@ -296,7 +298,7 @@ int 33 int 2 + extract_uint64 -store 41 +frame_bury 34 frame_dig -1 int 8 int 34 @@ -304,7 +306,7 @@ int 34 int 2 + extract_uint64 -store 42 +frame_bury 35 frame_dig -1 int 8 int 35 @@ -312,7 +314,7 @@ int 35 int 2 + extract_uint64 -store 43 +frame_bury 36 frame_dig -1 int 8 int 36 @@ -320,7 +322,7 @@ int 36 int 2 + extract_uint64 -store 44 +frame_bury 37 frame_dig -1 int 8 int 37 @@ -328,7 +330,7 @@ int 37 int 2 + extract_uint64 -store 45 +frame_bury 38 frame_dig -1 int 8 int 38 @@ -336,7 +338,7 @@ int 38 int 2 + extract_uint64 -store 46 +frame_bury 39 frame_dig -1 int 8 int 39 @@ -344,7 +346,7 @@ int 39 int 2 + extract_uint64 -store 47 +frame_bury 40 frame_dig -1 int 8 int 40 @@ -352,7 +354,7 @@ int 40 int 2 + extract_uint64 -store 48 +frame_bury 41 frame_dig -1 int 8 int 41 @@ -360,261 +362,261 @@ int 41 int 2 + extract_uint64 -store 49 -load 8 +frame_bury 42 +frame_dig 1 callsub numericalcomp_0 -store 8 -load 9 +frame_bury 1 +frame_dig 2 callsub numericalcomp_0 -store 9 -load 10 +frame_bury 2 +frame_dig 3 callsub numericalcomp_0 -store 10 -load 11 +frame_bury 3 +frame_dig 4 callsub numericalcomp_0 -store 11 -load 12 +frame_bury 4 +frame_dig 5 callsub numericalcomp_0 -store 12 -load 13 +frame_bury 5 +frame_dig 6 callsub numericalcomp_0 -store 13 -load 14 +frame_bury 6 +frame_dig 7 callsub numericalcomp_0 -store 14 -load 15 +frame_bury 7 +frame_dig 8 callsub numericalcomp_0 -store 15 -load 16 +frame_bury 8 +frame_dig 9 callsub numericalcomp_0 -store 16 -load 17 +frame_bury 9 +frame_dig 10 callsub numericalcomp_0 -store 17 -load 18 +frame_bury 10 +frame_dig 11 callsub numericalcomp_0 -store 18 -load 19 +frame_bury 11 +frame_dig 12 callsub numericalcomp_0 -store 19 -load 20 +frame_bury 12 +frame_dig 13 callsub numericalcomp_0 -store 20 -load 21 +frame_bury 13 +frame_dig 14 callsub numericalcomp_0 -store 21 -load 22 +frame_bury 14 +frame_dig 15 callsub numericalcomp_0 -store 22 -load 23 +frame_bury 15 +frame_dig 16 callsub numericalcomp_0 -store 23 -load 24 +frame_bury 16 +frame_dig 17 callsub numericalcomp_0 -store 24 -load 25 +frame_bury 17 +frame_dig 18 callsub numericalcomp_0 -store 25 -load 26 +frame_bury 18 +frame_dig 19 callsub numericalcomp_0 -store 26 -load 27 +frame_bury 19 +frame_dig 20 callsub numericalcomp_0 -store 27 -load 28 +frame_bury 20 +frame_dig 21 callsub numericalcomp_0 -store 28 -load 29 +frame_bury 21 +frame_dig 22 callsub numericalcomp_0 -store 29 -load 30 +frame_bury 22 +frame_dig 23 callsub numericalcomp_0 -store 30 -load 31 +frame_bury 23 +frame_dig 24 callsub numericalcomp_0 -store 31 -load 32 +frame_bury 24 +frame_dig 25 callsub numericalcomp_0 -store 32 -load 33 +frame_bury 25 +frame_dig 26 callsub numericalcomp_0 -store 33 -load 34 +frame_bury 26 +frame_dig 27 callsub numericalcomp_0 -store 34 -load 35 +frame_bury 27 +frame_dig 28 callsub numericalcomp_0 -store 35 -load 36 +frame_bury 28 +frame_dig 29 callsub numericalcomp_0 -store 36 -load 37 +frame_bury 29 +frame_dig 30 callsub numericalcomp_0 -store 37 -load 38 +frame_bury 30 +frame_dig 31 callsub numericalcomp_0 -store 38 -load 39 +frame_bury 31 +frame_dig 32 callsub numericalcomp_0 -store 39 -load 40 +frame_bury 32 +frame_dig 33 callsub numericalcomp_0 -store 40 -load 41 +frame_bury 33 +frame_dig 34 callsub numericalcomp_0 -store 41 -load 42 +frame_bury 34 +frame_dig 35 callsub numericalcomp_0 -store 42 -load 43 +frame_bury 35 +frame_dig 36 callsub numericalcomp_0 -store 43 -load 44 +frame_bury 36 +frame_dig 37 callsub numericalcomp_0 -store 44 -load 45 +frame_bury 37 +frame_dig 38 callsub numericalcomp_0 -store 45 -load 46 +frame_bury 38 +frame_dig 39 callsub numericalcomp_0 -store 46 -load 47 +frame_bury 39 +frame_dig 40 callsub numericalcomp_0 -store 47 -load 48 +frame_bury 40 +frame_dig 41 callsub numericalcomp_0 -store 48 -load 49 +frame_bury 41 +frame_dig 42 callsub numericalcomp_0 -store 49 +frame_bury 42 int 42 -store 50 -load 50 +frame_bury 87 +frame_dig 87 itob extract 6 0 -load 8 +frame_dig 1 itob -load 9 +frame_dig 2 itob concat -load 10 +frame_dig 3 itob concat -load 11 +frame_dig 4 itob concat -load 12 +frame_dig 5 itob concat -load 13 +frame_dig 6 itob concat -load 14 +frame_dig 7 itob concat -load 15 +frame_dig 8 itob concat -load 16 +frame_dig 9 itob concat -load 17 +frame_dig 10 itob concat -load 18 +frame_dig 11 itob concat -load 19 +frame_dig 12 itob concat -load 20 +frame_dig 13 itob concat -load 21 +frame_dig 14 itob concat -load 22 +frame_dig 15 itob concat -load 23 +frame_dig 16 itob concat -load 24 +frame_dig 17 itob concat -load 25 +frame_dig 18 itob concat -load 26 +frame_dig 19 itob concat -load 27 +frame_dig 20 itob concat -load 28 +frame_dig 21 itob concat -load 29 +frame_dig 22 itob concat -load 30 +frame_dig 23 itob concat -load 31 +frame_dig 24 itob concat -load 32 +frame_dig 25 itob concat -load 33 +frame_dig 26 itob concat -load 34 +frame_dig 27 itob concat -load 35 +frame_dig 28 itob concat -load 36 +frame_dig 29 itob concat -load 37 +frame_dig 30 itob concat -load 38 +frame_dig 31 itob concat -load 39 +frame_dig 32 itob concat -load 40 +frame_dig 33 itob concat -load 41 +frame_dig 34 itob concat -load 42 +frame_dig 35 itob concat -load 43 +frame_dig 36 itob concat -load 44 +frame_dig 37 itob concat -load 45 +frame_dig 38 itob concat -load 46 +frame_dig 39 itob concat -load 47 +frame_dig 40 itob concat -load 48 +frame_dig 41 itob concat -load 49 +frame_dig 42 itob concat concat @@ -625,64 +627,67 @@ retsub roundtripper_2: proto 1 1 byte "" +dupn 2 +int 0 +dupn 1 frame_dig -1 callsub arraycomplement_1 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub arraycomplement_1 -store 3 +frame_bury 2 frame_dig -1 -store 7 -load 7 -store 6 +store 3 +load 3 +store 2 int 6 -store 4 -load 4 -load 7 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 +frame_dig 1 +store 3 load 2 -store 7 -load 6 -load 7 -concat -store 6 -load 5 -store 4 -load 4 -load 7 +load 3 +concat +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 +load 3 len + -store 5 -load 5 +frame_bury 4 +frame_dig 4 int 65536 < assert -load 4 +frame_dig 3 itob extract 6 0 concat +frame_dig 2 +store 3 +load 2 load 3 -store 7 -load 6 -load 7 concat -store 6 -load 5 -store 4 -load 4 +store 2 +frame_dig 4 +frame_bury 3 +frame_dig 3 itob extract 6 0 concat -load 6 +load 2 concat frame_bury 0 retsub \ No newline at end of file diff --git a/tests/integration/teal/roundtrip/app_roundtrip_uint64_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_uint64_v8.teal index ce11171f2..6a94f89c3 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_uint64_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_uint64_v8.teal @@ -26,18 +26,20 @@ retsub roundtripper_1: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 callsub numericalcomp_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub numericalcomp_0 -store 3 +frame_bury 2 frame_dig -1 itob -load 2 +frame_dig 1 itob concat -load 3 +frame_dig 2 itob concat frame_bury 0 diff --git a/tests/integration/teal/roundtrip/app_roundtrip_uint8_v8.teal b/tests/integration/teal/roundtrip/app_roundtrip_uint8_v8.teal index c7dfcc09f..58daf6eb2 100644 --- a/tests/integration/teal/roundtrip/app_roundtrip_uint8_v8.teal +++ b/tests/integration/teal/roundtrip/app_roundtrip_uint8_v8.teal @@ -31,24 +31,26 @@ retsub roundtripper_1: proto 1 1 byte "" +int 0 +dupn 3 frame_dig -1 callsub numericalcomp_0 -store 2 -load 2 +frame_bury 1 +frame_dig 1 callsub numericalcomp_0 -store 3 +frame_bury 2 byte 0x00 int 0 frame_dig -1 setbyte byte 0x00 int 0 -load 2 +frame_dig 1 setbyte concat byte 0x00 int 0 -load 3 +frame_dig 2 setbyte concat frame_bury 0