Closed
Bug 1225040
Opened 7 years ago
Closed 7 years ago
Add jsapi-tests for TypedArray on SharedArrayBuffer
Categories
(Core :: JavaScript Engine, defect)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
mozilla45
Tracking | Status | |
---|---|---|
firefox45 | --- | fixed |
People
(Reporter: lth, Assigned: lth)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
9.08 KB,
patch
|
arai
:
review+
|
Details | Diff | Splinter Review |
All TypedArray jsapi-test tests currently work with ArrayBuffer. Clearly we need to do better once TypedArray can map SharedArrayBuffer.
Assignee | ||
Comment 1•7 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=b950cfaf12dc
Assignee | ||
Comment 2•7 years ago
|
||
The "p" failure in that run is bug 1230162, technically a problem with running tests in parallel but fundamentally we should also clean up SpiderMonkey.
Assignee | ||
Comment 3•7 years ago
|
||
Attachment #8695789 -
Flags: review?(arai.unmht)
Assignee | ||
Updated•7 years ago
|
Assignee: nobody → lhansen
Status: NEW → ASSIGNED
Comment 4•7 years ago
|
||
Comment on attachment 8695789 [details] [diff] [review] generalize jsapi-tests for SAB Review of attachment 8695789 [details] [diff] [review]: ----------------------------------------------------------------- ::: js/src/jsapi-tests/testTypedArrays.cpp @@ +66,5 @@ > > return ok; > } > > +// Shared memory can only be mapped by a TypedArray by creating the TypedArray with "with" should be moved to the next line, to make this line fit into 79 chars. @@ +115,5 @@ > TestArrayFromBuffer(JSContext* cx) > { > size_t elts = 8; > size_t nbytes = elts * sizeof(Element); > + RootedObject buffer(cx, Shared ? JS_NewSharedArrayBuffer(cx, nbytes) : JS_NewArrayBuffer(cx, nbytes)); please wrap this line into 99 chars ;) (or maybe there's different style rule for test files?) @@ +120,5 @@ > { > JS::AutoCheckCannotGC nogc; > bool isShared; > + void* data = Shared ? JS_GetSharedArrayBufferData(buffer, &isShared, nogc) > + : JS_GetArrayBufferData(buffer, &isShared, nogc); ":" should be aligned to the same column as "S" of "Shared ?" in previous line. @@ +121,5 @@ > JS::AutoCheckCannotGC nogc; > bool isShared; > + void* data = Shared ? JS_GetSharedArrayBufferData(buffer, &isShared, nogc) > + : JS_GetArrayBufferData(buffer, &isShared, nogc); > + MOZ_ASSERT(Shared == isShared); as "Shared" is now variable, using CHECK might be better for testing purpose here, and following several places.
Attachment #8695789 -
Flags: review?(arai.unmht) → review+
Assignee | ||
Comment 5•7 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/a42590c2a8bf36bc766621cb0362dff28de037df Bug 1225040 - generalize jsapi-tests for SAB. r=arai
Comment 6•7 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/a42590c2a8bf
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
status-firefox45:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla45
You need to log in
before you can comment on or make changes to this bug.
Description
•