Index: src/interpreter/bytecodes.h |
diff --git a/src/interpreter/bytecodes.h b/src/interpreter/bytecodes.h |
index a3dc8220e40293380e1b543a788857cf13ce06d9..a146241a49b46153cb45d5adfa1929fd830bc7ea 100644 |
--- a/src/interpreter/bytecodes.h |
+++ b/src/interpreter/bytecodes.h |
@@ -43,8 +43,12 @@ namespace interpreter { |
V(LdaTrue, OperandType::kNone) \ |
V(LdaFalse, OperandType::kNone) \ |
\ |
- /* Load globals */ \ |
+ /* Globals */ \ |
V(LdaGlobal, OperandType::kIdx8) \ |
+ V(StaGlobal, OperandType::kIdx8) \ |
+ \ |
+ /* Context operations */ \ |
+ V(LdaContextSlot, OperandType::kReg8, OperandType::kIdx8) \ |
\ |
/* Register-accumulator transfers */ \ |
V(Ldar, OperandType::kReg8) \ |
@@ -163,6 +167,10 @@ class Register { |
int ToParameterIndex(int parameter_count) const; |
static int MaxParameterIndex(); |
+ // Returns the register for the function's outer context. |
+ static Register function_context(); |
+ bool is_function_context() const; |
+ |
static Register FromOperand(uint8_t operand); |
uint8_t ToOperand() const; |