[kaffe] CVS kaffe (robilad): Fixed small compiler warning regarding
failure to inline jthread_on_current_stac
Kaffe CVS
cvs-commits at kaffe.org
Tue Oct 12 01:48:56 PDT 2004
PatchSet 5278
Date: 2004/10/12 08:45:00
Author: robilad
Branch: HEAD
Tag: (none)
Log:
Fixed small compiler warning regarding failure to inline jthread_on_current_stack
2004-10-12 Dalibor Topic <robilad at kaffe.org>
* kaffe/kaffevm/systems/unix-pthreads/thread-internal.h
(jthread_on_current_stack): De-inlined to fix compiler
warnings.
* kaffe/kaffevm/systems/unix-pthreads/thread-impl.c
(jthread_on_current_stack): Moved over here.
Members:
ChangeLog:1.2830->1.2831
kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.43->1.44
kaffe/kaffevm/systems/unix-pthreads/thread-internal.h:1.19->1.20
Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.2830 kaffe/ChangeLog:1.2831
--- kaffe/ChangeLog:1.2830 Tue Oct 12 05:20:01 2004
+++ kaffe/ChangeLog Tue Oct 12 08:45:00 2004
@@ -1,5 +1,14 @@
2004-10-12 Dalibor Topic <robilad at kaffe.org>
+ * kaffe/kaffevm/systems/unix-pthreads/thread-internal.h
+ (jthread_on_current_stack): De-inlined to fix compiler
+ warnings.
+
+ * kaffe/kaffevm/systems/unix-pthreads/thread-impl.c
+ (jthread_on_current_stack): Moved over here.
+
+2004-10-12 Dalibor Topic <robilad at kaffe.org>
+
* kaffe/kaffevm/jar.c (initJarEntry, getCentralDirCount,
getDataJarFile, openJarFile): Cast second parameter of
jarSeek to off_t to fix warnings on platforms with
Index: kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c
diff -u kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.43 kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.44
--- kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.43 Fri Oct 1 15:02:31 2004
+++ kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c Tue Oct 12 08:45:02 2004
@@ -1392,3 +1392,32 @@
#endif
}
}
+
+/**
+ * Test whether an address is on the stack of the calling thread.
+ *
+ * @param p the address to check
+ *
+ * @return true if address is on the stack
+ *
+ * Needed for locking and for exception handling.
+ */
+bool jthread_on_current_stack(void* p)
+{
+ jthread_t nt = jthread_current();
+
+DBG(JTHREADDETAIL, dprintf("on current stack: base=%p size=%ld bp=%p",
+ nt->stackMin,
+ (long)((char *)nt->stackMax - (char *)nt->stackMin),
+ p); )
+
+ if (nt == 0 || (p > nt->stackMin && p < nt->stackMax)) {
+DBG(JTHREADDETAIL, dprintf(" yes\n"); )
+ return (true);
+ }
+ else {
+DBG(JTHREADDETAIL, dprintf(" no\n"); )
+ return (false);
+ }
+}
+
Index: kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-internal.h
diff -u kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-internal.h:1.19 kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-internal.h:1.20
--- kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-internal.h:1.19 Mon Sep 20 15:48:45 2004
+++ kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-internal.h Tue Oct 12 08:45:02 2004
@@ -185,25 +185,7 @@
*
* Needed for locking and for exception handling.
*/
-static inline
-bool jthread_on_current_stack(void* p)
-{
- jthread_t nt = jthread_current();
-
-DBG(JTHREADDETAIL, dprintf("on current stack: base=%p size=%ld bp=%p",
- nt->stackMin,
- (long)((char *)nt->stackMax - (char *)nt->stackMin),
- p); )
-
- if (nt == 0 || (p > nt->stackMin && p < nt->stackMax)) {
-DBG(JTHREADDETAIL, dprintf(" yes\n"); )
- return (true);
- }
- else {
-DBG(JTHREADDETAIL, dprintf(" no\n"); )
- return (false);
- }
-}
+bool jthread_on_current_stack(void* p);
/**
* Check for room on stack.
More information about the kaffe
mailing list