summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkseitz <kseitz@138bc75d-0d04-0410-961f-82ee72b054a4>2006-07-21 18:50:48 +0000
committerkseitz <kseitz@138bc75d-0d04-0410-961f-82ee72b054a4>2006-07-21 18:50:48 +0000
commit508eaecca69fcf4ed2e3f6977c935b865be7c52c (patch)
tree18889540e248cad0ac2e8816d5d43cc314bd39c7
parente25a65a121ea0b6be5b0089984988cd7bbe3b7be (diff)
downloadgcc-508eaecca69fcf4ed2e3f6977c935b865be7c52c.tar.gz
* java/lang/natThread.cc (_Jv_ThreadGetData): New function.
* Makefile.am (java/lang/Thread.h): Add friend function _Jv_ThreadGetData. * Makefile.in: Regenerate. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@115646 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--libjava/ChangeLog7
-rw-r--r--libjava/Makefile.am3
-rw-r--r--libjava/Makefile.in3
-rw-r--r--libjava/java/lang/natThread.cc7
4 files changed, 20 insertions, 0 deletions
diff --git a/libjava/ChangeLog b/libjava/ChangeLog
index fef9f7b393b..9705ebe1f3e 100644
--- a/libjava/ChangeLog
+++ b/libjava/ChangeLog
@@ -1,3 +1,10 @@
+2006-07-21 Keith Seitz <keiths@redhat.com>
+
+ * java/lang/natThread.cc (_Jv_ThreadGetData): New function.
+ * Makefile.am (java/lang/Thread.h): Add friend function
+ _Jv_ThreadGetData.
+ * Makefile.in: Regenerate.
+
2006-07-20 Keith Seitz <keiths@redhat.com>
* jvmti.cc (_Jv_JVMTI_DisposeEnvironment): New function.
diff --git a/libjava/Makefile.am b/libjava/Makefile.am
index 52c8ed02288..f4f5d15a070 100644
--- a/libjava/Makefile.am
+++ b/libjava/Makefile.am
@@ -380,6 +380,7 @@ java/lang/ClassLoader.h: classpath/lib/java/lang/ClassLoader.class
java/lang/Thread.h: classpath/lib/java/lang/Thread.class
$(GCJH) -classpath '' -bootclasspath classpath/lib \
-prepend 'class _Jv_JNIEnv;' \
+ -prepend 'class _Jv_Thread_t;' \
-prepend '#define _JV_NOT_OWNER 1' \
-prepend '#define _JV_INTERRUPTED 2' \
-prepend '_Jv_JNIEnv * _Jv_GetCurrentJNIEnv ();' \
@@ -389,6 +390,7 @@ java/lang/Thread.h: classpath/lib/java/lang/Thread.class
-prepend 'java::lang::Thread* _Jv_AttachCurrentThread (jstring name, java::lang::ThreadGroup* group);' \
-prepend 'java::lang::Thread* _Jv_AttachCurrentThreadAsDaemon (jstring name, java::lang::ThreadGroup* group);' \
-prepend 'jint _Jv_DetachCurrentThread ();' \
+ -prepend '_Jv_Thread_t* _Jv_ThreadGetData (java::lang::Thread* thread);' \
-friend '_Jv_JNIEnv * ::_Jv_GetCurrentJNIEnv ();' \
-friend 'void ::_Jv_SetCurrentJNIEnv (_Jv_JNIEnv *env);' \
-friend 'void ::_Jv_ThreadRun (java::lang::Thread* thread);' \
@@ -396,6 +398,7 @@ java/lang/Thread.h: classpath/lib/java/lang/Thread.class
-friend 'java::lang::Thread* ::_Jv_AttachCurrentThread (jstring name, java::lang::ThreadGroup* group);' \
-friend 'java::lang::Thread* ::_Jv_AttachCurrentThreadAsDaemon (jstring name, java::lang::ThreadGroup* group);' \
-friend 'jint (::_Jv_DetachCurrentThread) ();' \
+ -friend '_Jv_Thread_t* ::_Jv_ThreadGetData (java::lang::Thread* thread);' \
java/lang/Thread
java/lang/String.h: classpath/lib/java/lang/String.class
diff --git a/libjava/Makefile.in b/libjava/Makefile.in
index 02ad5b7828e..e50c1e6d8c6 100644
--- a/libjava/Makefile.in
+++ b/libjava/Makefile.in
@@ -11157,6 +11157,7 @@ java/lang/ClassLoader.h: classpath/lib/java/lang/ClassLoader.class
java/lang/Thread.h: classpath/lib/java/lang/Thread.class
$(GCJH) -classpath '' -bootclasspath classpath/lib \
-prepend 'class _Jv_JNIEnv;' \
+ -prepend 'class _Jv_Thread_t;' \
-prepend '#define _JV_NOT_OWNER 1' \
-prepend '#define _JV_INTERRUPTED 2' \
-prepend '_Jv_JNIEnv * _Jv_GetCurrentJNIEnv ();' \
@@ -11166,6 +11167,7 @@ java/lang/Thread.h: classpath/lib/java/lang/Thread.class
-prepend 'java::lang::Thread* _Jv_AttachCurrentThread (jstring name, java::lang::ThreadGroup* group);' \
-prepend 'java::lang::Thread* _Jv_AttachCurrentThreadAsDaemon (jstring name, java::lang::ThreadGroup* group);' \
-prepend 'jint _Jv_DetachCurrentThread ();' \
+ -prepend '_Jv_Thread_t* _Jv_ThreadGetData (java::lang::Thread* thread);' \
-friend '_Jv_JNIEnv * ::_Jv_GetCurrentJNIEnv ();' \
-friend 'void ::_Jv_SetCurrentJNIEnv (_Jv_JNIEnv *env);' \
-friend 'void ::_Jv_ThreadRun (java::lang::Thread* thread);' \
@@ -11173,6 +11175,7 @@ java/lang/Thread.h: classpath/lib/java/lang/Thread.class
-friend 'java::lang::Thread* ::_Jv_AttachCurrentThread (jstring name, java::lang::ThreadGroup* group);' \
-friend 'java::lang::Thread* ::_Jv_AttachCurrentThreadAsDaemon (jstring name, java::lang::ThreadGroup* group);' \
-friend 'jint (::_Jv_DetachCurrentThread) ();' \
+ -friend '_Jv_Thread_t* ::_Jv_ThreadGetData (java::lang::Thread* thread);' \
java/lang/Thread
java/lang/String.h: classpath/lib/java/lang/String.class
diff --git a/libjava/java/lang/natThread.cc b/libjava/java/lang/natThread.cc
index 99841423d57..f778510bebd 100644
--- a/libjava/java/lang/natThread.cc
+++ b/libjava/java/lang/natThread.cc
@@ -318,6 +318,13 @@ _Jv_ThreadRun (java::lang::Thread* thread)
thread->finish_ ();
}
+_Jv_Thread_t*
+_Jv_ThreadGetData (java::lang::Thread* thread)
+{
+ natThread* nt = (natThread*) thread->data;
+ return nt->thread;
+}
+
void
java::lang::Thread::start (void)
{