Reviewers: Karl Klose,

Description:
Change kPointerSize to kIntSize in ia32 specific stack check patching.

The call uses a 32 bit displacement relative to the next instruction. Althoug this has no actual impact on the 32 bit platform I think this is more correct
(and will make the x64 and ia32 code more alike).


Please review this at http://codereview.chromium.org/6515011/

SVN Base: http://v8.googlecode.com/svn/branches/bleeding_edge/

Affected files:
  M     src/ia32/deoptimizer-ia32.cc


Index: src/ia32/deoptimizer-ia32.cc
===================================================================
--- src/ia32/deoptimizer-ia32.cc        (revision 6765)
+++ src/ia32/deoptimizer-ia32.cc        (working copy)
@@ -137,7 +137,7 @@
 void Deoptimizer::PatchStackCheckCodeAt(Address pc_after,
                                         Code* check_code,
                                         Code* replacement_code) {
-    Address call_target_address = pc_after - kPointerSize;
+    Address call_target_address = pc_after - kIntSize;
     ASSERT(check_code->entry() ==
            Assembler::target_address_at(call_target_address));
     // The stack check code matches the pattern:
@@ -169,7 +169,7 @@
 void Deoptimizer::RevertStackCheckCodeAt(Address pc_after,
                                          Code* check_code,
                                          Code* replacement_code) {
-  Address call_target_address = pc_after - kPointerSize;
+  Address call_target_address = pc_after - kIntSize;
   ASSERT(replacement_code->entry() ==
          Assembler::target_address_at(call_target_address));
   // Replace the nops from patching (Deoptimizer::PatchStackCheckCode) to


--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to