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

Side by Side Diff: src/x64/fast-codegen-x64.cc

Issue 456001: Move CPU-specific constants from debug.h into the platform-specific directori... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years 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 | « src/x64/debug-x64.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 __ RecordJSReturn(); 182 __ RecordJSReturn();
183 // Do not use the leave instruction here because it is too short to 183 // Do not use the leave instruction here because it is too short to
184 // patch with the code required by the debugger. 184 // patch with the code required by the debugger.
185 __ movq(rsp, rbp); 185 __ movq(rsp, rbp);
186 __ pop(rbp); 186 __ pop(rbp);
187 __ ret((function_->scope()->num_parameters() + 1) * kPointerSize); 187 __ ret((function_->scope()->num_parameters() + 1) * kPointerSize);
188 #ifdef ENABLE_DEBUGGER_SUPPORT 188 #ifdef ENABLE_DEBUGGER_SUPPORT
189 // Add padding that will be overwritten by a debugger breakpoint. We 189 // Add padding that will be overwritten by a debugger breakpoint. We
190 // have just generated "movq rsp, rbp; pop rbp; ret k" with length 7 190 // have just generated "movq rsp, rbp; pop rbp; ret k" with length 7
191 // (3 + 1 + 3). 191 // (3 + 1 + 3).
192 const int kPadding = Debug::kX64JSReturnSequenceLength - 7; 192 const int kPadding = Assembler::kJSReturnSequenceLength - 7;
193 for (int i = 0; i < kPadding; ++i) { 193 for (int i = 0; i < kPadding; ++i) {
194 masm_->int3(); 194 masm_->int3();
195 } 195 }
196 // Check that the size of the code used for returning matches what is 196 // Check that the size of the code used for returning matches what is
197 // expected by the debugger. 197 // expected by the debugger.
198 ASSERT_EQ(Debug::kX64JSReturnSequenceLength, 198 ASSERT_EQ(Assembler::kJSReturnSequenceLength,
199 masm_->SizeOfCodeGeneratedSince(&check_exit_codesize)); 199 masm_->SizeOfCodeGeneratedSince(&check_exit_codesize));
200 #endif 200 #endif
201 } 201 }
202 } 202 }
203 203
204 204
205 void FastCodeGenerator::Move(Expression::Context context, Register source) { 205 void FastCodeGenerator::Move(Expression::Context context, Register source) {
206 switch (context) { 206 switch (context) {
207 case Expression::kUninitialized: 207 case Expression::kUninitialized:
208 UNREACHABLE(); 208 UNREACHABLE();
(...skipping 1472 matching lines...) Expand 10 before | Expand all | Expand 10 after
1681 true_label_ = saved_true; 1681 true_label_ = saved_true;
1682 false_label_ = saved_false; 1682 false_label_ = saved_false;
1683 // Convert current context to test context: End post-test code. 1683 // Convert current context to test context: End post-test code.
1684 } 1684 }
1685 1685
1686 1686
1687 #undef __ 1687 #undef __
1688 1688
1689 1689
1690 } } // namespace v8::internal 1690 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/x64/debug-x64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698