mirror of
https://github.com/Samsung/escargot.git
synced 2026-06-29 10:02:14 +00:00
Implement general tail call optimization
Signed-off-by: HyukWoo Park <hyukwoo.park@samsung.com>
This commit is contained in:
parent
65558531f8
commit
023b7ea014
27 changed files with 368 additions and 89 deletions
|
|
@ -31,6 +31,9 @@
|
|||
#include "runtime/ReloadableString.h"
|
||||
#include "intl/Intl.h"
|
||||
#include "interpreter/ByteCode.h"
|
||||
#if defined(ENABLE_TCO)
|
||||
#include "interpreter/ByteCodeInterpreter.h"
|
||||
#endif
|
||||
#if defined(ENABLE_CODE_CACHE)
|
||||
#include "codecache/CodeCache.h"
|
||||
#endif
|
||||
|
|
@ -398,7 +401,6 @@ VMInstance::VMInstance(const char* locale, const char* timezone, const char* bas
|
|||
}
|
||||
#endif
|
||||
|
||||
|
||||
// add gc event callback
|
||||
GCEventListenerSet& list = ThreadLocal::gcEventListenerSet();
|
||||
list.ensureMarkStartListeners()->push_back(std::make_pair(vmMarkStartCallback, this));
|
||||
|
|
@ -480,6 +482,12 @@ VMInstance::VMInstance(const char* locale, const char* timezone, const char* bas
|
|||
|
||||
m_jobQueue = new JobQueue();
|
||||
|
||||
#if defined(ENABLE_TCO)
|
||||
if (!Interpreter::tcoBuffer) {
|
||||
Interpreter::initTCOBuffer();
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined(ENABLE_CODE_CACHE)
|
||||
if (UNLIKELY(!baseCacheDir || strlen(baseCacheDir) == 0)) {
|
||||
const char* homeDir = getenv("HOME");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue