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

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

Issue 15946002: Allow breakpoints on strict equal (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 7 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/flow_graph_compiler_ia32.cc ('k') | runtime/vm/flow_graph_compiler_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/flow_graph_compiler.h" 8 #include "vm/flow_graph_compiler.h"
9 9
10 #include "lib/error.h" 10 #include "lib/error.h"
(...skipping 1195 matching lines...) Expand 10 before | Expand all | Expand 10 after
1206 &StubCode::CallStaticFunctionLabel(), 1206 &StubCode::CallStaticFunctionLabel(),
1207 PcDescriptors::kFuncCall, 1207 PcDescriptors::kFuncCall,
1208 locs); 1208 locs);
1209 AddStaticCallTarget(function); 1209 AddStaticCallTarget(function);
1210 __ Drop(argument_count); 1210 __ Drop(argument_count);
1211 } 1211 }
1212 1212
1213 1213
1214 void FlowGraphCompiler::EmitEqualityRegConstCompare(Register reg, 1214 void FlowGraphCompiler::EmitEqualityRegConstCompare(Register reg,
1215 const Object& obj, 1215 const Object& obj,
1216 bool needs_number_check) { 1216 bool needs_number_check,
1217 intptr_t token_pos) {
1217 if (needs_number_check && 1218 if (needs_number_check &&
1218 (obj.IsMint() || obj.IsDouble() || obj.IsBigint())) { 1219 (obj.IsMint() || obj.IsDouble() || obj.IsBigint())) {
1219 __ addiu(SP, SP, Immediate(-2 * kWordSize)); 1220 __ addiu(SP, SP, Immediate(-2 * kWordSize));
1220 __ sw(reg, Address(SP, 1 * kWordSize)); 1221 __ sw(reg, Address(SP, 1 * kWordSize));
1221 __ LoadObject(TMP1, obj); 1222 __ LoadObject(TMP1, obj);
1222 __ BranchLink(&StubCode::IdenticalWithNumberCheckLabel()); 1223 __ BranchLink(&StubCode::IdenticalWithNumberCheckLabel());
1224 AddCurrentDescriptor(PcDescriptors::kRuntimeCall,
1225 Isolate::kNoDeoptId,
1226 token_pos);
1223 __ delay_slot()->sw(TMP1, Address(SP, 0 * kWordSize)); 1227 __ delay_slot()->sw(TMP1, Address(SP, 0 * kWordSize));
1224 __ lw(reg, Address(SP, 1 * kWordSize)); // Restore 'reg'. 1228 __ lw(reg, Address(SP, 1 * kWordSize)); // Restore 'reg'.
1225 __ addiu(SP, SP, Immediate(2 * kWordSize)); // Discard constant. 1229 __ addiu(SP, SP, Immediate(2 * kWordSize)); // Discard constant.
1226 return; 1230 return;
1227 } 1231 }
1228 __ CompareObject(CMPRES, reg, obj); 1232 __ CompareObject(CMPRES, reg, obj);
1229 } 1233 }
1230 1234
1231 1235
1232 void FlowGraphCompiler::EmitEqualityRegRegCompare(Register left, 1236 void FlowGraphCompiler::EmitEqualityRegRegCompare(Register left,
1233 Register right, 1237 Register right,
1234 bool needs_number_check) { 1238 bool needs_number_check,
1239 intptr_t token_pos) {
1235 __ TraceSimMsg("EqualityRegRegCompare"); 1240 __ TraceSimMsg("EqualityRegRegCompare");
1236 if (needs_number_check) { 1241 if (needs_number_check) {
1237 __ addiu(SP, SP, Immediate(-2 * kWordSize)); 1242 __ addiu(SP, SP, Immediate(-2 * kWordSize));
1238 __ sw(left, Address(SP, 1 * kWordSize)); 1243 __ sw(left, Address(SP, 1 * kWordSize));
1239 __ BranchLink(&StubCode::IdenticalWithNumberCheckLabel()); 1244 __ BranchLink(&StubCode::IdenticalWithNumberCheckLabel());
1245 AddCurrentDescriptor(PcDescriptors::kRuntimeCall,
1246 Isolate::kNoDeoptId,
1247 token_pos);
1240 __ delay_slot()->sw(right, Address(SP, 0 * kWordSize)); 1248 __ delay_slot()->sw(right, Address(SP, 0 * kWordSize));
1241 __ TraceSimMsg("EqualityRegRegCompare return"); 1249 __ TraceSimMsg("EqualityRegRegCompare return");
1242 // Stub returns result in CMPRES. If it is 0, then left and right are equal. 1250 // Stub returns result in CMPRES. If it is 0, then left and right are equal.
1243 __ lw(right, Address(SP, 0 * kWordSize)); 1251 __ lw(right, Address(SP, 0 * kWordSize));
1244 __ lw(left, Address(SP, 1 * kWordSize)); 1252 __ lw(left, Address(SP, 1 * kWordSize));
1245 __ addiu(SP, SP, Immediate(2 * kWordSize)); 1253 __ addiu(SP, SP, Immediate(2 * kWordSize));
1246 } else { 1254 } else {
1247 __ subu(CMPRES, left, right); 1255 __ subu(CMPRES, left, right);
1248 } 1256 }
1249 } 1257 }
(...skipping 329 matching lines...) Expand 10 before | Expand all | Expand 10 after
1579 __ AddImmediate(SP, kDoubleSize); 1587 __ AddImmediate(SP, kDoubleSize);
1580 } 1588 }
1581 1589
1582 1590
1583 #undef __ 1591 #undef __
1584 1592
1585 1593
1586 } // namespace dart 1594 } // namespace dart
1587 1595
1588 #endif // defined TARGET_ARCH_MIPS 1596 #endif // defined TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph_compiler_ia32.cc ('k') | runtime/vm/flow_graph_compiler_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698