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

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

Issue 17868006: Fix code for store buffer update on ARM and MIPS (link register was trashed). (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 6 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/assembler_mips.cc ('k') | runtime/vm/intrinsifier_ia32.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_ARM. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_ARM.
6 #if defined(TARGET_ARCH_ARM) 6 #if defined(TARGET_ARCH_ARM)
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 219 matching lines...) Expand 10 before | Expand all | Expand 10 after
230 __ ldr(R0, Address(SP, 2 * kWordSize)); // Array. 230 __ ldr(R0, Address(SP, 2 * kWordSize)); // Array.
231 231
232 // Range check. 232 // Range check.
233 __ ldr(R3, FieldAddress(R0, Array::length_offset())); // Array length. 233 __ ldr(R3, FieldAddress(R0, Array::length_offset())); // Array length.
234 __ cmp(R1, ShifterOperand(R3)); 234 __ cmp(R1, ShifterOperand(R3));
235 // Runtime throws exception. 235 // Runtime throws exception.
236 __ b(&fall_through, CS); 236 __ b(&fall_through, CS);
237 237
238 // Note that R1 is Smi, i.e, times 2. 238 // Note that R1 is Smi, i.e, times 2.
239 ASSERT(kSmiTagShift == 1); 239 ASSERT(kSmiTagShift == 1);
240 // Destroy R2 as we will not continue in the function.
241 __ ldr(R2, Address(SP, 0 * kWordSize)); // Value. 240 __ ldr(R2, Address(SP, 0 * kWordSize)); // Value.
242 __ add(R1, R0, ShifterOperand(R1, LSL, 1)); // R1 is Smi. 241 __ add(R1, R0, ShifterOperand(R1, LSL, 1)); // R1 is Smi.
243 __ StoreIntoObject(R0, 242 __ StoreIntoObject(R0,
244 FieldAddress(R1, Array::data_offset()), 243 FieldAddress(R1, Array::data_offset()),
245 R2); 244 R2);
246 // Caller is responsible for preserving the value if necessary. 245 // Caller is responsible for preserving the value if necessary.
247 __ Ret(); 246 __ Ret();
248 __ Bind(&fall_through); 247 __ Bind(&fall_through);
249 return false; 248 return false;
250 } 249 }
(...skipping 1439 matching lines...) Expand 10 before | Expand all | Expand 10 after
1690 __ Bind(&ok); 1689 __ Bind(&ok);
1691 __ Ret(); 1690 __ Ret();
1692 1691
1693 __ Bind(&fall_through); 1692 __ Bind(&fall_through);
1694 return false; 1693 return false;
1695 } 1694 }
1696 1695
1697 } // namespace dart 1696 } // namespace dart
1698 1697
1699 #endif // defined TARGET_ARCH_ARM 1698 #endif // defined TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « runtime/vm/assembler_mips.cc ('k') | runtime/vm/intrinsifier_ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698