author | Yury Delendik <ydelendik@mozilla.com> |
Wed, 18 Jan 2017 12:48:35 -0600 | |
changeset 330021 | 29e806c862faaf43c984c12a2a17dd0053acb852 |
parent 330020 | c4abb503bfcddd2c79f998047bbede6672b6bd0c |
child 330022 | 3544f347daf2af7a48e9f8b4a8ff75181d948041 |
push id | 31229 |
push user | cbook@mozilla.com |
push date | Thu, 19 Jan 2017 15:01:46 +0000 |
treeherder | mozilla-central@168ea3e9ff0b [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
reviewers | luke |
bugs | 1331592 |
milestone | 53.0a1 |
first release with | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
last release without | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
js/src/jit-test/tests/debug/bug1331592.js | file | annotate | diff | comparison | revisions | |
js/src/vm/Stack.cpp | file | annotate | diff | comparison | revisions |
new file mode 100644 --- /dev/null +++ b/js/src/jit-test/tests/debug/bug1331592.js @@ -0,0 +1,28 @@ +// |jit-test| test-also-wasm-baseline; error: TestComplete + +if (!wasmIsSupported()) + throw "TestComplete"; + +var module = new WebAssembly.Module(wasmTextToBinary(` + (module + (import "global" "func" (result i32)) + (func (export "func_0") (result i32) + call 0 ;; calls the import, which is func #0 + ) + ) +`)); + +var dbg; +(function (global) { + var dbgGlobal = newGlobal(); + dbg = new dbgGlobal.Debugger(); + dbg.addDebuggee(global); +})(this); + +var instance = new WebAssembly.Instance(module, { global: { func: () => { + var frame = dbg.getNewestFrame().older; + frame.eval("some_error"); +}}}); +instance.exports.func_0(); + +throw "TestComplete";
--- a/js/src/vm/Stack.cpp +++ b/js/src/vm/Stack.cpp @@ -703,16 +703,18 @@ FrameIter::operator++() { AbstractFramePtr eifPrev = interpFrame()->evalInFramePrev(); popInterpreterFrame(); while (!hasUsableAbstractFramePtr() || abstractFramePtr() != eifPrev) { if (data_.state_ == JIT) popJitFrame(); + else if (data_.state_ == WASM) + popWasmFrame(); else popInterpreterFrame(); } break; } popInterpreterFrame(); break;