summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/debug
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@gmail.com>2017-08-15 20:12:03 +0200
committerwolfbeast <mcwerewolf@gmail.com>2018-02-08 10:14:22 +0100
commitf7f35438f5e257575ea2b7a430c58e458ae56b4e (patch)
tree457debe0b64e67fd2ac05498fb8efe02bbce979d /js/src/jit-test/tests/debug
parentd773eca3316f2c99db9a1dd77929bcbd157eeacb (diff)
downloadUXP-f7f35438f5e257575ea2b7a430c58e458ae56b4e.tar
UXP-f7f35438f5e257575ea2b7a430c58e458ae56b4e.tar.gz
UXP-f7f35438f5e257575ea2b7a430c58e458ae56b4e.tar.lz
UXP-f7f35438f5e257575ea2b7a430c58e458ae56b4e.tar.xz
UXP-f7f35438f5e257575ea2b7a430c58e458ae56b4e.zip
Add rematerialized frames to the table on JitActivation after rematerialization succeeds.
Diffstat (limited to 'js/src/jit-test/tests/debug')
-rw-r--r--js/src/jit-test/tests/debug/bug1353356.js65
1 files changed, 65 insertions, 0 deletions
diff --git a/js/src/jit-test/tests/debug/bug1353356.js b/js/src/jit-test/tests/debug/bug1353356.js
new file mode 100644
index 000000000..389bb7860
--- /dev/null
+++ b/js/src/jit-test/tests/debug/bug1353356.js
@@ -0,0 +1,65 @@
+// |jit-test| allow-oom; --fuzzing-safe
+
+var lfLogBuffer = `
+//corefuzz-dcd-endofdata
+//corefuzz-dcd-endofdata
+//corefuzz-dcd-endofdata
+ setJitCompilerOption("ion.warmup.trigger", 4);
+ var g = newGlobal();
+ g.debuggeeGlobal = this;
+ g.eval("(" + function () {
+ dbg = new Debugger(debuggeeGlobal);
+ dbg.onExceptionUnwind = function (frame, exc) {
+ var s = '!';
+ for (var f = frame; f; f = f.older)
+ debuggeeGlobal.log += s;
+ };
+ } + ")();");
+ j('Number.prototype.toSource.call([])');
+//corefuzz-dcd-endofdata
+//corefuzz-dcd-endofdata
+//corefuzz-dcd-endofdata
+//corefuzz-dcd-selectmode 4
+//corefuzz-dcd-endofdata
+}
+//corefuzz-dcd-endofdata
+//corefuzz-dcd-selectmode 5
+//corefuzz-dcd-endofdata
+oomTest(() => i({
+ new : (true ),
+ thisprops: true
+}));
+`;
+lfLogBuffer = lfLogBuffer.split('\n');
+var lfRunTypeId = -1;
+var lfCodeBuffer = "";
+while (true) {
+ var line = lfLogBuffer.shift();
+ if (line == null) {
+ break;
+ } else if (line == "//corefuzz-dcd-endofdata") {
+ loadFile(lfCodeBuffer);
+ lfCodeBuffer = "";
+ loadFile(line);
+ } else {
+ lfCodeBuffer += line + "\n";
+ }
+}
+if (lfCodeBuffer) loadFile(lfCodeBuffer);
+function loadFile(lfVarx) {
+ try {
+ if (lfVarx.indexOf("//corefuzz-dcd-selectmode ") === 0) {
+ lfRunTypeId = parseInt(lfVarx.split(" ")[1]) % 6;
+ } else {
+ switch (lfRunTypeId) {
+ case 4:
+ oomTest(function() {
+ let m = parseModule(lfVarx);
+ });
+ break;
+ default:
+ evaluate(lfVarx);
+ }
+ }
+ } catch (lfVare) {}
+}