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

Unified Diff: runtime/vm/constants_dbc.h

Issue 2162173002: DBC: Misc double instructions (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Make test deopt Created 4 years, 5 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 | « runtime/vm/assembler_dbc_test.cc ('k') | 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 665335cf00db0b7dcf0fddc71d9e612270a65ed9..e2ea8042e0963bfc0492bffef567efd0b4b958d7 100644
--- a/runtime/vm/constants_dbc.h
+++ b/runtime/vm/constants_dbc.h
@@ -188,6 +188,11 @@ namespace dart {
// the immediately following instruction is skipped. These instructions
// expect their operands to be Smis, but don't check that they are.
//
+// - Min, Max rA, rB, rC
+//
+// FP[rA] <- {min, max}(FP[rB], FP[rC]). Assumes that FP[rB], and FP[rC] are
+// Smis.
+//
// - DAdd, DSub, DMul, DDiv rA, rB, rC
//
// Arithmetic operaions on unboxed doubles. FP[rA] <- FP[rB] op FP[rC].
@@ -201,6 +206,15 @@ namespace dart {
//
// FP[rA] <- -FP[rD]. Assumes FP[rD] is an unboxed double.
//
+// - DSqrt rA, rD
+//
+// FP[rA] <- sqrt(FP[rD]). Assumes FP[rD] is an unboxed double.
+//
+// - DMin, DMax rA, rB, rC
+//
+// FP[rA] <- {min, max}(FP[rB], FP[rC]). Assumes FP[rB] and FP[rC] are
+// unboxed doubles.
+//
// - BitOr, BitAnd, BitXor rA, rB, rC
//
// FP[rA] <- FP[rB] op FP[rC]. These instructions expect their operands to be
@@ -228,6 +242,12 @@ namespace dart {
//
// Convert the Smi in FP[rD] to an unboxed double in FP[rA].
//
+// - DoubleToSmi rA, rD
+//
+// If the unboxed double in FP[rD] can be converted to a Smi in FP[rA], then
+// this instruction does so, and skips the following instruction. Otherwise,
+// the following instruction is not skipped.
+//
// - StoreStaticT`OS D
//
// Stores TOS into the static field PP[D].
@@ -563,15 +583,21 @@ namespace dart {
V(BitAnd, A_B_C, reg, reg, reg) \
V(BitXor, A_B_C, reg, reg, reg) \
V(BitNot, A_D, reg, reg, ___) \
+ V(Min, A_B_C, reg, reg, reg) \
+ V(Max, A_B_C, reg, reg, reg) \
V(WriteIntoDouble, A_D, reg, reg, ___) \
V(UnboxDouble, A_D, reg, reg, ___) \
V(CheckedUnboxDouble, A_D, reg, reg, ___) \
V(SmiToDouble, A_D, reg, reg, ___) \
+ V(DoubleToSmi, A_D, reg, reg, ___) \
V(DAdd, A_B_C, reg, reg, reg) \
V(DSub, A_B_C, reg, reg, reg) \
V(DMul, A_B_C, reg, reg, reg) \
V(DDiv, A_B_C, reg, reg, reg) \
V(DNeg, A_D, reg, reg, ___) \
+ V(DSqrt, A_D, reg, reg, ___) \
+ V(DMin, A_B_C, reg, reg, reg) \
+ V(DMax, A_B_C, reg, reg, reg) \
V(StoreStaticTOS, D, lit, ___, ___) \
V(PushStatic, D, lit, ___, ___) \
V(InitStaticTOS, 0, ___, ___, ___) \
« no previous file with comments | « runtime/vm/assembler_dbc_test.cc ('k') | runtime/vm/intermediate_language_dbc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698