summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/jaeger/inline
diff options
context:
space:
mode:
authorMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
committerMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
commit5f8de423f190bbb79a62f804151bc24824fa32d8 (patch)
tree10027f336435511475e392454359edea8e25895d /js/src/jit-test/tests/jaeger/inline
parent49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff)
downloadUXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip
Add m-esr52 at 52.6.0
Diffstat (limited to 'js/src/jit-test/tests/jaeger/inline')
-rw-r--r--js/src/jit-test/tests/jaeger/inline/bug645645.js4
-rw-r--r--js/src/jit-test/tests/jaeger/inline/bug645666.js16
-rw-r--r--js/src/jit-test/tests/jaeger/inline/bug646004.js9
-rw-r--r--js/src/jit-test/tests/jaeger/inline/bug646480.js7
-rw-r--r--js/src/jit-test/tests/jaeger/inline/bug647973.js11
-rw-r--r--js/src/jit-test/tests/jaeger/inline/bug651209.js11
-rw-r--r--js/src/jit-test/tests/jaeger/inline/bug655954.js5
-rw-r--r--js/src/jit-test/tests/jaeger/inline/bug656221.js5
-rw-r--r--js/src/jit-test/tests/jaeger/inline/bug676491.js14
-rw-r--r--js/src/jit-test/tests/jaeger/inline/bug680759.js14
-rw-r--r--js/src/jit-test/tests/jaeger/inline/doubleArg.js10
-rw-r--r--js/src/jit-test/tests/jaeger/inline/mathAbs.js31
-rw-r--r--js/src/jit-test/tests/jaeger/inline/mathFloor.js34
-rw-r--r--js/src/jit-test/tests/jaeger/inline/mathPow.js35
-rw-r--r--js/src/jit-test/tests/jaeger/inline/mathRound.js41
-rw-r--r--js/src/jit-test/tests/jaeger/inline/mathSqrt.js29
-rw-r--r--js/src/jit-test/tests/jaeger/inline/scripted-01.js17
-rw-r--r--js/src/jit-test/tests/jaeger/inline/scripted-02.js22
-rw-r--r--js/src/jit-test/tests/jaeger/inline/scripted-03.js14
-rw-r--r--js/src/jit-test/tests/jaeger/inline/scripted-04.js12
-rw-r--r--js/src/jit-test/tests/jaeger/inline/scripted-05.js13
-rw-r--r--js/src/jit-test/tests/jaeger/inline/scripted-06.js17
-rw-r--r--js/src/jit-test/tests/jaeger/inline/scripted-07.js15
-rw-r--r--js/src/jit-test/tests/jaeger/inline/scripted-08.js21
-rw-r--r--js/src/jit-test/tests/jaeger/inline/scripted-09.js19
-rw-r--r--js/src/jit-test/tests/jaeger/inline/scripted-10.js13
-rw-r--r--js/src/jit-test/tests/jaeger/inline/scripted-11.js12
-rw-r--r--js/src/jit-test/tests/jaeger/inline/stringCharAt.js49
-rw-r--r--js/src/jit-test/tests/jaeger/inline/stringCharCodeAt.js47
-rw-r--r--js/src/jit-test/tests/jaeger/inline/undefinedLocal.js19
30 files changed, 566 insertions, 0 deletions
diff --git a/js/src/jit-test/tests/jaeger/inline/bug645645.js b/js/src/jit-test/tests/jaeger/inline/bug645645.js
new file mode 100644
index 000000000..6649b559e
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/bug645645.js
@@ -0,0 +1,4 @@
+function f() {
+ f = Math.x;
+}
+f();
diff --git a/js/src/jit-test/tests/jaeger/inline/bug645666.js b/js/src/jit-test/tests/jaeger/inline/bug645666.js
new file mode 100644
index 000000000..34fd6822a
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/bug645666.js
@@ -0,0 +1,16 @@
+function f1() {
+ gc();
+}
+function f2() {
+ with(this) {};
+ f1();
+}
+function f3() {
+ f2();
+}
+function f4() {
+ f3();
+}
+f3();
+f3();
+f4();
diff --git a/js/src/jit-test/tests/jaeger/inline/bug646004.js b/js/src/jit-test/tests/jaeger/inline/bug646004.js
new file mode 100644
index 000000000..8ffb4bd55
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/bug646004.js
@@ -0,0 +1,9 @@
+function reportCompare (expected, actual, description) {}
+function f()
+{
+ f(f, 0x09AA, 0x09B0, f);
+}
+try {
+ reportCompare ("outer", f(),
+ "Inner function statement should not have been called.");
+} catch (e) {}
diff --git a/js/src/jit-test/tests/jaeger/inline/bug646480.js b/js/src/jit-test/tests/jaeger/inline/bug646480.js
new file mode 100644
index 000000000..e870e33ef
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/bug646480.js
@@ -0,0 +1,7 @@
+if (true)
+ function f1() {};
+function f2() {
+ var y = -8;
+ return y % 2;
+}
+f2() / 3;
diff --git a/js/src/jit-test/tests/jaeger/inline/bug647973.js b/js/src/jit-test/tests/jaeger/inline/bug647973.js
new file mode 100644
index 000000000..c19797a24
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/bug647973.js
@@ -0,0 +1,11 @@
+function f(a1, a2, a3, a4) {
+}
+function g(a1, a2) {
+ var d = new Date(0);
+ f();
+ assertEq(typeof d, 'object');
+}
+g();
+gc();
+f(2, 2, 2, f(2, 2, 2, 12 === 12));
+g(false, false);
diff --git a/js/src/jit-test/tests/jaeger/inline/bug651209.js b/js/src/jit-test/tests/jaeger/inline/bug651209.js
new file mode 100644
index 000000000..27e14a17b
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/bug651209.js
@@ -0,0 +1,11 @@
+var i = 0;
+try { test(); } catch (e) { }
+function test() {
+ var jstop = 900;
+ var code = '';
+ code+=createCode(i);
+ eval();
+}
+function createCode(i) {
+ jstop+= + + + i + " string.';";
+}
diff --git a/js/src/jit-test/tests/jaeger/inline/bug655954.js b/js/src/jit-test/tests/jaeger/inline/bug655954.js
new file mode 100644
index 000000000..f57488b95
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/bug655954.js
@@ -0,0 +1,5 @@
+// |jit-test| error: TypeError
+foo();
+function foo() {
+ this();
+}
diff --git a/js/src/jit-test/tests/jaeger/inline/bug656221.js b/js/src/jit-test/tests/jaeger/inline/bug656221.js
new file mode 100644
index 000000000..8319bcf83
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/bug656221.js
@@ -0,0 +1,5 @@
+function f() {
+ var a = [];
+ a.push(a);
+}
+f();
diff --git a/js/src/jit-test/tests/jaeger/inline/bug676491.js b/js/src/jit-test/tests/jaeger/inline/bug676491.js
new file mode 100644
index 000000000..82e6095a0
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/bug676491.js
@@ -0,0 +1,14 @@
+Array.prototype.__defineSetter__(32, function() { print("Hello from arbitrary JS");});
+var UBound = 0;
+var expect= '';
+var expectedvalues = [];
+for (var j=0; j < 10; j++) {
+ addThis();
+ addThis();
+ addThis();
+ addThis();
+}
+function addThis() {
+ expectedvalues[UBound] = expect;
+ UBound++;
+}
diff --git a/js/src/jit-test/tests/jaeger/inline/bug680759.js b/js/src/jit-test/tests/jaeger/inline/bug680759.js
new file mode 100644
index 000000000..975f9e3b7
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/bug680759.js
@@ -0,0 +1,14 @@
+
+TryToCatch();
+TryToCatch();
+function Thrower( v ) {
+ throw "Caught";
+}
+function Eval( v ) {
+ SECTION : Thrower(TryToCatch, v, ': 3')
+}
+function TryToCatch( value, expect ) {
+ try {
+ Eval( value )
+ } catch (e) { }
+}
diff --git a/js/src/jit-test/tests/jaeger/inline/doubleArg.js b/js/src/jit-test/tests/jaeger/inline/doubleArg.js
new file mode 100644
index 000000000..bd4422599
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/doubleArg.js
@@ -0,0 +1,10 @@
+function foo(x, y) {
+ if (y < 0) {}
+ return x * 1000;
+}
+function bar(x, y) {
+ while (false) {}
+ assertEq(foo(x, false), 10500);
+ assertEq(foo(y, false), 11000);
+}
+bar(10.5, 11);
diff --git a/js/src/jit-test/tests/jaeger/inline/mathAbs.js b/js/src/jit-test/tests/jaeger/inline/mathAbs.js
new file mode 100644
index 000000000..b1d077add
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/mathAbs.js
@@ -0,0 +1,31 @@
+
+assertEq(Math.abs(-10), 10);
+assertEq(Math.abs(-2147483648), 2147483648);
+assertEq(Math.abs(2147483648), 2147483648);
+assertEq(Math.abs(-0), 0);
+assertEq(Math.abs(0), 0);
+assertEq(Math.abs(-3.14), 3.14);
+assertEq(Math.abs(NaN), NaN);
+
+/* Inferred as abs(int). */
+function abs1(x) {
+ return Math.abs(x);
+}
+assertEq(abs1(1), 1);
+assertEq(abs1(-1), 1);
+assertEq(abs1(0), 0);
+assertEq(abs1(-123) + abs1(234), 357);
+assertEq(abs1(-2147483648), 2147483648); // recompile to return double
+assertEq(abs1(-2), 2);
+
+/* Inferred as abs(double). */
+function abs2(x) {
+ return Math.abs(x);
+}
+assertEq(abs2(-2.2), 2.2);
+assertEq(abs2(123), 123);
+assertEq(abs2(-456), 456);
+assertEq(abs2(-0), 0);
+assertEq(abs2(1.3), 1.3);
+assertEq(abs2(NaN), NaN);
+
diff --git a/js/src/jit-test/tests/jaeger/inline/mathFloor.js b/js/src/jit-test/tests/jaeger/inline/mathFloor.js
new file mode 100644
index 000000000..1419beb9f
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/mathFloor.js
@@ -0,0 +1,34 @@
+
+assertEq(Math.floor(3.14), 3);
+assertEq(Math.floor(-0), -0);
+assertEq(Math.floor(0), 0);
+assertEq(Math.floor(-1.23), -2);
+assertEq(Math.floor(2147483649), 2147483649);
+assertEq(Math.floor(2147483648.5), 2147483648);
+assertEq(Math.floor(2147483647.1), 2147483647);
+
+/* Inferred as floor(double). */
+function floor1(x) {
+ return Math.floor(x);
+}
+assertEq(floor1(10.3), 10);
+assertEq(floor1(-3.14), -4);
+assertEq(floor1(-0), -0); // recompile to return double
+assertEq(floor1(678.3), 678);
+
+/* Inferred as floor(double). */
+function floor2(x) {
+ return Math.floor(x);
+}
+assertEq(floor2(3.4), 3);
+assertEq(floor2(NaN), NaN); // recompile to return double
+assertEq(floor2(-4.4), -5);
+
+/* Inferred as floor(int). */
+function floor3(x) {
+ return Math.floor(x);
+}
+assertEq(floor3(4), 4);
+assertEq(floor3(-5), -5);
+assertEq(floor3(0), 0);
+
diff --git a/js/src/jit-test/tests/jaeger/inline/mathPow.js b/js/src/jit-test/tests/jaeger/inline/mathPow.js
new file mode 100644
index 000000000..717e087c9
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/mathPow.js
@@ -0,0 +1,35 @@
+
+assertEq(Math.pow(100, 2), 10000);
+assertEq(Math.pow(-Infinity, -0.5), 0);
+assertEq(Math.pow(-Infinity, 0.5), Infinity);
+assertEq(Math.pow(Infinity, -0.5), 0);
+assertEq(Math.pow(Infinity, 0.5), Infinity);
+assertEq(Math.pow(NaN, -0.5), NaN);
+assertEq(Math.pow(NaN, 0.5), NaN);
+assertEq(Math.pow(-3.14, -0.5), NaN);
+assertEq(Math.pow(-1.23, 0.5), NaN);
+assertEq(Math.pow(-0, -0.5), Infinity);
+assertEq(Math.pow(-0, 0.5), 0);
+assertEq(Math.pow(-1, -0.5), NaN);
+assertEq(Math.pow(-1, 0.5), NaN);
+assertEq(Math.pow(0, -0.5), Infinity);
+assertEq(Math.pow(0, 0.5), 0);
+assertEq(Math.pow(1, -0.5), 1);
+assertEq(Math.pow(1, 0.5), 1);
+assertEq(Math.pow(100, -0.5), 0.1);
+assertEq(Math.pow(100, 0.5), 10);
+
+/* Inferred as pow(double, double). */
+function pow1(x) {
+ return Math.pow(x, 0.5);
+}
+assertEq(pow1(100), 10);
+assertEq(pow1(144), 12);
+assertEq(pow1(-0), 0);
+assertEq(pow1(0), 0);
+assertEq(pow1(1), 1);
+assertEq(pow1(-1), NaN);
+assertEq(pow1(NaN), NaN);
+assertEq(pow1(-Infinity), Infinity);
+assertEq(pow1(Infinity), Infinity);
+
diff --git a/js/src/jit-test/tests/jaeger/inline/mathRound.js b/js/src/jit-test/tests/jaeger/inline/mathRound.js
new file mode 100644
index 000000000..60a59e202
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/mathRound.js
@@ -0,0 +1,41 @@
+
+assertEq(Math.round(3.14), 3);
+assertEq(Math.round(0.5), 1);
+assertEq(Math.round(-0), -0);
+assertEq(Math.round(0), 0);
+assertEq(Math.round(-1.03), -1);
+assertEq(Math.round(2147483649), 2147483649);
+assertEq(Math.round(2147483647.5), 2147483648);
+assertEq(Math.floor(2147483647.1), 2147483647);
+
+/* Inferred as round(double). */
+function round1(x) {
+ return Math.round(x);
+}
+assertEq(round1(10.3), 10);
+assertEq(round1(-3.14), -3);
+assertEq(round1(-3.5), -3);
+assertEq(round1(-3.6), -4);
+assertEq(round1(3.5), 4);
+assertEq(round1(3.6), 4);
+assertEq(round1(0), 0);
+assertEq(round1(-0), -0); // recompile to return double
+assertEq(round1(12345), 12345);
+assertEq(round1(654.6), 655);
+
+/* Inferred as round(double). */
+function round2(x) {
+ return Math.round(x);
+}
+assertEq(round2(1234.5), 1235);
+assertEq(round2(NaN), NaN); // recompile to return double
+assertEq(round2(4.6), 5);
+
+/* Inferred as round(int). */
+function round3(x) {
+ return Math.round(x);
+}
+assertEq(round3(4), 4);
+assertEq(round3(-5), -5);
+assertEq(round3(0), 0);
+
diff --git a/js/src/jit-test/tests/jaeger/inline/mathSqrt.js b/js/src/jit-test/tests/jaeger/inline/mathSqrt.js
new file mode 100644
index 000000000..340149942
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/mathSqrt.js
@@ -0,0 +1,29 @@
+
+assertEq(Math.sqrt(-Infinity), NaN);
+assertEq(Math.sqrt(-3.14), NaN);
+assertEq(Math.sqrt(-2), NaN);
+assertEq(Math.sqrt(-0), -0);
+assertEq(Math.sqrt(0), 0);
+assertEq(Math.sqrt(2), Math.SQRT2);
+assertEq(Math.sqrt(49), 7);
+assertEq(Math.sqrt(Infinity), Infinity);
+
+/* Inferred as sqrt(double). */
+function sqrt1(x) {
+ return Math.sqrt(x);
+}
+assertEq(sqrt1(NaN), NaN);
+assertEq(sqrt1(-Infinity), NaN);
+assertEq(sqrt1(Infinity), Infinity);
+assertEq(sqrt1(-0), -0);
+assertEq(sqrt1(2), Math.SQRT2);
+assertEq(sqrt1(16), 4);
+
+/* Inferred as sqrt(int). */
+function sqrt2(x) {
+ return Math.sqrt(x);
+}
+assertEq(sqrt2(4), 2);
+assertEq(sqrt2(169), 13);
+assertEq(sqrt2(0), 0);
+
diff --git a/js/src/jit-test/tests/jaeger/inline/scripted-01.js b/js/src/jit-test/tests/jaeger/inline/scripted-01.js
new file mode 100644
index 000000000..f6a585d05
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/scripted-01.js
@@ -0,0 +1,17 @@
+function bar(x, y) {
+ return x + y;
+}
+
+function foo(x, y) {
+ var a = 0;
+ for (var i = 0; i < 1000; i++) {
+ a += bar(x, y);
+ a += bar(x, y);
+ a += bar(x, y);
+ a += bar(x, y);
+ }
+ return a;
+}
+
+var q = foo(0, 1);
+assertEq(q, 4000);
diff --git a/js/src/jit-test/tests/jaeger/inline/scripted-02.js b/js/src/jit-test/tests/jaeger/inline/scripted-02.js
new file mode 100644
index 000000000..fede7f494
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/scripted-02.js
@@ -0,0 +1,22 @@
+function getter(a, i) {
+ return a[i];
+}
+
+function foo(a, n) {
+ var res = 0;
+ for (var i = 0; i < 10; i++) {
+ res = 0;
+ for (var j = 0; j < n; j++) {
+ res += getter(a, j);
+ }
+ }
+ return res;
+}
+
+var n = 100;
+var a = Array(n);
+for (var i = 0; i < n; i++)
+ a[i] = i;
+
+var q = foo(a, n);
+assertEq(q, 4950);
diff --git a/js/src/jit-test/tests/jaeger/inline/scripted-03.js b/js/src/jit-test/tests/jaeger/inline/scripted-03.js
new file mode 100644
index 000000000..f54c1c66d
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/scripted-03.js
@@ -0,0 +1,14 @@
+function choose(x, y, z) {
+ return x ? y : z;
+}
+
+function foo(x, y, z) {
+ var a = 0;
+ for (var i = 0; i < 100; i++) {
+ a += choose(x, y, z);
+ }
+ return a;
+}
+
+var q = foo(true, 10, 0);
+assertEq(q, 1000);
diff --git a/js/src/jit-test/tests/jaeger/inline/scripted-04.js b/js/src/jit-test/tests/jaeger/inline/scripted-04.js
new file mode 100644
index 000000000..d2f8535bc
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/scripted-04.js
@@ -0,0 +1,12 @@
+function adder(x, y) {
+ return x + y;
+}
+
+function foo(x) {
+ for (var i = 0; i < 100; i++)
+ var a = adder(x, i);
+ return a;
+}
+
+var q = foo(0x7ffffff0);
+assertEq(q, 2147483731);
diff --git a/js/src/jit-test/tests/jaeger/inline/scripted-05.js b/js/src/jit-test/tests/jaeger/inline/scripted-05.js
new file mode 100644
index 000000000..b763fb364
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/scripted-05.js
@@ -0,0 +1,13 @@
+function adder(x, y) {
+ return Math.floor(x + y);
+}
+
+function foo(x) {
+ for (var i = 0; i < 100; i++) {
+ var a = adder(x, i);
+ }
+ return a;
+}
+
+var q = foo(0x7ffffff0 + .5);
+assertEq(q, 2147483731);
diff --git a/js/src/jit-test/tests/jaeger/inline/scripted-06.js b/js/src/jit-test/tests/jaeger/inline/scripted-06.js
new file mode 100644
index 000000000..074bb5201
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/scripted-06.js
@@ -0,0 +1,17 @@
+function popper(a) {
+ return a.pop();
+}
+
+function foo(x) {
+ for (var i = 0; i < 10; i++) {
+ var q = popper(x);
+ if (i < 5)
+ assertEq(q, 5 - i);
+ else
+ assertEq(q, undefined);
+ }
+ return q;
+}
+
+var q = foo([1,2,3,4,5]);
+assertEq(q, undefined);
diff --git a/js/src/jit-test/tests/jaeger/inline/scripted-07.js b/js/src/jit-test/tests/jaeger/inline/scripted-07.js
new file mode 100644
index 000000000..dfe076a65
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/scripted-07.js
@@ -0,0 +1,15 @@
+function multiple(a) {
+ if (a > 10)
+ return 1;
+ return 0;
+}
+
+function foo(x) {
+ var a = 0;
+ for (var i = 0; i < 100; i++)
+ a += multiple(i);
+ return a;
+}
+
+var q = foo([1,2,3,4,5]);
+assertEq(q, 89);
diff --git a/js/src/jit-test/tests/jaeger/inline/scripted-08.js b/js/src/jit-test/tests/jaeger/inline/scripted-08.js
new file mode 100644
index 000000000..22198388e
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/scripted-08.js
@@ -0,0 +1,21 @@
+function first(a, b) {
+ return second(a, b);
+}
+
+function second(a, b) {
+ return third(a, b, a + b);
+}
+
+function third(a, b, c) {
+ return a + b + c;
+}
+
+function foo(x) {
+ var a = 0;
+ for (var i = 0; i < 100; i++)
+ a += first(x, i);
+ return a;
+}
+
+var q = foo(10);
+assertEq(q, 11900);
diff --git a/js/src/jit-test/tests/jaeger/inline/scripted-09.js b/js/src/jit-test/tests/jaeger/inline/scripted-09.js
new file mode 100644
index 000000000..e970b77e4
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/scripted-09.js
@@ -0,0 +1,19 @@
+function multiple(a) {
+ if (a > 10)
+ return a * 20;
+ return 0;
+}
+
+function deeper(a, b) {
+ return multiple(a + b);
+}
+
+function foo() {
+ var a = 0;
+ for (var i = 0; i < 10; i++)
+ a += deeper(0x7ffffff0, i);
+ return a;
+}
+
+var q = foo();
+assertEq(q, 429496727300);
diff --git a/js/src/jit-test/tests/jaeger/inline/scripted-10.js b/js/src/jit-test/tests/jaeger/inline/scripted-10.js
new file mode 100644
index 000000000..492d055e8
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/scripted-10.js
@@ -0,0 +1,13 @@
+function copied(x, y) {
+ return x + y;
+}
+
+function foo(x) {
+ var a = 0;
+ for (var i = 0; i < 100; i++)
+ a += copied(x, x);
+ return a;
+}
+
+var q = foo(5);
+assertEq(q, 1000);
diff --git a/js/src/jit-test/tests/jaeger/inline/scripted-11.js b/js/src/jit-test/tests/jaeger/inline/scripted-11.js
new file mode 100644
index 000000000..750add398
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/scripted-11.js
@@ -0,0 +1,12 @@
+what = 0;
+
+function f(x) {
+ g(x);
+}
+
+function g(x) {
+ eval("what = true");
+}
+
+f(10);
+assertEq(what, true);
diff --git a/js/src/jit-test/tests/jaeger/inline/stringCharAt.js b/js/src/jit-test/tests/jaeger/inline/stringCharAt.js
new file mode 100644
index 000000000..bf2bbbd67
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/stringCharAt.js
@@ -0,0 +1,49 @@
+
+assertEq("foo".charAt(-123), "");
+assertEq("foo".charAt(-1), "");
+assertEq("foo".charAt(0), "f");
+assertEq("foo".charAt(1), "o");
+assertEq("foo".charAt(2), "o");
+assertEq("foo".charAt(3.4), "");
+assertEq("foo".charAt(), "f");
+assertEq("".charAt(), "");
+assertEq("".charAt(0), "");
+assertEq("abc\u9123".charAt(3), "\u9123"); // char without unit string
+
+/* Inferred as string.charAt(int). */
+function charAt1(x) {
+ return "abc".charAt(x);
+}
+assertEq(charAt1(-1), "");
+assertEq(charAt1(0), "a");
+assertEq(charAt1(1), "b");
+assertEq(charAt1(2), "c");
+assertEq(charAt1(3), "");
+assertEq(charAt1(1234), "");
+
+/* Inferred as string.charAt(double). */
+function charAt2(x) {
+ return "abc".charAt(x);
+}
+assertEq(charAt2(-1.3), "");
+assertEq(charAt2(-0), "a");
+assertEq(charAt2(2), "c");
+assertEq(charAt2(2.3), "c");
+assertEq(charAt2(3.14), "");
+assertEq(charAt2(NaN), "a");
+
+/* Test ropes. */
+function charAt3(s, i) {
+ var s2 = "abcdef" + s + "12345";
+ return s2.charAt(i);
+}
+assertEq(charAt3("abcdef", 14), "3");
+assertEq(charAt3("a" + "b", 1), "b");
+assertEq(charAt3("abcdefg" + "hijklmnop", 10), "e");
+
+/* Other 'this'. */
+var arr = [1, 2];
+arr.charAt = String.prototype.charAt;
+assertEq(arr.charAt(1), ",");
+
+
diff --git a/js/src/jit-test/tests/jaeger/inline/stringCharCodeAt.js b/js/src/jit-test/tests/jaeger/inline/stringCharCodeAt.js
new file mode 100644
index 000000000..3f0bfe2cf
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/stringCharCodeAt.js
@@ -0,0 +1,47 @@
+
+assertEq("foo".charCodeAt(-123), NaN);
+assertEq("foo".charCodeAt(-0), 102);
+assertEq("foo".charCodeAt(0), 102);
+assertEq("foo".charCodeAt(2), 111);
+assertEq("foo".charCodeAt(3.4), NaN);
+assertEq("foo".charCodeAt(), 102);
+assertEq("".charCodeAt(), NaN);
+assertEq("".charCodeAt(0), NaN);
+
+/* Inferred as string.charCodeAt(int). */
+function charCodeAt1(x) {
+ return "abc".charCodeAt(x);
+}
+assertEq(charCodeAt1(-1), NaN);
+assertEq(charCodeAt1(0), 97);
+assertEq(charCodeAt1(1), 98);
+assertEq(charCodeAt1(2), 99);
+assertEq(charCodeAt1(3), NaN);
+assertEq(charCodeAt1(1234), NaN);
+
+/* Inferred as string.charCodeAt(double). */
+function charCodeAt2(x) {
+ return "abc".charCodeAt(x);
+}
+assertEq(charCodeAt2(-1.3), NaN);
+assertEq(charCodeAt2(-0), 97);
+assertEq(charCodeAt2(2), 99);
+assertEq(charCodeAt2(2.3), 99);
+assertEq(charCodeAt2(3.14), NaN);
+assertEq(charCodeAt2(NaN), 97);
+
+/* Test ropes. */
+function charCodeAt3(s, i) {
+ var s2 = "abcdef" + s + "12345";
+ return s2.charCodeAt(i);
+}
+assertEq(charCodeAt3("abcdef", 14), 51);
+assertEq(charCodeAt3("a" + "b", 1), 98);
+assertEq(charCodeAt3("abcdefg" + "hijklmnop", 10), 101);
+
+/* Other 'this'. */
+var n = new Number(123);
+n.charCodeAt = String.prototype.charCodeAt;
+assertEq(n.charCodeAt(1), 50);
+
+
diff --git a/js/src/jit-test/tests/jaeger/inline/undefinedLocal.js b/js/src/jit-test/tests/jaeger/inline/undefinedLocal.js
new file mode 100644
index 000000000..f6fb12996
--- /dev/null
+++ b/js/src/jit-test/tests/jaeger/inline/undefinedLocal.js
@@ -0,0 +1,19 @@
+
+function bar(n) {
+ var a;
+ if (n < 50)
+ a = n;
+ return a;
+}
+
+function foo() {
+ for (var i = 0; i < 100; i++) {
+ var q = bar(i);
+ if (i < 50)
+ assertEq(q, i);
+ else
+ assertEq(q, undefined);
+ }
+}
+
+foo();