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

Unified Diff: src/ia32/code-stubs-ia32.h

Issue 6597104: Move IncrementalRecordWrite to a stub. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/gc
Patch Set: Created 9 years, 10 months 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/code-stubs-ia32.h
diff --git a/src/ia32/code-stubs-ia32.h b/src/ia32/code-stubs-ia32.h
index 4ee88978a7d98a9a643bdc4731d09236e12a303d..dc0cb136ded32203aece0ebb98744a3ce166e4e2 100644
--- a/src/ia32/code-stubs-ia32.h
+++ b/src/ia32/code-stubs-ia32.h
@@ -505,6 +505,52 @@ class NumberToStringStub: public CodeStub {
};
+class IncrementalMarkingRecordWriteStub: public CodeStub {
+ public:
+ IncrementalMarkingRecordWriteStub(Register object,
+ Register value,
+ Register scratch,
+ ObjectMode object_mode,
+ ValueMode value_mode,
+ ScratchMode scratch_mode)
+ : object_(object),
+ value_(value),
+ scratch_(scratch),
+ object_mode_(object_mode),
+ value_mode_(value_mode),
+ scratch_mode_(scratch_mode) {
+ }
+
+ private:
+ void Generate(MacroAssembler* masm);
+
+ Major MajorKey() { return IncrementalMarkingRecordWrite; }
+
+ int MinorKey() {
+ return ObjectBits::encode(object_.code()) |
+ ValueBits::encode(value_.code()) |
+ ScratchBits::encode(scratch_.code()) |
+ ObjectModeBits::encode(object_mode_) |
+ ValueModeBits::encode(value_mode_) |
+ ScratchModeBits::encode(scratch_mode_);
+ }
+
+ class ObjectBits: public BitField<int, 0, 3> {};
+ class ValueBits: public BitField<int, 3, 3> {};
+ class ScratchBits: public BitField<int, 6, 3> {};
+ class ObjectModeBits: public BitField<ObjectMode, 9, 1> {};
+ class ValueModeBits: public BitField<ValueMode, 10, 1> {};
+ class ScratchModeBits: public BitField<ScratchMode, 11, 1> {};
+
+ Register object_;
+ Register value_;
+ Register scratch_;
+ ObjectMode object_mode_;
+ ValueMode value_mode_;
+ ScratchMode scratch_mode_;
+};
+
+
// Generate code to load an element from a pixel array. The receiver is assumed
// to not be a smi and to have elements, the caller must guarantee this
// precondition. If key is not a smi, then the generated code branches to

Powered by Google App Engine
This is Rietveld 408576698