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

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

Issue 1227963004: Trace typed data allocations (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 5 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
« 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 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 __ LoadImmediate(T7, reinterpret_cast<int32_t>(Object::null())); 172 __ LoadImmediate(T7, reinterpret_cast<int32_t>(Object::null()));
173 __ Ret(); 173 __ Ret();
174 __ delay_slot()->mov(V0, T7); 174 __ delay_slot()->mov(V0, T7);
175 __ Bind(&fall_through); 175 __ Bind(&fall_through);
176 } 176 }
177 177
178 178
179 #define TYPED_ARRAY_ALLOCATION(type_name, cid, max_len, scale_shift) \ 179 #define TYPED_ARRAY_ALLOCATION(type_name, cid, max_len, scale_shift) \
180 Label fall_through; \ 180 Label fall_through; \
181 const intptr_t kArrayLengthStackOffset = 0 * kWordSize; \ 181 const intptr_t kArrayLengthStackOffset = 0 * kWordSize; \
182 __ MaybeTraceAllocation(cid, T2, &fall_through); \
182 __ lw(T2, Address(SP, kArrayLengthStackOffset)); /* Array length. */ \ 183 __ lw(T2, Address(SP, kArrayLengthStackOffset)); /* Array length. */ \
183 /* Check that length is a positive Smi. */ \ 184 /* Check that length is a positive Smi. */ \
184 /* T2: requested array length argument. */ \ 185 /* T2: requested array length argument. */ \
185 __ andi(CMPRES1, T2, Immediate(kSmiTagMask)); \ 186 __ andi(CMPRES1, T2, Immediate(kSmiTagMask)); \
186 __ bne(CMPRES1, ZR, &fall_through); \ 187 __ bne(CMPRES1, ZR, &fall_through); \
187 __ BranchSignedLess(T2, Immediate(0), &fall_through); \ 188 __ BranchSignedLess(T2, Immediate(0), &fall_through); \
188 __ SmiUntag(T2); \ 189 __ SmiUntag(T2); \
189 /* Check for maximum allowed length. */ \ 190 /* Check for maximum allowed length. */ \
190 /* T2: untagged array length. */ \ 191 /* T2: untagged array length. */ \
191 __ BranchSignedGreater(T2, Immediate(max_len), &fall_through); \ 192 __ BranchSignedGreater(T2, Immediate(max_len), &fall_through); \
(...skipping 1976 matching lines...) Expand 10 before | Expand all | Expand 10 after
2168 Isolate* isolate = Isolate::Current(); 2169 Isolate* isolate = Isolate::Current();
2169 __ LoadImmediate(V0, reinterpret_cast<uword>(isolate)); 2170 __ LoadImmediate(V0, reinterpret_cast<uword>(isolate));
2170 // Set return value. 2171 // Set return value.
2171 __ Ret(); 2172 __ Ret();
2172 __ delay_slot()->lw(V0, Address(V0, Isolate::current_tag_offset())); 2173 __ delay_slot()->lw(V0, Address(V0, Isolate::current_tag_offset()));
2173 } 2174 }
2174 2175
2175 } // namespace dart 2176 } // namespace dart
2176 2177
2177 #endif // defined TARGET_ARCH_MIPS 2178 #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