]> gitweb.factorcode.org Git - factor.git/blobdiff - vm/cpu-x86.cpp
vm: strip out call-counting profiler
[factor.git] / vm / cpu-x86.cpp
index 0fc6bbfc413bd30b28b1949b627edaaa30465413..003d8e198071119c8df5e9d09b096cfc575b0d68 100644 (file)
@@ -53,17 +53,17 @@ void factor_vm::dispatch_signal_handler(cell *sp, cell *pc, cell handler)
                        code_block *leaf_block = code->code_block_for_address(*pc);
                        assert(leaf_block != NULL);
 
-                       cell newsp = *sp - 32;
-                       *(cell*)(newsp + 32 -   sizeof(cell)) = 32;
-                       *(cell*)(newsp + 32 - 2*sizeof(cell)) = (cell)leaf_block->entry_point();
-                       *(cell*) newsp                        = *pc;
+                       cell newsp = *sp - 4*sizeof(cell);
+                       *(cell*)(newsp + 3*sizeof(cell)) = 4*sizeof(cell);
+                       *(cell*)(newsp + 2*sizeof(cell)) = (cell)leaf_block->entry_point();
+                       *(cell*) newsp                   = *pc;
                        *sp = newsp;
                        handler_word = tagged<word>(special_objects[LEAF_SIGNAL_HANDLER_WORD]);
                }
                else
                        assert(false);
 
-               *pc = (cell)handler_word->code->entry_point();
+               *pc = (cell)handler_word->entry_point;
        }
 }