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

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

Issue 10832214: Move deopt reason into PcDescriptor so the EAX/RAX register is not destroyed. Some cleanups in PC d… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 4 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_x64.h ('k') | runtime/vm/intermediate_language.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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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_X64. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64.
6 #if defined(TARGET_ARCH_X64) 6 #if defined(TARGET_ARCH_X64)
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 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 __ Comment("Leaf method, lazy PC marker setup"); 68 __ Comment("Leaf method, lazy PC marker setup");
69 Label L; 69 Label L;
70 __ call(&L); 70 __ call(&L);
71 const intptr_t offset = assem->CodeSize(); 71 const intptr_t offset = assem->CodeSize();
72 __ Bind(&L); 72 __ Bind(&L);
73 __ popq(RAX); 73 __ popq(RAX);
74 __ subq(RAX, 74 __ subq(RAX,
75 Immediate(offset - AssemblerMacros::kOffsetOfSavedPCfromEntrypoint)); 75 Immediate(offset - AssemblerMacros::kOffsetOfSavedPCfromEntrypoint));
76 __ movq(Address(RBP, -kWordSize), RAX); 76 __ movq(Address(RBP, -kWordSize), RAX);
77 } 77 }
78 __ movq(RAX, Immediate(Smi::RawValue(reason_)));
79 __ call(&StubCode::DeoptimizeLabel()); 78 __ call(&StubCode::DeoptimizeLabel());
80 const intptr_t deopt_info_index = stub_ix; 79 const intptr_t deopt_info_index = stub_ix;
81 compiler->pc_descriptors_list()-> AddDeoptInfo( 80 compiler->pc_descriptors_list()-> AddDeoptInfo(
82 compiler->assembler()->CodeSize(), 81 compiler->assembler()->CodeSize(),
83 deopt_id_, 82 deopt_id_,
84 deopt_token_pos_, 83 reason_,
85 deopt_info_index); 84 deopt_info_index);
86 __ int3(); 85 __ int3();
87 #undef __ 86 #undef __
88 } 87 }
89 88
90 89
91 #define __ assembler()-> 90 #define __ assembler()->
92 91
93 92
94 // Fall through if bool_register contains null. 93 // Fall through if bool_register contains null.
(...skipping 1120 matching lines...) Expand 10 before | Expand all | Expand 10 after
1215 void ParallelMoveResolver::Exchange(const Address& mem1, const Address& mem2) { 1214 void ParallelMoveResolver::Exchange(const Address& mem1, const Address& mem2) {
1216 __ Exchange(mem1, mem2); 1215 __ Exchange(mem1, mem2);
1217 } 1216 }
1218 1217
1219 1218
1220 #undef __ 1219 #undef __
1221 1220
1222 } // namespace dart 1221 } // namespace dart
1223 1222
1224 #endif // defined TARGET_ARCH_X64 1223 #endif // defined TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph_compiler_x64.h ('k') | runtime/vm/intermediate_language.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698