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

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

Issue 1824023002: VM: Fix a couple of issues in the AOT optimizer, add fast path smi multiply. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: updated inlining of numeric operators Created 4 years, 9 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/aot_optimizer.cc ('k') | runtime/vm/intermediate_language_arm64.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/intermediate_language.h" 8 #include "vm/intermediate_language.h"
9 9
10 #include "vm/compiler.h" 10 #include "vm/compiler.h"
(...skipping 3099 matching lines...) Expand 10 before | Expand all | Expand 10 after
3110 __ b(slow_path->entry_label(), NE); 3110 __ b(slow_path->entry_label(), NE);
3111 switch (op_kind()) { 3111 switch (op_kind()) {
3112 case Token::kADD: 3112 case Token::kADD:
3113 __ adds(result, left, Operand(right)); 3113 __ adds(result, left, Operand(right));
3114 __ b(slow_path->entry_label(), VS); 3114 __ b(slow_path->entry_label(), VS);
3115 break; 3115 break;
3116 case Token::kSUB: 3116 case Token::kSUB:
3117 __ subs(result, left, Operand(right)); 3117 __ subs(result, left, Operand(right));
3118 __ b(slow_path->entry_label(), VS); 3118 __ b(slow_path->entry_label(), VS);
3119 break; 3119 break;
3120 case Token::kMUL:
3121 __ SmiUntag(IP, left);
3122 __ smull(result, IP, IP, right);
3123 // IP: result bits 32..63.
3124 __ cmp(IP, Operand(result, ASR, 31));
3125 __ b(slow_path->entry_label(), NE);
3126 break;
3120 case Token::kBIT_OR: 3127 case Token::kBIT_OR:
3121 // Operation may be part of combined smi check. 3128 // Operation may be part of combined smi check.
3122 if (!combined_smi_check) { 3129 if (!combined_smi_check) {
3123 __ orr(result, left, Operand(right)); 3130 __ orr(result, left, Operand(right));
3124 } 3131 }
3125 break; 3132 break;
3126 case Token::kBIT_AND: 3133 case Token::kBIT_AND:
3127 __ and_(result, left, Operand(right)); 3134 __ and_(result, left, Operand(right));
3128 break; 3135 break;
3129 case Token::kBIT_XOR: 3136 case Token::kBIT_XOR:
(...skipping 3798 matching lines...) Expand 10 before | Expand all | Expand 10 after
6928 1, 6935 1,
6929 locs()); 6936 locs());
6930 __ Drop(1); 6937 __ Drop(1);
6931 __ Pop(result); 6938 __ Pop(result);
6932 } 6939 }
6933 6940
6934 6941
6935 } // namespace dart 6942 } // namespace dart
6936 6943
6937 #endif // defined TARGET_ARCH_ARM 6944 #endif // defined TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « runtime/vm/aot_optimizer.cc ('k') | runtime/vm/intermediate_language_arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698