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

Unified Diff: runtime/vm/intermediate_language_x64.cc

Issue 51333005: Add Uint32x4List to typed_data (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 2 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/intermediate_language_mips.cc ('k') | runtime/vm/intrinsifier.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/intermediate_language_x64.cc
diff --git a/runtime/vm/intermediate_language_x64.cc b/runtime/vm/intermediate_language_x64.cc
index 6b8c37d1d59dc3969014cbfb8b48a5d64e588f51..574c51a8e80915179d970d8d5952ec3300e42149 100644
--- a/runtime/vm/intermediate_language_x64.cc
+++ b/runtime/vm/intermediate_language_x64.cc
@@ -1035,6 +1035,8 @@ CompileType LoadIndexedInstr::ComputeType() const {
return CompileType::FromCid(kDoubleCid);
case kTypedDataFloat32x4ArrayCid:
return CompileType::FromCid(kFloat32x4Cid);
+ case kTypedDataUint32x4ArrayCid:
+ return CompileType::FromCid(kUint32x4Cid);
case kTypedDataInt8ArrayCid:
case kTypedDataUint8ArrayCid:
@@ -1075,6 +1077,8 @@ Representation LoadIndexedInstr::representation() const {
case kTypedDataFloat32ArrayCid:
case kTypedDataFloat64ArrayCid:
return kUnboxedDouble;
+ case kTypedDataUint32x4ArrayCid:
+ return kUnboxedUint32x4;
case kTypedDataFloat32x4ArrayCid:
return kUnboxedFloat32x4;
default:
@@ -1103,7 +1107,9 @@ LocationSummary* LoadIndexedInstr::MakeLocationSummary() const {
index()->definition()->AsConstant()->value())
: Location::RequiresRegister());
}
- if (representation() == kUnboxedDouble) {
+ if ((representation() == kUnboxedDouble) ||
+ (representation() == kUnboxedFloat32x4) ||
+ (representation() == kUnboxedUint32x4)) {
locs->set_out(Location::RequiresFpuRegister());
} else {
locs->set_out(Location::RequiresRegister());
@@ -1137,7 +1143,8 @@ void LoadIndexedInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
}
if ((representation() == kUnboxedDouble) ||
- (representation() == kUnboxedFloat32x4)) {
+ (representation() == kUnboxedFloat32x4) ||
+ (representation() == kUnboxedUint32x4)) {
if ((index_scale() == 1) && index.IsRegister()) {
__ SmiUntag(index.reg());
}
@@ -1151,7 +1158,8 @@ void LoadIndexedInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
} else if (class_id() == kTypedDataFloat64ArrayCid) {
__ movsd(result, element_address);
} else {
- ASSERT(class_id() == kTypedDataFloat32x4ArrayCid);
+ ASSERT((class_id() == kTypedDataUint32x4ArrayCid) ||
+ (class_id() == kTypedDataFloat32x4ArrayCid));
__ movups(result, element_address);
}
return;
@@ -1222,6 +1230,8 @@ Representation StoreIndexedInstr::RequiredInputRepresentation(
return kUnboxedDouble;
case kTypedDataFloat32x4ArrayCid:
return kUnboxedFloat32x4;
+ case kTypedDataUint32x4ArrayCid:
+ return kUnboxedUint32x4;
default:
UNIMPLEMENTED();
return kTagged;
@@ -1279,6 +1289,7 @@ LocationSummary* StoreIndexedInstr::MakeLocationSummary() const {
// TODO(srdjan): Support Float64 constants.
locs->set_in(2, Location::RequiresFpuRegister());
break;
+ case kTypedDataUint32x4ArrayCid:
case kTypedDataFloat32x4ArrayCid:
locs->set_in(2, Location::RequiresFpuRegister());
break;
@@ -1396,6 +1407,7 @@ void StoreIndexedInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
case kTypedDataFloat64ArrayCid:
__ movsd(element_address, locs()->in(2).fpu_reg());
break;
+ case kTypedDataUint32x4ArrayCid:
case kTypedDataFloat32x4ArrayCid:
__ movups(element_address, locs()->in(2).fpu_reg());
break;
@@ -1530,7 +1542,7 @@ void GuardFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
__ j(EQUAL, &no_fixed_length, Assembler::kNearJump);
// Check for typed data array.
__ CompareImmediate(
- value_cid_reg, Immediate(kTypedDataFloat32x4ArrayCid), PP);
+ value_cid_reg, Immediate(kTypedDataUint32x4ArrayCid), PP);
// Not a typed array or a regular array.
__ j(GREATER, &no_fixed_length, Assembler::kNearJump);
__ CompareImmediate(
@@ -1610,7 +1622,7 @@ void GuardFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
__ j(EQUAL, &no_fixed_length, Assembler::kNearJump);
// Check for typed data array.
__ CompareImmediate(value_cid_reg,
- Immediate(kTypedDataFloat32x4ArrayCid), PP);
+ Immediate(kTypedDataUint32x4ArrayCid), PP);
// Not a typed array or a regular array.
__ j(GREATER, &no_fixed_length);
__ CompareImmediate(
« no previous file with comments | « runtime/vm/intermediate_language_mips.cc ('k') | runtime/vm/intrinsifier.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698