| Index: src/objects-inl.h
|
| ===================================================================
|
| --- src/objects-inl.h (revision 3737)
|
| +++ src/objects-inl.h (working copy)
|
| @@ -1349,7 +1349,7 @@
|
| }
|
|
|
|
|
| -WriteBarrierMode HeapObject::GetWriteBarrierMode() {
|
| +WriteBarrierMode HeapObject::GetWriteBarrierMode(const AssertNoAllocation&) {
|
| if (Heap::InNewSpace(this)) return SKIP_WRITE_BARRIER;
|
| return UPDATE_WRITE_BARRIER;
|
| }
|
| @@ -1548,9 +1548,7 @@
|
| }
|
|
|
| void NumberDictionary::set_requires_slow_elements() {
|
| - set(kMaxNumberKeyIndex,
|
| - Smi::FromInt(kRequiresSlowElementsMask),
|
| - SKIP_WRITE_BARRIER);
|
| + set(kMaxNumberKeyIndex, Smi::FromInt(kRequiresSlowElementsMask));
|
| }
|
|
|
|
|
| @@ -2973,7 +2971,8 @@
|
| PropertyDetails details) {
|
| ASSERT(!key->IsString() || details.IsDeleted() || details.index() > 0);
|
| int index = HashTable<Shape, Key>::EntryToIndex(entry);
|
| - WriteBarrierMode mode = FixedArray::GetWriteBarrierMode();
|
| + AssertNoAllocation no_gc;
|
| + WriteBarrierMode mode = FixedArray::GetWriteBarrierMode(no_gc);
|
| FixedArray::set(index, key, mode);
|
| FixedArray::set(index+1, value, mode);
|
| FixedArray::fast_set(this, index+2, details.AsSmi());
|
| @@ -3007,8 +3006,13 @@
|
| }
|
|
|
|
|
| +void JSArray::set_length(Smi* length) {
|
| + set_length(static_cast<Object*>(length), SKIP_WRITE_BARRIER);
|
| +}
|
| +
|
| +
|
| void JSArray::SetContent(FixedArray* storage) {
|
| - set_length(Smi::FromInt(storage->length()), SKIP_WRITE_BARRIER);
|
| + set_length(Smi::FromInt(storage->length()));
|
| set_elements(storage);
|
| }
|
|
|
|
|