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

Side by Side Diff: src/ia32/full-codegen-ia32.cc

Issue 2883042: Breakpoint position should be inside function body. (Closed)
Patch Set: Created 10 years, 5 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
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 189 matching lines...) Expand 10 before | Expand all | Expand 10 after
200 __ bind(&return_label_); 200 __ bind(&return_label_);
201 if (FLAG_trace) { 201 if (FLAG_trace) {
202 __ push(eax); 202 __ push(eax);
203 __ CallRuntime(Runtime::kTraceExit, 1); 203 __ CallRuntime(Runtime::kTraceExit, 1);
204 } 204 }
205 #ifdef DEBUG 205 #ifdef DEBUG
206 // Add a label for checking the size of the code used for returning. 206 // Add a label for checking the size of the code used for returning.
207 Label check_exit_codesize; 207 Label check_exit_codesize;
208 masm_->bind(&check_exit_codesize); 208 masm_->bind(&check_exit_codesize);
209 #endif 209 #endif
210 CodeGenerator::RecordPositions(masm_, function()->end_position()); 210 CodeGenerator::RecordPositions(masm_, function()->end_position() - 1);
211 __ RecordJSReturn(); 211 __ RecordJSReturn();
212 // Do not use the leave instruction here because it is too short to 212 // Do not use the leave instruction here because it is too short to
213 // patch with the code required by the debugger. 213 // patch with the code required by the debugger.
214 __ mov(esp, ebp); 214 __ mov(esp, ebp);
215 __ pop(ebp); 215 __ pop(ebp);
216 __ ret((scope()->num_parameters() + 1) * kPointerSize); 216 __ ret((scope()->num_parameters() + 1) * kPointerSize);
217 #ifdef ENABLE_DEBUGGER_SUPPORT 217 #ifdef ENABLE_DEBUGGER_SUPPORT
218 // Check that the size of the code used for returning matches what is 218 // Check that the size of the code used for returning matches what is
219 // expected by the debugger. 219 // expected by the debugger.
220 ASSERT_EQ(Assembler::kJSReturnSequenceLength, 220 ASSERT_EQ(Assembler::kJSReturnSequenceLength,
(...skipping 3051 matching lines...) Expand 10 before | Expand all | Expand 10 after
3272 // And return. 3272 // And return.
3273 __ ret(0); 3273 __ ret(0);
3274 } 3274 }
3275 3275
3276 3276
3277 #undef __ 3277 #undef __
3278 3278
3279 } } // namespace v8::internal 3279 } } // namespace v8::internal
3280 3280
3281 #endif // V8_TARGET_ARCH_IA32 3281 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« src/full-codegen.cc ('K') | « src/full-codegen.cc ('k') | src/runtime.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698