1. add FUNCTION_OBJECT_BYTECODE_SIZE_MAX as config flag

2. divide CodeBlock into CodeBlock and InterpretedCodeBlock for saving memory
3. expand SCANNER_RESULT_POOL_INITIAL_SIZE to 128
4. connect String -> AtomicString with remaining space of String::m_tag
5. optimize Function.bind

Signed-off-by: seonghyun kim <sh8281.kim@samsung.com>
This commit is contained in:
seonghyun kim 2017-04-13 21:39:03 +09:00
commit a98bf4ec1b
45 changed files with 622 additions and 588 deletions

View file

@ -43,7 +43,7 @@ Value Script::execute(ExecutionState& state, bool isEvalMode, bool needNewEnv, b
LexicalEnvironment* env;
ExecutionContext* prevEc;
{
CodeBlock* globalCodeBlock = (needNewEnv) ? nullptr : m_topCodeBlock;
InterpretedCodeBlock* globalCodeBlock = (needNewEnv) ? nullptr : m_topCodeBlock;
LexicalEnvironment* globalEnvironment = new LexicalEnvironment(new GlobalEnvironmentRecord(state, globalCodeBlock, state.context()->globalObject(), isEvalMode), nullptr);
if (UNLIKELY(needNewEnv)) {
// NOTE: ES5 10.4.2.1 eval in strict mode
@ -103,7 +103,7 @@ Script::ScriptSandboxExecuteResult Script::sandboxExecute(ExecutionState& state)
}
// NOTE: eval by direct call
Value Script::executeLocal(ExecutionState& state, Value thisValue, CodeBlock* parentCodeBlock, bool isEvalMode, bool needNewRecord)
Value Script::executeLocal(ExecutionState& state, Value thisValue, InterpretedCodeBlock* parentCodeBlock, bool isEvalMode, bool needNewRecord)
{
Node* programNode = m_topCodeBlock->cachedASTNode();
ASSERT(programNode && programNode->type() == ASTNodeType::Program);