Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(443)

Unified Diff: src/ia32/lithium-codegen-ia32.cc

Issue 5736008: Provide baseline for experimental GC implementation. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/gc
Patch Set: Created 10 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/ia32/lithium-codegen-ia32.cc
diff --git a/src/ia32/lithium-codegen-ia32.cc b/src/ia32/lithium-codegen-ia32.cc
index b5c0289174e7c94abf332dbc8a43726f9e8c47ce..4c1b9b5eda6a079c8c1d9535cb4ee83182256966 100644
--- a/src/ia32/lithium-codegen-ia32.cc
+++ b/src/ia32/lithium-codegen-ia32.cc
@@ -2335,20 +2335,24 @@ void LCodeGen::DoStoreNamedField(LStoreNamedField* instr) {
// Do the store.
if (instr->is_in_object()) {
__ mov(FieldOperand(object, offset), value);
+#ifdef ENABLE_CARDMARKING_WRITE_BARRIER
if (instr->needs_write_barrier()) {
Register temp = ToRegister(instr->temp());
// Update the write barrier for the object for in-object properties.
__ RecordWrite(object, offset, value, temp);
}
+#endif
} else {
Register temp = ToRegister(instr->temp());
__ mov(temp, FieldOperand(object, JSObject::kPropertiesOffset));
__ mov(FieldOperand(temp, offset), value);
+#ifdef ENABLE_CARDMARKING_WRITE_BARRIER
if (instr->needs_write_barrier()) {
// Update the write barrier for the properties array.
// object is used as a scratch register.
__ RecordWrite(temp, offset, value, object);
}
+#endif
}
}
@@ -2386,12 +2390,14 @@ void LCodeGen::DoStoreKeyedFastElement(LStoreKeyedFastElement* instr) {
value);
}
+#ifdef ENABLE_CARDMARKING_WRITE_BARRIER
// Update the write barrier unless we're certain that we're storing a smi.
if (instr->hydrogen()->NeedsWriteBarrier()) {
// Compute address of modified element and store it into key register.
__ lea(key, FieldOperand(elements, key, times_4, FixedArray::kHeaderSize));
__ RecordWrite(elements, key, value);
}
+#endif
}
« src/globals.h ('K') | « src/ia32/ic-ia32.cc ('k') | src/ia32/macro-assembler-ia32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698