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

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

Issue 23684036: Fix large performance regression in Box2D, MD5, and SHA1 benchmarks (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 3 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/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 1588 matching lines...) Expand 10 before | Expand all | Expand 10 after
1599 __ subu(CMPRES1, TMP, CMPRES1); 1599 __ subu(CMPRES1, TMP, CMPRES1);
1600 } else { 1600 } else {
1601 ASSERT(field_cid == kIllegalCid); 1601 ASSERT(field_cid == kIllegalCid);
1602 ASSERT(field_length == Field::kUnknownFixedLength); 1602 ASSERT(field_length == Field::kUnknownFixedLength);
1603 // At compile time we do not know the type of the field nor its 1603 // At compile time we do not know the type of the field nor its
1604 // length. At execution time we may have set the class id and 1604 // length. At execution time we may have set the class id and
1605 // list length so we compare the guarded length with the 1605 // list length so we compare the guarded length with the
1606 // list length here, without this check the list length could change 1606 // list length here, without this check the list length could change
1607 // without triggering a deoptimization. 1607 // without triggering a deoptimization.
1608 Label check_array, length_compared, no_fixed_length; 1608 Label check_array, length_compared, no_fixed_length;
1609 // If length is negative the length guard is either disabled or
1610 // has not been initialized, either way it is safe to skip the
1611 // length check.
1612 __ lw(CMPRES1, field_length_operand);
1613 __ BranchSignedLess(CMPRES1, 0, &skip_length_check);
1609 __ BranchEqual(value_cid_reg, kNullCid, &no_fixed_length); 1614 __ BranchEqual(value_cid_reg, kNullCid, &no_fixed_length);
1610 // Check for typed data array. 1615 // Check for typed data array.
1611 __ BranchSignedGreater(value_cid_reg, kTypedDataFloat32x4ArrayCid, 1616 __ BranchSignedGreater(value_cid_reg, kTypedDataFloat32x4ArrayCid,
1612 &no_fixed_length); 1617 &no_fixed_length);
1613 __ BranchSignedLess(value_cid_reg, kTypedDataInt8ArrayCid, 1618 __ BranchSignedLess(value_cid_reg, kTypedDataInt8ArrayCid,
1614 &check_array); 1619 &check_array);
1615 __ lw(TMP, FieldAddress(value_reg, TypedData::length_offset())); 1620 __ lw(TMP, FieldAddress(value_reg, TypedData::length_offset()));
1616 __ lw(CMPRES1, field_length_operand); 1621 __ lw(CMPRES1, field_length_operand);
1617 __ subu(CMPRES1, TMP, CMPRES1); 1622 __ subu(CMPRES1, TMP, CMPRES1);
1618 __ b(&length_compared); 1623 __ b(&length_compared);
(...skipping 2483 matching lines...) Expand 10 before | Expand all | Expand 10 after
4102 compiler->GenerateCall(token_pos(), 4107 compiler->GenerateCall(token_pos(),
4103 &label, 4108 &label,
4104 PcDescriptors::kOther, 4109 PcDescriptors::kOther,
4105 locs()); 4110 locs());
4106 __ Drop(2); // Discard type arguments and receiver. 4111 __ Drop(2); // Discard type arguments and receiver.
4107 } 4112 }
4108 4113
4109 } // namespace dart 4114 } // namespace dart
4110 4115
4111 #endif // defined TARGET_ARCH_MIPS 4116 #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