Bug 126588 - js/script-tests/function-apply-many-args.js fails on ARM
Summary: js/script-tests/function-apply-many-args.js fails on ARM
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Michael Saboff
URL:
Keywords:
Depends on:
Blocks: 126172
  Show dependency treegraph
 
Reported: 2014-01-07 12:10 PST by Michael Saboff
Modified: 2014-06-30 15:14 PDT (History)
5 users (show)

See Also:


Attachments
Patch (4.02 KB, patch)
2014-06-30 15:08 PDT, Michael Saboff
mark.lam: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Saboff 2014-01-07 12:10:41 PST
It appears that the native C stack is too small top properly run function-apply-many-args.js.  When run on ARM64 with a ~1M stack, the output is:

Tests that we throw an error when passing a number of arguments beyond a certain threshold.

On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".


PASS f.apply(null) is 0
PASS f.apply(null, []) is 0
PASS f.apply(null, [1]) is 1
PASS f.apply(null, new Array(10)) is 10
PASS f.apply(null, new Array(1000)) is 1000
PASS f.apply(null, new Array(65536)) is 65536
PASS f.apply(null, new Array(65537)) threw exception RangeError: Maximum call stack size exceeded..
PASS f.apply(null, new Array(65537)) threw exception RangeError: Maximum call stack size exceeded..
PASS f.apply(null, bigArray) threw exception RangeError: Maximum call stack size exceeded..
PASS g.apply(null) is 0
PASS g.apply(null, []) is 0
PASS g.apply(null, [1]) is 1
PASS g.apply(null, new Array(10)) is 10
PASS g.apply(null, new Array(1000)) is 1000
FAIL g.apply(null, new Array(65536)) should be 65536. Threw exception RangeError: Maximum call stack size exceeded.
PASS g.apply(null, new Array(65537)) threw exception RangeError: Maximum call stack size exceeded..
PASS g.apply(null, new Array(65537)) threw exception RangeError: Maximum call stack size exceeded..
PASS g.apply(null, bigArray) threw exception RangeError: Maximum call stack size exceeded..
...
Comment 1 Michael Saboff 2014-06-30 15:08:07 PDT
Created attachment 234099 [details]
Patch
Comment 2 Mark Lam 2014-06-30 15:11:20 PDT
Comment on attachment 234099 [details]
Patch

r=me
Comment 3 Michael Saboff 2014-06-30 15:14:10 PDT
Committed r170602: <http://trac.webkit.org/changeset/170602>