mirror of
https://github.com/Samsung/escargot.git
synced 2026-06-29 10:02:14 +00:00
Implement per thread isolating
Signed-off-by: Seonghyun Kim <sh8281.kim@samsung.com>
This commit is contained in:
parent
ac2bb84b6f
commit
77a68579a5
59 changed files with 228 additions and 205 deletions
|
|
@ -38,8 +38,8 @@ StringObject::StringObject(ExecutionState& state, Object* proto, String* value)
|
|||
|
||||
void* StringObject::operator new(size_t size)
|
||||
{
|
||||
static bool typeInited = false;
|
||||
static GC_descr descr;
|
||||
static MAY_THREAD_LOCAL bool typeInited = false;
|
||||
static MAY_THREAD_LOCAL GC_descr descr;
|
||||
if (!typeInited) {
|
||||
GC_word obj_bitmap[GC_BITMAP_SIZE(StringObject)] = { 0 };
|
||||
Object::fillGCDescriptor(obj_bitmap);
|
||||
|
|
@ -135,8 +135,8 @@ StringIteratorObject::StringIteratorObject(ExecutionState& state, String* s)
|
|||
|
||||
void* StringIteratorObject::operator new(size_t size)
|
||||
{
|
||||
static bool typeInited = false;
|
||||
static GC_descr descr;
|
||||
static MAY_THREAD_LOCAL bool typeInited = false;
|
||||
static MAY_THREAD_LOCAL GC_descr descr;
|
||||
if (!typeInited) {
|
||||
GC_word obj_bitmap[GC_BITMAP_SIZE(StringIteratorObject)] = { 0 };
|
||||
Object::fillGCDescriptor(obj_bitmap);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue