[kaffe] CVS kaffe (robilad): deinlined jthread_extract_stack

Kaffe CVS cvs-commits at kaffe.org
Tue Feb 15 20:52:20 PST 2005


PatchSet 5553 
Date: 2005/02/16 04:44:47
Author: robilad
Branch: HEAD
Tag: (none) 
Log:
deinlined jthread_extract_stack

2005-02-16  Dalibor Topic  <robilad at kaffe.org>

* kaffe/kaffevm/systems/unix-pthreads/thread-internal.h (jthread_extract_stack):
Deinlined.

* kaffe/kaffevm/systems/unix-pthreads/thread-impl.c (jthread_extract_stack):
Moved over here.

Members: 
	ChangeLog:1.3597->1.3598 
	kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.70->1.71 
	kaffe/kaffevm/systems/unix-pthreads/thread-internal.h:1.34->1.35 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.3597 kaffe/ChangeLog:1.3598
--- kaffe/ChangeLog:1.3597	Wed Feb 16 03:45:09 2005
+++ kaffe/ChangeLog	Wed Feb 16 04:44:47 2005
@@ -1,5 +1,13 @@
 2005-02-16  Dalibor Topic  <robilad at kaffe.org>
 
+	* kaffe/kaffevm/systems/unix-pthreads/thread-internal.h (jthread_extract_stack): 
+	Deinlined.
+	
+	* kaffe/kaffevm/systems/unix-pthreads/thread-impl.c (jthread_extract_stack): 
+	Moved over here.
+
+2005-02-16  Dalibor Topic  <robilad at kaffe.org>
+
 	Resynced with GNU Classpath.
 
 	2005-02-15  Mark Wielaard  <mark at klomp.org>
Index: kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c
diff -u kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.70 kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.71
--- kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.70	Sat Feb  5 21:15:40 2005
+++ kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c	Wed Feb 16 04:44:50 2005
@@ -1656,3 +1656,31 @@
 {
   return sigSuspend;
 }
+
+/**
+ * Extract the range of the stack that's in use.
+ * 
+ * @param tid the thread whose stack is to be examined
+ * @param from storage for the address of the start address
+ * @param len storage for the size of the used range
+ *
+ * @return true if successful, otherwise false
+ *
+ * Needed by the garbage collector.
+ */
+
+bool jthread_extract_stack(jthread_t tid, void** from, unsigned* len)
+{
+  if (tid->active == 0) {
+    return false;
+  }
+  assert(tid->suspendState == SS_SUSPENDED);
+#if defined(STACK_GROWS_UP)
+  *from = tid->stackMin;
+  *len = (uintp)tid->stackCur - (uintp)tid->stackMin;
+#else
+  *from = tid->stackCur;
+  *len = (uintp)tid->stackMax - (uintp)tid->stackCur;
+#endif
+  return true;
+}
Index: kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-internal.h
diff -u kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-internal.h:1.34 kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-internal.h:1.35
--- kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-internal.h:1.34	Sat Feb  5 19:42:12 2005
+++ kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-internal.h	Wed Feb 16 04:44:51 2005
@@ -222,22 +222,7 @@
  *
  * Needed by the garbage collector.
  */
-static inline
-bool jthread_extract_stack(jthread_t tid, void** from, unsigned* len)
-{
-  if (tid->active == 0) {
-    return false;
-  }
-  assert(tid->suspendState == SS_SUSPENDED);
-#if defined(STACK_GROWS_UP)
-  *from = tid->stackMin;
-  *len = (uintp)tid->stackCur - (uintp)tid->stackMin;
-#else
-  *from = tid->stackCur;
-  *len = (uintp)tid->stackMax - (uintp)tid->stackCur;
-#endif
-  return true;
-}
+bool jthread_extract_stack(jthread_t tid, void** from, unsigned* len);
 
 /**
  * Returns the upper bound of the stack of the calling thread.




More information about the kaffe mailing list