1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-14 15:40:19 +02:00

The dynamic stack records SP and FP values as offsets

* libguile/dynstack.h:
* libguile/dynstack.c (PROMPT_FP, PROMPT_SP):
  (scm_dynstack_push_prompt, scm_dynstack_find_prompt): Prompts on the
  dynstack are recorded as offsets from the base stack address in this
  thread.

* libguile/control.c (scm_c_abort):
* libguile/eval.c (eval):
* libguile/stacks.c (find_prompt, narrow_stack):
* libguile/throw.c (pre_init_catch):
* libguile/vm-engine.c (prompt): Adapt.
This commit is contained in:
Andy Wingo 2013-11-21 12:12:38 +01:00
parent a3da449801
commit 0bca90aac9
8 changed files with 50 additions and 39 deletions

View file

@ -2050,8 +2050,8 @@ VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
flags = escape_only_p ? SCM_F_DYNSTACK_PROMPT_ESCAPE_ONLY : 0;
scm_dynstack_push_prompt (&current_thread->dynstack, flags,
LOCAL_REF (tag),
fp,
LOCAL_ADDRESS (proc_slot),
fp - vp->stack_base,
LOCAL_ADDRESS (proc_slot) - vp->stack_base,
ip + offset,
&registers);
NEXT (3);