summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-11-02 03:55:04 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-11-02 03:55:04 +0000
commit9287cfa97dc7af476aa39658c442a3e12751f36d (patch)
treebd1c623cfb5a49bab8ba586dc1cb4b9ef5c133cc
parent2cf209d53748f938e7cba9925748a20ad33266ba (diff)
downloadruby-9287cfa97dc7af476aa39658c442a3e12751f36d.tar.gz
ruby-9287cfa97dc7af476aa39658c442a3e12751f36d.tar.xz
ruby-9287cfa97dc7af476aa39658c442a3e12751f36d.zip
* gc.c: cancel IA64 changes unnecessary for 1.8.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@7177 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--gc.c19
1 files changed, 4 insertions, 15 deletions
diff --git a/gc.c b/gc.c
index 9b3eee396..f5078721c 100644
--- a/gc.c
+++ b/gc.c
@@ -39,14 +39,10 @@
*/
#define __libc_ia64_register_backing_store_base (4ULL<<61)
#else
-#ifdef HAVE_UNWIND_H
-#include <unwind.h>
-#else
#pragma weak __libc_ia64_register_backing_store_base
extern unsigned long __libc_ia64_register_backing_store_base;
#endif
#endif
-#endif
#if defined _WIN32 || defined __CYGWIN__
#include <windows.h>
@@ -1362,21 +1358,14 @@ garbage_collect()
{
ucontext_t ctx;
VALUE *top, *bot;
-#ifdef HAVE_UNWIND_H
- _Unwind_Context *unwctx = _UNW_createContextForSelf();
-#endif
-
getcontext(&ctx);
mark_locations_array((VALUE*)&ctx.uc_mcontext,
((size_t)(sizeof(VALUE)-1 + sizeof ctx.uc_mcontext)/sizeof(VALUE)));
-#ifdef HAVE_UNWIND_H
- _UNW_currentContext(unwctx);
- bot = (VALUE*)(long)_UNW_getAR(unwctx, _UNW_AR_BSP);
- top = (VALUE*)(long)_UNW_getAR(unwctx, _UNW_AR_BSPSTORE);
- _UNW_destroyContext(unwctx);
-#else
bot = (VALUE*)__libc_ia64_register_backing_store_base;
- top = (VALUE*)ctx.uc_mcontext.IA64_BSPSTORE;
+#if defined(__FreeBSD__)
+ top = (VALUE*)ctx.uc_mcontext.mc_special.bspstore;
+#else
+ top = (VALUE*)ctx.uc_mcontext.sc_ar_bsp;
#endif
rb_gc_mark_locations(bot, top);
}