Closed
Bug 1716324
Opened 3 years ago
Closed 3 years ago
Call JS_SetNativeStackQuota when creating the JSContext
Categories
(Core :: JavaScript Engine, task, P3)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
91 Branch
Tracking | Status | |
---|---|---|
firefox91 | --- | fixed |
People
(Reporter: jandem, Assigned: jandem)
References
(Blocks 1 open bug)
Details
Attachments
(2 files)
Not calling JS_SetNativeStackQuota
can result in weird behavior. I think this is because we initialize jitStackLimit
and jitStackLimitNoInterrupt
to UINTPTR_MAX
.
We should probably just call this with a value of 128 KB or so when we initialize the JSContext. Embedders can still override it, of course, but if they forget to call JS_SetNativeStackQuota
they'd still get reasonable behavior.
Assignee | ||
Updated•3 years ago
|
Flags: needinfo?(jdemooij)
Updated•3 years ago
|
Blocks: sm-embedding
Assignee | ||
Comment 1•3 years ago
|
||
Uses the stack limit values currently used for the JS shell. This fixes confusing
behavior when the embedding forgets to call JS_SetNativeStackQuota.
Assignee | ||
Comment 2•3 years ago
|
||
Depends on D117655
Updated•3 years ago
|
Attachment #9226830 -
Attachment description: Bug 1716324 part 2 - Rely on default stack size for jsapi-tests, gdb-test and JS shell main thread. r?tcampbell! → Bug 1716324 part 2 - Rely on default stack size for jsapi-tests, gdb-tests, and JS shell main thread. r?tcampbell!
Assignee | ||
Updated•3 years ago
|
Flags: needinfo?(jdemooij)
Pushed by jdemooij@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/d2aa7be66c9c
part 1 - Set default stack quota when creating the JSContext. r=tcampbell
https://hg.mozilla.org/integration/autoland/rev/0b62a8d087fd
part 2 - Rely on default stack size for jsapi-tests, gdb-tests, and JS shell main thread. r=tcampbell
Comment 4•3 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/d2aa7be66c9c
https://hg.mozilla.org/mozilla-central/rev/0b62a8d087fd
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
status-firefox91:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 91 Branch
You need to log in
before you can comment on or make changes to this bug.
Description
•