mirror of
https://github.com/Samsung/escargot.git
synced 2026-06-22 10:01:50 +00:00
1. replace LoadByStackIndex, StoreByStackIndex with Move opcode
2. generate more optimized byte code in for, if, assignment, update AST node Signed-off-by: seonghyun kim <sh8281.kim@samsung.com>
This commit is contained in:
parent
f27adc4dad
commit
974e986e76
30 changed files with 176 additions and 147 deletions
|
|
@ -49,7 +49,7 @@ Value Script::execute(ExecutionState& state, bool isEvalMode, bool needNewEnv, b
|
|||
Value* stackStorage = registerFile + m_topCodeBlock->byteCodeBlock()->m_requiredRegisterFileSizeInValueSize;
|
||||
stackStorage[0] = thisValue;
|
||||
clearStack<512>();
|
||||
ByteCodeInterpreter::interpret(newState, m_topCodeBlock->byteCodeBlock(), 0, registerFile, stackStorage);
|
||||
ByteCodeInterpreter::interpret(newState, m_topCodeBlock->byteCodeBlock(), 0, registerFile);
|
||||
|
||||
return resultValue;
|
||||
}
|
||||
|
|
@ -120,7 +120,7 @@ Value Script::executeLocal(ExecutionState& state, Value thisValue, bool isEvalMo
|
|||
stackStorage[m_topCodeBlock->thisSymbolIndex()] = thisValue;
|
||||
|
||||
clearStack<512>();
|
||||
ByteCodeInterpreter::interpret(newState, m_topCodeBlock->byteCodeBlock(), 0, registerFile, stackStorage);
|
||||
ByteCodeInterpreter::interpret(newState, m_topCodeBlock->byteCodeBlock(), 0, registerFile);
|
||||
|
||||
return resultValue;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue