summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/arguments/inline-arguments-profiler.js
blob: 6d89b3d72b24bcd8ebb3f2266af89666000674a4 (plain)
1
2
3
4
5
6
7
8
9
10
11
function foo() { return arguments; }
function bar(x) { return foo(x); }

// Turning on the profiler uses up a register and increases register pressure.
enableGeckoProfiling();
with ({}) {}
for (var i = 0; i < 100; i++) {
  var result = bar(3);
  assertEq(result.length, 1);
  assertEq(result[0], 3);
}