diff options
Diffstat (limited to 'include/ssa')
-rw-r--r-- | include/ssa/ssa.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/include/ssa/ssa.h b/include/ssa/ssa.h index ed147bf..9d6949d 100644 --- a/include/ssa/ssa.h +++ b/include/ssa/ssa.h @@ -28,7 +28,8 @@ typedef enum { SSA_CALL_EXTERN, SSA_JUMP_ZERO, SSA_JUMP, - SSA_RET + SSA_RET, + SSA_LABEL } SsaInstruction; typedef enum { @@ -61,6 +62,7 @@ typedef u16 SsaStringIndex; typedef u16 SsaExternFuncIndex; typedef u16 SsaExportFuncIndex; typedef u16 SsaFuncIndex; +typedef u16 SsaLabelIndex; typedef struct { Buffer/*instruction data*/ instructions; @@ -78,6 +80,7 @@ typedef struct { SsaRegister reg_counter; SsaRegister param_counter; SsaFuncIndex func_counter; + SsaLabelIndex label_counter; Parser *parser; /* Borrowed */ } Ssa; @@ -111,11 +114,11 @@ typedef struct { typedef struct { SsaRegister condition_reg; - JumpOffset jump_offset; + SsaLabelIndex target_label; } SsaInsJumpZero; typedef struct { - JumpOffset jump_offset; + SsaLabelIndex target_label; } SsaInsJump; /* None of these functions are thread-safe */ |