Closed Bug 1429140 Opened 2 years ago Closed 2 years ago

timeout function doesn't work when ion is disabled

Categories

(Core :: JavaScript Engine, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla59
Tracking Status
firefox59 --- fixed

People

(Reporter: terpri, Assigned: lth)

References

Details

Attachments

(1 file)

The JS shell's "timeout" function doesn't work when Ion is disabled (using the "--disable-ion" configure option). For example, "js -e 'timeout(1);sleep(2)'" segfaults in the ContextToPC function from js/src/wasm/WasmSignalHandlers.cpp. This causes test failures that don't happen when the JIT is enabled.
This problem seems to have been present since the non-Ion build was fixed in #1388005.
Assignee: nobody → lhansen
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Disabling signal handling for JS_CODEGEN_NONE makes the test case run (I have a simple patch).  Also, when running jit-tests on a JS_CODEGEN_NONE build that patch changes crash failures into simple test failures, which is at least something.  But there are still quite a few test failures on jit-tests, failures I do not see when running with --no-ion --no-baseline, for example.  So the proper fix is likely to try to make signal handling work properly for the JS_CODEGEN_NONE build.  This seems doable, there are a couple of likely places where we can bypass attempts to identify JIT code (which is what currently fails).
See commit message for technical details.  With this patch, a --disable-ion build passes all jit-tests.
Attachment #8941877 - Flags: review?(luke)
Comment on attachment 8941877 [details] [diff] [review]
bug1429140-non-ion-signal-handling.patch

Review of attachment 8941877 [details] [diff] [review]:
-----------------------------------------------------------------

Thanks!
Attachment #8941877 - Flags: review?(luke) → review+
Pushed by lhansen@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/16740cf93a77
Make signal handling work for --disable-ion builds. r=luke
https://hg.mozilla.org/mozilla-central/rev/16740cf93a77
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla59
Duplicate of this bug: 1426008
You need to log in before you can comment on or make changes to this bug.