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

Unified Diff: runtime/vm/constants_dbc.h

Issue 2331033003: DBC: A couple allocation fastpaths. (Closed)
Patch Set: Address comments Created 4 years, 3 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
« no previous file with comments | « no previous file | runtime/vm/intermediate_language_dbc.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/constants_dbc.h
diff --git a/runtime/vm/constants_dbc.h b/runtime/vm/constants_dbc.h
index f5b2117c941a67ed0a23162601f540b625f51b67..c5dbe04f52f287ff717c2cd9661c9446b60ced42 100644
--- a/runtime/vm/constants_dbc.h
+++ b/runtime/vm/constants_dbc.h
@@ -231,7 +231,7 @@ namespace dart {
//
// - WriteIntoDouble rA, rD
//
-// Box the double in FP[rD] with the result in FP[rA].
+// Box the double in FP[rD] using the box in FP[rA].
//
// - UnboxDouble rA, rD
//
@@ -309,10 +309,24 @@ namespace dart {
//
// Allocate array of length SP[0] with type arguments SP[-1].
//
+// - CreateArrayOpt rA, rB, rC
+//
+// Try to allocate a new array where FP[rB] is the length, and FP[rC] is the
+// type. If allocation is successful, the result is stored in FP[rA], and
+// the next four instructions, which should be the
+// (Push type; Push length; AllocateTOS; PopLocal) slow path are skipped.
+//
// - Allocate D
//
// Allocate object of class PP[D] with no type arguments.
//
+// - AllocateOpt rA, D
+//
+// Try allocating an object with tags in PP[D] with no type arguments.
+// If allocation is successful, the result is stored in FP[rA], and
+// the next two instructions, which should be the (Allocate class; PopLocal)
+// slow path are skipped
+//
// - AllocateT
//
// Allocate object of class SP[0] with type arguments SP[-1].
@@ -684,8 +698,10 @@ namespace dart {
V(IfEqNull, A, reg, ___, ___) \
V(IfNeNull, A, reg, ___, ___) \
V(CreateArrayTOS, 0, ___, ___, ___) \
+ V(CreateArrayOpt, A_B_C, reg, reg, ___) \
V(Allocate, D, lit, ___, ___) \
V(AllocateT, 0, ___, ___, ___) \
+ V(AllocateOpt, A_D, reg, lit, ___) \
V(StoreIndexedTOS, 0, ___, ___, ___) \
V(StoreIndexed, A_B_C, reg, reg, reg) \
V(StoreIndexedUint8, A_B_C, reg, reg, reg) \
« no previous file with comments | « no previous file | runtime/vm/intermediate_language_dbc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698