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

Unified Diff: runtime/vm/simulator_dbc.cc

Issue 2178413002: DBC: Fix 32-bit build (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/simulator_dbc.cc
diff --git a/runtime/vm/simulator_dbc.cc b/runtime/vm/simulator_dbc.cc
index 44e1e5c97cca85d35ffc7eead8e48b4854084a60..416dda577e7635daf1b5d7bcad6818e9ac9004f2 100644
--- a/runtime/vm/simulator_dbc.cc
+++ b/runtime/vm/simulator_dbc.cc
@@ -1882,6 +1882,28 @@ RawObject* Simulator::Call(const Code& code,
FP[rA] = bit_cast<RawObject*, double>(fmax(lhs, rhs));
DISPATCH();
}
+
+ {
+ BYTECODE(LoadFloat64Indexed, A_B_C);
+ ASSERT(RawObject::IsTypedDataClassId(FP[rB]->GetClassId()));
+ RawTypedData* array = reinterpret_cast<RawTypedData*>(FP[rB]);
+ RawSmi* index = RAW_CAST(Smi, FP[rC]);
+ ASSERT(SimulatorHelpers::CheckIndex(index, array->ptr()->length_));
+ double* data = reinterpret_cast<double*>(array->ptr()->data());
+ FP[rA] = bit_cast<RawObject*, double>(data[Smi::Value(index)]);
+ DISPATCH();
+ }
+
+ {
+ BYTECODE(StoreFloat64Indexed, A_B_C);
+ ASSERT(RawObject::IsTypedDataClassId(FP[rA]->GetClassId()));
+ RawTypedData* array = reinterpret_cast<RawTypedData*>(FP[rA]);
+ RawSmi* index = RAW_CAST(Smi, FP[rB]);
+ ASSERT(SimulatorHelpers::CheckIndex(index, array->ptr()->length_));
+ double* data = reinterpret_cast<double*>(array->ptr()->data());
+ data[Smi::Value(index)] = bit_cast<double, RawObject*>(FP[rC]);
+ DISPATCH();
+ }
#else // defined(ARCH_IS_64_BIT)
{
BYTECODE(WriteIntoDouble, A_D);
@@ -1984,6 +2006,18 @@ RawObject* Simulator::Call(const Code& code,
UNREACHABLE();
DISPATCH();
}
+
+ {
+ BYTECODE(LoadFloat64Indexed, A_B_C);
+ UNREACHABLE();
+ DISPATCH();
+ }
+
+ {
+ BYTECODE(StoreFloat64Indexed, A_B_C);
+ UNREACHABLE();
+ DISPATCH();
+ }
#endif // defined(ARCH_IS_64_BIT)
// Return and return like instructions (Instrinsic).
@@ -2764,17 +2798,6 @@ RawObject* Simulator::Call(const Code& code,
}
{
- BYTECODE(StoreFloat64Indexed, A_B_C);
- ASSERT(RawObject::IsTypedDataClassId(FP[rA]->GetClassId()));
- RawTypedData* array = reinterpret_cast<RawTypedData*>(FP[rA]);
- RawSmi* index = RAW_CAST(Smi, FP[rB]);
- ASSERT(SimulatorHelpers::CheckIndex(index, array->ptr()->length_));
- double* data = reinterpret_cast<double*>(array->ptr()->data());
- data[Smi::Value(index)] = bit_cast<double, RawObject*>(FP[rC]);
- DISPATCH();
- }
-
- {
BYTECODE(LoadIndexed, A_B_C);
RawArray* array = RAW_CAST(Array, FP[rB]);
RawSmi* index = RAW_CAST(Smi, FP[rC]);
@@ -2784,17 +2807,6 @@ RawObject* Simulator::Call(const Code& code,
}
{
- BYTECODE(LoadFloat64Indexed, A_B_C);
- ASSERT(RawObject::IsTypedDataClassId(FP[rB]->GetClassId()));
- RawTypedData* array = reinterpret_cast<RawTypedData*>(FP[rB]);
- RawSmi* index = RAW_CAST(Smi, FP[rC]);
- ASSERT(SimulatorHelpers::CheckIndex(index, array->ptr()->length_));
- double* data = reinterpret_cast<double*>(array->ptr()->data());
- FP[rA] = bit_cast<RawObject*, double>(data[Smi::Value(index)]);
- DISPATCH();
- }
-
- {
BYTECODE(LoadOneByteStringIndexed, A_B_C);
RawOneByteString* array = RAW_CAST(OneByteString, FP[rB]);
RawSmi* index = RAW_CAST(Smi, FP[rC]);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698