mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 679893 - Move up handling of -D js shell argument so that JSOPTION_PCCOUNTS is set before constructing the initial script for Function class (r=cdleary)
--HG-- extra : rebase_source : 4a075c9091fd0ca6bb66df908360e1c3828be496
This commit is contained in:
parent
fe50c38240
commit
0c99ef82c8
@ -5340,10 +5340,8 @@ ProcessArgs(JSContext *cx, JSObject *obj, OptionParser *op)
|
||||
if (op->getBoolOption('b'))
|
||||
printTiming = true;
|
||||
|
||||
if (op->getBoolOption('D')) {
|
||||
if (op->getBoolOption('D'))
|
||||
enableDisassemblyDumps = true;
|
||||
JS_ToggleOptions(cx, JSOPTION_PCCOUNT);
|
||||
}
|
||||
|
||||
/* |scriptArgs| gets bound on the global before any code is run. */
|
||||
if (!BindScriptArgs(cx, obj, op))
|
||||
@ -5664,6 +5662,10 @@ main(int argc, char **argv, char **envp)
|
||||
JS_SetGCParameter(rt, JSGC_MODE, JSGC_MODE_COMPARTMENT);
|
||||
JS_SetGCParameterForThread(cx, JSGC_MAX_CODE_CACHE_BYTES, 16 * 1024 * 1024);
|
||||
|
||||
/* Must be done before creating the global object */
|
||||
if (op.getBoolOption('D'))
|
||||
JS_ToggleOptions(cx, JSOPTION_PCCOUNT);
|
||||
|
||||
result = Shell(cx, &op, envp);
|
||||
|
||||
#ifdef DEBUG
|
||||
|
Loading…
Reference in New Issue
Block a user