| Index: runtime/vm/intermediate_language_ia32.cc
|
| diff --git a/runtime/vm/intermediate_language_ia32.cc b/runtime/vm/intermediate_language_ia32.cc
|
| index 03f8a723c50c2055c90b35932f6fcaf223b3604e..2717a3f4e209fd04561a6b8e742c7ccb5d86ddb9 100644
|
| --- a/runtime/vm/intermediate_language_ia32.cc
|
| +++ b/runtime/vm/intermediate_language_ia32.cc
|
| @@ -1013,8 +1013,7 @@ CompileType LoadIndexedInstr::ComputeType() const {
|
|
|
| case kTypedDataInt32ArrayCid:
|
| case kTypedDataUint32ArrayCid:
|
| - return Typed32BitIsSmi() ? CompileType::FromCid(kSmiCid)
|
| - : CompileType::FromCid(kMintCid);
|
| + return CompileType::Int();
|
|
|
| default:
|
| UNIMPLEMENTED();
|
| @@ -1038,8 +1037,9 @@ Representation LoadIndexedInstr::representation() const {
|
| case kTwoByteStringCid:
|
| return kTagged;
|
| case kTypedDataInt32ArrayCid:
|
| + return kUnboxedInt32;
|
| case kTypedDataUint32ArrayCid:
|
| - return Typed32BitIsSmi() ? kTagged : kUnboxedMint;
|
| + return kUnboxedUint32;
|
| case kTypedDataFloat32ArrayCid:
|
| case kTypedDataFloat64ArrayCid:
|
| return kUnboxedDouble;
|
| @@ -1078,15 +1078,12 @@ LocationSummary* LoadIndexedInstr::MakeLocationSummary(Isolate* isolate,
|
| (representation() == kUnboxedInt32x4) ||
|
| (representation() == kUnboxedFloat64x2)) {
|
| locs->set_out(0, Location::RequiresFpuRegister());
|
| - } else if (representation() == kUnboxedMint) {
|
| - if (class_id() == kTypedDataInt32ArrayCid) {
|
| - locs->set_out(0, Location::Pair(Location::RegisterLocation(EAX),
|
| - Location::RegisterLocation(EDX)));
|
| - } else {
|
| - ASSERT(class_id() == kTypedDataUint32ArrayCid);
|
| - locs->set_out(0, Location::Pair(Location::RequiresRegister(),
|
| - Location::RequiresRegister()));
|
| - }
|
| + } else if (representation() == kUnboxedUint32) {
|
| + ASSERT(class_id() == kTypedDataUint32ArrayCid);
|
| + locs->set_out(0, Location::RequiresRegister());
|
| + } else if (representation() == kUnboxedInt32) {
|
| + ASSERT(class_id() == kTypedDataInt32ArrayCid);
|
| + locs->set_out(0, Location::RequiresRegister());
|
| } else {
|
| ASSERT(representation() == kTagged);
|
| locs->set_out(0, Location::RequiresRegister());
|
| @@ -1133,25 +1130,21 @@ void LoadIndexedInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
|
| return;
|
| }
|
|
|
| - if (representation() == kUnboxedMint) {
|
| - ASSERT(locs()->out(0).IsPairLocation());
|
| - PairLocation* result_pair = locs()->out(0).AsPairLocation();
|
| - Register result1 = result_pair->At(0).reg();
|
| - Register result2 = result_pair->At(1).reg();
|
| + if ((representation() == kUnboxedUint32) ||
|
| + (representation() == kUnboxedInt32)) {
|
| + Register result = locs()->out(0).reg();
|
| if ((index_scale() == 1) && index.IsRegister()) {
|
| __ SmiUntag(index.reg());
|
| }
|
| switch (class_id()) {
|
| case kTypedDataInt32ArrayCid:
|
| - ASSERT(result1 == EAX);
|
| - ASSERT(result2 == EDX);
|
| - __ movl(result1, element_address);
|
| - __ cdq();
|
| - break;
|
| + ASSERT(representation() == kUnboxedInt32);
|
| + __ movl(result, element_address);
|
| + break;
|
| case kTypedDataUint32ArrayCid:
|
| - __ movl(result1, element_address);
|
| - __ xorl(result2, result2);
|
| - break;
|
| + ASSERT(representation() == kUnboxedUint32);
|
| + __ movl(result, element_address);
|
| + break;
|
| default:
|
| UNREACHABLE();
|
| }
|
|
|