mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 992535 - Add a missing barrier in ArrayPopShift; r=sfink
--HG-- extra : rebase_source : 9506fd7b727877bc635e8977171aaa079bc66199
This commit is contained in:
parent
0c5c3fa967
commit
7e26c7cd83
@ -2141,7 +2141,7 @@ js::ArrayShiftMoveElements(JSObject *obj)
|
||||
* themselves.
|
||||
*/
|
||||
uint32_t initlen = obj->getDenseInitializedLength();
|
||||
obj->moveDenseElementsUnbarriered(0, 1, initlen);
|
||||
obj->moveDenseElementsNoPreBarrier(0, 1, initlen);
|
||||
}
|
||||
|
||||
/* ES5 15.4.4.9 */
|
||||
|
@ -725,13 +725,14 @@ class JSObject : public js::ObjectImpl
|
||||
}
|
||||
}
|
||||
|
||||
void moveDenseElementsUnbarriered(uint32_t dstStart, uint32_t srcStart, uint32_t count) {
|
||||
void moveDenseElementsNoPreBarrier(uint32_t dstStart, uint32_t srcStart, uint32_t count) {
|
||||
JS_ASSERT(!shadowZone()->needsBarrier());
|
||||
|
||||
JS_ASSERT(dstStart + count <= getDenseCapacity());
|
||||
JS_ASSERT(srcStart + count <= getDenseCapacity());
|
||||
|
||||
memmove(elements + dstStart, elements + srcStart, count * sizeof(js::Value));
|
||||
DenseRangeWriteBarrierPost(runtimeFromMainThread(), this, dstStart, count);
|
||||
}
|
||||
|
||||
bool shouldConvertDoubleElements() {
|
||||
|
Loading…
Reference in New Issue
Block a user