mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-30 17:00:23 +02:00
* gc.c: support ia64 register backing store.
(SCM_MARK_BACKING_STORE): new macro.
This commit is contained in:
parent
075acefc27
commit
043a5b0f94
1 changed files with 20 additions and 0 deletions
|
@ -52,6 +52,11 @@
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
|
#ifdef __ia64__
|
||||||
|
#include <ucontext.h>
|
||||||
|
extern unsigned long __libc_ia64_register_backing_store_base;
|
||||||
|
#endif
|
||||||
|
|
||||||
#include "libguile/_scm.h"
|
#include "libguile/_scm.h"
|
||||||
#include "libguile/eval.h"
|
#include "libguile/eval.h"
|
||||||
#include "libguile/stime.h"
|
#include "libguile/stime.h"
|
||||||
|
@ -1027,6 +1032,20 @@ scm_t_c_hook scm_before_sweep_c_hook;
|
||||||
scm_t_c_hook scm_after_sweep_c_hook;
|
scm_t_c_hook scm_after_sweep_c_hook;
|
||||||
scm_t_c_hook scm_after_gc_c_hook;
|
scm_t_c_hook scm_after_gc_c_hook;
|
||||||
|
|
||||||
|
#ifdef __ia64__
|
||||||
|
# define SCM_MARK_BACKING_STORE() do { \
|
||||||
|
ucontext_t ctx; \
|
||||||
|
SCM_STACKITEM * top, * bot; \
|
||||||
|
getcontext (&ctx); \
|
||||||
|
scm_mark_locations ((SCM_STACKITEM *) &ctx.uc_mcontext, \
|
||||||
|
((size_t) (sizeof (SCM_STACKITEM) - 1 + sizeof ctx.uc_mcontext) \
|
||||||
|
/ sizeof (SCM_STACKITEM))); \
|
||||||
|
bot = (SCM_STACKITEM *) __libc_ia64_register_backing_store_base; \
|
||||||
|
top = (SCM_STACKITEM *) ctx.uc_mcontext.sc_ar_bsp; \
|
||||||
|
scm_mark_locations (bot, top - bot); } while (0)
|
||||||
|
#else
|
||||||
|
# define SCM_MARK_BACKING_STORE()
|
||||||
|
#endif
|
||||||
|
|
||||||
void
|
void
|
||||||
scm_igc (const char *what)
|
scm_igc (const char *what)
|
||||||
|
@ -1099,6 +1118,7 @@ scm_igc (const char *what)
|
||||||
scm_mark_locations (scm_stack_base - stack_len, stack_len);
|
scm_mark_locations (scm_stack_base - stack_len, stack_len);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
SCM_MARK_BACKING_STORE();
|
||||||
|
|
||||||
#else /* USE_THREADS */
|
#else /* USE_THREADS */
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue