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

Unified Diff: src/interpreter/interpreter.cc

Issue 2501503005: [Interpreter] Add SetPendingMessage bytecode. (Closed)
Patch Set: cl format Created 4 years, 1 month 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
« no previous file with comments | « src/interpreter/bytecodes.h ('k') | src/runtime/runtime.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/interpreter/interpreter.cc
diff --git a/src/interpreter/interpreter.cc b/src/interpreter/interpreter.cc
index 81aecafecfdfbba9b465c7f54b6f1b685f6bf5e7..ba66044fd5cf825d6b0d8e8eaff088aad7e0a849 100644
--- a/src/interpreter/interpreter.cc
+++ b/src/interpreter/interpreter.cc
@@ -2371,6 +2371,22 @@ void Interpreter::DoStackCheck(InterpreterAssembler* assembler) {
}
}
+// SetPendingMessage
+//
+// Sets the pending message to the value in the accumulator, and returns the
+// previous pending message in the accumulator.
+void Interpreter::DoSetPendingMessage(InterpreterAssembler* assembler) {
+ Node* pending_message = __ ExternalConstant(
+ ExternalReference::address_of_pending_message_obj(isolate_));
+ Node* previous_message =
+ __ Load(MachineType::TaggedPointer(), pending_message);
+ Node* new_message = __ GetAccumulator();
+ __ StoreNoWriteBarrier(MachineRepresentation::kTaggedPointer, pending_message,
+ new_message);
+ __ SetAccumulator(previous_message);
+ __ Dispatch();
+}
+
// Throw
//
// Throws the exception in the accumulator.
« no previous file with comments | « src/interpreter/bytecodes.h ('k') | src/runtime/runtime.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698