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

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

Issue 497623003: Fix performance degradation in Havlak: prevent conflicting method recognizer kinds to be stored in … (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/vm/intrinsifier_ia32.cc ('k') | runtime/vm/intrinsifier_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/intrinsifier.h" 8 #include "vm/intrinsifier.h"
9 9
10 #include "vm/assembler.h" 10 #include "vm/assembler.h"
(...skipping 1319 matching lines...) Expand 10 before | Expand all | Expand 10 after
1330 Isolate::Current()->object_store()->double_class()); 1330 Isolate::Current()->object_store()->double_class());
1331 __ TryAllocate(double_class, &fall_through, V0, T1); // Result register. 1331 __ TryAllocate(double_class, &fall_through, V0, T1); // Result register.
1332 __ swc1(F0, FieldAddress(V0, Double::value_offset())); 1332 __ swc1(F0, FieldAddress(V0, Double::value_offset()));
1333 __ Ret(); 1333 __ Ret();
1334 __ delay_slot()->swc1(F1, 1334 __ delay_slot()->swc1(F1,
1335 FieldAddress(V0, Double::value_offset() + kWordSize)); 1335 FieldAddress(V0, Double::value_offset() + kWordSize));
1336 __ Bind(&fall_through); 1336 __ Bind(&fall_through);
1337 } 1337 }
1338 1338
1339 1339
1340 void Intrinsifier::Double_fromInteger(Assembler* assembler) { 1340 void Intrinsifier::DoubleFromInteger(Assembler* assembler) {
1341 Label fall_through; 1341 Label fall_through;
1342 1342
1343 __ lw(T0, Address(SP, 0 * kWordSize)); 1343 __ lw(T0, Address(SP, 0 * kWordSize));
1344 __ andi(CMPRES1, T0, Immediate(kSmiTagMask)); 1344 __ andi(CMPRES1, T0, Immediate(kSmiTagMask));
1345 __ bne(T0, ZR, &fall_through); 1345 __ bne(T0, ZR, &fall_through);
1346 1346
1347 // Is Smi. 1347 // Is Smi.
1348 __ SmiUntag(T0); 1348 __ SmiUntag(T0);
1349 __ mtc1(T0, F4); 1349 __ mtc1(T0, F4);
1350 __ cvtdw(D0, F4); 1350 __ cvtdw(D0, F4);
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
1555 ASSERT(kSmiTagShift == 1); 1555 ASSERT(kSmiTagShift == 1);
1556 __ addu(T2, T0, T1); 1556 __ addu(T2, T0, T1);
1557 __ lhu(V0, FieldAddress(T2, TwoByteString::data_offset())); 1557 __ lhu(V0, FieldAddress(T2, TwoByteString::data_offset()));
1558 __ Ret(); 1558 __ Ret();
1559 __ delay_slot()->SmiTag(V0); 1559 __ delay_slot()->SmiTag(V0);
1560 1560
1561 __ Bind(&fall_through); 1561 __ Bind(&fall_through);
1562 } 1562 }
1563 1563
1564 1564
1565 void Intrinsifier::StringBase_charAt(Assembler* assembler) { 1565 void Intrinsifier::StringBaseCharAt(Assembler* assembler) {
1566 Label fall_through, try_two_byte_string; 1566 Label fall_through, try_two_byte_string;
1567 1567
1568 __ lw(T1, Address(SP, 0 * kWordSize)); // Index. 1568 __ lw(T1, Address(SP, 0 * kWordSize)); // Index.
1569 __ lw(T0, Address(SP, 1 * kWordSize)); // String. 1569 __ lw(T0, Address(SP, 1 * kWordSize)); // String.
1570 1570
1571 // Checks. 1571 // Checks.
1572 __ andi(CMPRES1, T1, Immediate(kSmiTagMask)); 1572 __ andi(CMPRES1, T1, Immediate(kSmiTagMask));
1573 __ bne(T1, ZR, &fall_through); // Index is not a Smi. 1573 __ bne(T1, ZR, &fall_through); // Index is not a Smi.
1574 __ lw(T2, FieldAddress(T0, String::length_offset())); // Range check. 1574 __ lw(T2, FieldAddress(T0, String::length_offset())); // Range check.
1575 // Runtime throws exception. 1575 // Runtime throws exception.
(...skipping 373 matching lines...) Expand 10 before | Expand all | Expand 10 after
1949 Isolate* isolate = Isolate::Current(); 1949 Isolate* isolate = Isolate::Current();
1950 __ LoadImmediate(V0, reinterpret_cast<uword>(isolate)); 1950 __ LoadImmediate(V0, reinterpret_cast<uword>(isolate));
1951 // Set return value. 1951 // Set return value.
1952 __ Ret(); 1952 __ Ret();
1953 __ delay_slot()->lw(V0, Address(V0, Isolate::current_tag_offset())); 1953 __ delay_slot()->lw(V0, Address(V0, Isolate::current_tag_offset()));
1954 } 1954 }
1955 1955
1956 } // namespace dart 1956 } // namespace dart
1957 1957
1958 #endif // defined TARGET_ARCH_MIPS 1958 #endif // defined TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « runtime/vm/intrinsifier_ia32.cc ('k') | runtime/vm/intrinsifier_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698