Closed Bug 882012 Opened 11 years ago Closed 11 years ago

"asm.js type error: unknown is not a subtype of doublish" when assigning into float*array

Categories

(Core :: JavaScript Engine, defect)

x86_64
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla24

People

(Reporter: jruderman, Assigned: bbouvier)

References

Details

(Keywords: testcase)

Attachments

(1 file, 1 obsolete file)

var g = (function(stdlib, foreign, heap) { "use asm"; var identity = foreign.identity; var doubles = new stdlib.Float64Array(heap); function g() { doubles[0] = identity(2.0); return +doubles[0]; } return g; })(this, {identity: function(x) { return x; }}, new ArrayBuffer(4096)); print(g()); asm.js type error: unknown is not a subtype of doublish (In other contexts, OdinMonkey seems to be fine with treating unknown as a subtype of doublish, so this is weird.)
Same problem with *int*arrays.
Attached patch proposed fix (obsolete) — Splinter Review
Assignee: general → bbouvier
Status: NEW → ASSIGNED
Attachment #761734 - Flags: review?(luke)
Comment on attachment 761734 [details] [diff] [review] proposed fix Thanks Benjamin, perfect fix. On a style note, I'd prefer if you kept the switch (TypedArrayStoreType()) (the one after the CheckExpr) because that way we get the compiler checking that all the enum values are handled in the switch (and warning if one is missing).
Attachment #761734 - Flags: review?(luke) → review+
Sorry, backed out because of test failures: http://hg.mozilla.org/integration/mozilla-inbound/rev/64e8cd80963f TEST-UNEXPECTED-FAIL | /builds/slave/m-in_lx_sm-warnaserr-000000000/src/js/src/jit-test/tests/asm.js/testHeapAccess.js | --ion-eager: /builds/slave/m-in_lx_sm-warnaserr-000000000/src/js/src/jit-test/lib/asm.js:17:0 warning: successfully compiled asm.js code TEST-UNEXPECTED-FAIL | /builds/slave/m-in_lx_sm-warnaserr-000000000/src/js/src/jit-test/tests/asm.js/testHeapAccess.js | --baseline-eager --no-ti --no-fpu: /builds/slave/m-in_lx_sm-warnaserr-000000000/src/js/src/jit-test/lib/asm.js:17:0 warning: successfully compiled asm.js code TEST-UNEXPECTED-FAIL | /builds/slave/m-in_lx_sm-warnaserr-000000000/src/js/src/jit-test/tests/asm.js/testHeapAccess.js | --no-baseline --no-ion: /builds/slave/m-in_lx_sm-warnaserr-000000000/src/js/src/jit-test/lib/asm.js:17:0 warning: successfully compiled asm.js code TEST-UNEXPECTED-FAIL | /builds/slave/m-in_lx_sm-warnaserr-000000000/src/js/src/jit-test/tests/asm.js/testHeapAccess.js | --no-baseline --no-ion --no-ti: /builds/slave/m-in_lx_sm-warnaserr-000000000/src/js/src/jit-test/lib/asm.js:17:0 warning: successfully compiled asm.js code TEST-UNEXPECTED-FAIL | /builds/slave/m-in_lx_sm-warnaserr-000000000/src/js/src/jit-test/tests/asm.js/testHeapAccess.js | --baseline-eager: /builds/slave/m-in_lx_sm-warnaserr-000000000/src/js/src/jit-test/lib/asm.js:17:0 warning: successfully compiled asm.js code https://tbpl.mozilla.org/php/getParsedLog.php?id=24080933&tree=Mozilla-Inbound
Depends on: 882514
Doh! The tests were failing because of bug 882514. Replaced the arrow function by a lambda, jit-tests now work with --tbpl. Carrying over r+ from Luke.
Attachment #761734 - Attachment is obsolete: true
Attachment #762303 - Flags: review+
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla24
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: