Remove interpreter’s byte stack
commit644fc17b9ae181174a842e3876e887666d505666
authorPaul Eggert <eggert@cs.ucla.edu>
Tue, 9 Aug 2016 07:37:40 +0000 (9 00:37 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Tue, 9 Aug 2016 08:31:22 +0000 (9 01:31 -0700)
tree25fd8d1b3e1a32753d3db759d0909acbc2b12e77
parentcb71a119f7231984e010cc28ef33854721036a0f
Remove interpreter’s byte stack

This improves performance overall on my benchmark on x86-64,
since the interpreted program-counter resides in a machine
register rather than in RAM.
* etc/DEBUG, src/.gdbinit: Remove xbytecode GDB command, as there
is no longer a byte stack to decode.
* src/bytecode.c (struct byte_stack, byte_stack_list)
(relocate_byte_stack): Remove.  All uses removed.
(FETCH): Simplify now that pc is now local (typically, in a
register) and no longer needs to be relocated.
(CHECK_RANGE): Remove.  All uses now done inline, in a different way.
(BYTE_CODE_QUIT): Remove; now done by op_relative_branch.
(exec_byte_code): Allocate a copy of the function’s bytecode,
so that there is no problem if GC moves it.
* src/lisp.h (struct handler): Remove byte_stack member.
All uses removed.
(SAFE_ALLOCA_LISP_EXTRA): New macro, a generalization of
SAFE_ALLOCA_LISP.
(SAFE_ALLOCA_LISP): Use it.
etc/DEBUG
src/.gdbinit
src/alloc.c
src/bytecode.c
src/eval.c
src/lisp.h