mirror of
https://github.com/cocos/cocos4.git
synced 2026-12-06 03:22:39 +08:00
Increase default JS heap to 32 mb
This commit is contained in:
@@ -620,14 +620,14 @@ void ScriptingCore::createGlobalContext() {
|
||||
_jsInited = true;
|
||||
}
|
||||
|
||||
_rt = JS_NewRuntime(8L * 1024L * 1024L);
|
||||
_rt = JS_NewRuntime(32L * 1024L * 1024L);
|
||||
JS_SetGCParameter(_rt, JSGC_MAX_BYTES, 0xffffffff);
|
||||
|
||||
JS_SetTrustedPrincipals(_rt, &shellTrustedPrincipals);
|
||||
JS_SetSecurityCallbacks(_rt, &securityCallbacks);
|
||||
JS_SetNativeStackQuota(_rt, JSB_MAX_STACK_QUOTA);
|
||||
|
||||
_cx = JS_NewContext(_rt, 8192);
|
||||
_cx = JS_NewContext(_rt, 32 * 1024);
|
||||
|
||||
JS::RuntimeOptionsRef(_rt).setIon(true);
|
||||
JS::RuntimeOptionsRef(_rt).setBaseline(true);
|
||||
|
||||
Reference in New Issue
Block a user