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

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

Issue 51653006: Track live instance and allocation counts for classes (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 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
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" 5 #include "vm/globals.h"
6 #if defined(TARGET_ARCH_ARM) 6 #if defined(TARGET_ARCH_ARM)
7 7
8 #include "vm/assembler.h" 8 #include "vm/assembler.h"
9 #include "vm/code_generator.h" 9 #include "vm/code_generator.h"
10 #include "vm/compiler.h" 10 #include "vm/compiler.h"
(...skipping 1098 matching lines...) Expand 10 before | Expand all | Expand 10 after
1109 __ cmp(R3, ShifterOperand(IP)); 1109 __ cmp(R3, ShifterOperand(IP));
1110 if (FLAG_use_slow_path) { 1110 if (FLAG_use_slow_path) {
1111 __ b(&slow_case); 1111 __ b(&slow_case);
1112 } else { 1112 } else {
1113 __ b(&slow_case, CS); // Branch if unsigned higher or equal. 1113 __ b(&slow_case, CS); // Branch if unsigned higher or equal.
1114 } 1114 }
1115 1115
1116 // Successfully allocated the object(s), now update top to point to 1116 // Successfully allocated the object(s), now update top to point to
1117 // next object start and initialize the object. 1117 // next object start and initialize the object.
1118 __ str(R3, Address(R5, 0)); 1118 __ str(R3, Address(R5, 0));
1119 __ BumpAllocationCount(Heap::kNew, cls.id(), R5);
1119 1120
1120 if (is_cls_parameterized) { 1121 if (is_cls_parameterized) {
1121 // Initialize the type arguments field in the object. 1122 // Initialize the type arguments field in the object.
1122 // R2: new object start. 1123 // R2: new object start.
1123 // R4: potential new object end and, if R4 != R3, potential new 1124 // R4: potential new object end and, if R4 != R3, potential new
1124 // InstantiatedTypeArguments object start. 1125 // InstantiatedTypeArguments object start.
1125 // R3: next object start. 1126 // R3: next object start.
1126 Label type_arguments_ready; 1127 Label type_arguments_ready;
1127 __ cmp(R4, ShifterOperand(R3)); 1128 __ cmp(R4, ShifterOperand(R3));
1128 __ b(&type_arguments_ready, EQ); 1129 __ b(&type_arguments_ready, EQ);
(...skipping 1013 matching lines...) Expand 10 before | Expand all | Expand 10 after
2142 const Register right = R0; 2143 const Register right = R0;
2143 __ ldr(left, Address(SP, 1 * kWordSize)); 2144 __ ldr(left, Address(SP, 1 * kWordSize));
2144 __ ldr(right, Address(SP, 0 * kWordSize)); 2145 __ ldr(right, Address(SP, 0 * kWordSize));
2145 GenerateIdenticalWithNumberCheckStub(assembler, left, right, temp); 2146 GenerateIdenticalWithNumberCheckStub(assembler, left, right, temp);
2146 __ Ret(); 2147 __ Ret();
2147 } 2148 }
2148 2149
2149 } // namespace dart 2150 } // namespace dart
2150 2151
2151 #endif // defined TARGET_ARCH_ARM 2152 #endif // defined TARGET_ARCH_ARM
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698