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

Side by Side Diff: runtime/vm/intermediate_language_mips.cc

Issue 731943004: Box values of LoadCodeUnits that fall outside of smi range on 32bit platforms. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: might_box Created 6 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/vm/intermediate_language_ia32.cc ('k') | runtime/vm/intermediate_language_x64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_MIPS. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_MIPS.
6 #if defined(TARGET_ARCH_MIPS) 6 #if defined(TARGET_ARCH_MIPS)
7 7
8 #include "vm/intermediate_language.h" 8 #include "vm/intermediate_language.h"
9 9
10 #include "vm/dart_entry.h" 10 #include "vm/dart_entry.h"
(...skipping 1223 matching lines...) Expand 10 before | Expand all | Expand 10 after
1234 __ SmiTag(result); 1234 __ SmiTag(result);
1235 break; 1235 break;
1236 default: 1236 default:
1237 ASSERT((class_id() == kArrayCid) || (class_id() == kImmutableArrayCid)); 1237 ASSERT((class_id() == kArrayCid) || (class_id() == kImmutableArrayCid));
1238 __ lw(result, element_address); 1238 __ lw(result, element_address);
1239 break; 1239 break;
1240 } 1240 }
1241 } 1241 }
1242 1242
1243 1243
1244 Representation LoadCodeUnitsInstr::representation() const {
1245 switch (class_id()) {
1246 case kOneByteStringCid:
1247 case kTwoByteStringCid:
1248 return kTagged;
1249 default:
1250 UNIMPLEMENTED();
1251 return kTagged;
1252 }
1253 }
1254
1255
1256 LocationSummary* LoadCodeUnitsInstr::MakeLocationSummary(Isolate* isolate, 1244 LocationSummary* LoadCodeUnitsInstr::MakeLocationSummary(Isolate* isolate,
1257 bool opt) const { 1245 bool opt) const {
1258 const intptr_t kNumInputs = 2; 1246 const intptr_t kNumInputs = 2;
1259 const intptr_t kNumTemps = 0; 1247 const intptr_t kNumTemps = 0;
1260 LocationSummary* summary = new(isolate) LocationSummary( 1248 LocationSummary* summary = new(isolate) LocationSummary(
1261 isolate, kNumInputs, kNumTemps, LocationSummary::kNoCall); 1249 isolate, kNumInputs, kNumTemps, LocationSummary::kNoCall);
1262 summary->set_in(0, Location::RequiresRegister()); 1250 summary->set_in(0, Location::RequiresRegister());
1263 summary->set_in(1, Location::RequiresRegister()); 1251 summary->set_in(1, Location::RequiresRegister());
1264 1252
1265 // TODO(zerny): Handle mints properly once possible. 1253 // TODO(zerny): Handle mints properly once possible.
(...skipping 3705 matching lines...) Expand 10 before | Expand all | Expand 10 after
4971 compiler->GenerateCall(token_pos(), &label, stub_kind_, locs()); 4959 compiler->GenerateCall(token_pos(), &label, stub_kind_, locs());
4972 #if defined(DEBUG) 4960 #if defined(DEBUG)
4973 __ LoadImmediate(S4, kInvalidObjectPointer); 4961 __ LoadImmediate(S4, kInvalidObjectPointer);
4974 __ LoadImmediate(S5, kInvalidObjectPointer); 4962 __ LoadImmediate(S5, kInvalidObjectPointer);
4975 #endif 4963 #endif
4976 } 4964 }
4977 4965
4978 } // namespace dart 4966 } // namespace dart
4979 4967
4980 #endif // defined TARGET_ARCH_MIPS 4968 #endif // defined TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « runtime/vm/intermediate_language_ia32.cc ('k') | runtime/vm/intermediate_language_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698