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

Unified Diff: src/interpreter/bytecode-array-builder.cc

Issue 1531693002: [Interpreter] Implement ForIn in bytecode graph builder. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@oth-0009-phi
Patch Set: Created 5 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/interpreter/bytecode-array-builder.cc
diff --git a/src/interpreter/bytecode-array-builder.cc b/src/interpreter/bytecode-array-builder.cc
index 688ea0272d2e4b6e32df98598b6e70849922455b..da8d873c0a00b8216272da02cd669787290292b0 100644
--- a/src/interpreter/bytecode-array-builder.cc
+++ b/src/interpreter/bytecode-array-builder.cc
@@ -862,15 +862,26 @@ BytecodeArrayBuilder& BytecodeArrayBuilder::ForInPrepare(Register receiver) {
}
-BytecodeArrayBuilder& BytecodeArrayBuilder::ForInNext(Register for_in_state,
- Register index) {
- Output(Bytecode::kForInNext, for_in_state.ToOperand(), index.ToOperand());
+BytecodeArrayBuilder& BytecodeArrayBuilder::ForInNext(Register receiver,
+ Register index,
+ Register cache_type,
+ Register cache_array) {
+ Output(Bytecode::kForInNext, receiver.ToOperand(), index.ToOperand(),
+ cache_type.ToOperand(), cache_array.ToOperand());
return *this;
}
-BytecodeArrayBuilder& BytecodeArrayBuilder::ForInDone(Register for_in_state) {
- Output(Bytecode::kForInDone, for_in_state.ToOperand());
+BytecodeArrayBuilder& BytecodeArrayBuilder::ForInDone(Register index,
+ Register cache_length) {
+ Output(Bytecode::kForInDone, index.ToOperand(), cache_length.ToOperand());
+
+ return *this;
+}
+
+
+BytecodeArrayBuilder& BytecodeArrayBuilder::ForInStep(Register index) {
+ Output(Bytecode::kForInStep, index.ToOperand());
return *this;
}

Powered by Google App Engine
This is Rietveld 408576698