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

Unified Diff: src/ia32/codegen-ia32.cc

Issue 118383: Simplify the IA32 exception handler block by removing the unused code... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/frames-inl.h ('k') | src/ia32/frames-ia32.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ia32/codegen-ia32.cc
===================================================================
--- src/ia32/codegen-ia32.cc (revision 2121)
+++ src/ia32/codegen-ia32.cc (working copy)
@@ -6935,16 +6935,16 @@
void CEntryStub::GenerateThrowTOS(MacroAssembler* masm) {
- ASSERT(StackHandlerConstants::kSize == 6 * kPointerSize); // adjust this code
+ // Adjust this code if not the case.
+ ASSERT(StackHandlerConstants::kSize == 4 * kPointerSize);
ExternalReference handler_address(Top::k_handler_address);
__ mov(edx, Operand::StaticVariable(handler_address));
- __ mov(ecx, Operand(edx, -1 * kPointerSize)); // get next in chain
+ // Get next in chain.
+ __ mov(ecx, Operand(edx, StackHandlerConstants::kAddressDisplacement));
__ mov(Operand::StaticVariable(handler_address), ecx);
__ mov(esp, Operand(edx));
- __ pop(edi);
__ pop(ebp);
- __ pop(edx); // remove code pointer
- __ pop(edx); // remove state
+ __ pop(edx); // Remove state.
// Before returning we restore the context from the frame pointer if not NULL.
// The frame pointer is NULL in the exception handler of a JS entry frame.
@@ -7040,6 +7040,9 @@
void CEntryStub::GenerateThrowOutOfMemory(MacroAssembler* masm) {
+ // Adjust this code if not the case.
+ ASSERT(StackHandlerConstants::kSize == 4 * kPointerSize);
+
// Fetch top stack handler.
ExternalReference handler_address(Top::k_handler_address);
__ mov(edx, Operand::StaticVariable(handler_address));
@@ -7080,9 +7083,7 @@
__ xor_(esi, Operand(esi));
// Restore registers from handler.
- __ pop(edi); // PP
__ pop(ebp); // FP
- __ pop(edx); // Code
__ pop(edx); // State
__ ret(0);
« no previous file with comments | « src/frames-inl.h ('k') | src/ia32/frames-ia32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698