diff options
Diffstat (limited to 'patio-to-cranelift/src/patio/instructions.rs')
| -rw-r--r-- | patio-to-cranelift/src/patio/instructions.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/patio-to-cranelift/src/patio/instructions.rs b/patio-to-cranelift/src/patio/instructions.rs index fa8d098b..e9a3824e 100644 --- a/patio-to-cranelift/src/patio/instructions.rs +++ b/patio-to-cranelift/src/patio/instructions.rs @@ -17,6 +17,9 @@ pub(crate) enum PatioInstruction { IntToBool(PatioIntToBool), IntToDataPtr(PatioIntToDataPtr), LocalStore(PatioLocalStore), + Loop(PatioLoop), + LoopBreak(PatioLoopBreak), + LoopContinue(PatioLoopContinue), MemoryLoad(PatioMemoryLoad), MemoryStore(PatioMemoryStore), Resume(PatioResume), @@ -100,6 +103,14 @@ pub(crate) struct PatioLocalStore { pub(crate) value: PatioOperand, } +pub(crate) struct PatioLoop { + pub(crate) body: Vec<PatioInstruction>, +} + +pub(crate) struct PatioLoopBreak; + +pub(crate) struct PatioLoopContinue; + pub(crate) struct PatioMemoryLoad { pub(crate) destination: PatioLocalRef, pub(crate) pointer: PatioOperand, |
