configure.in: Removed `qt' threads case.

* configure.in: Removed `qt' threads case.
	* include/quick-threads.h: Removed.
	* quick-threads.cc: Removed.

From-SVN: r30393
This commit is contained in:
Tom Tromey 1999-11-04 17:12:25 +00:00 committed by Tom Tromey
parent 16f39e241a
commit 7f80fbe501
5 changed files with 214 additions and 428 deletions

View File

@ -1,5 +1,9 @@
1999-11-04 Tom Tromey <tromey@cygnus.com>
* configure.in: Removed `qt' threads case.
* include/quick-threads.h: Removed.
* quick-threads.cc: Removed.
* include/quick-threads.h (_Jv_ThreadCancel): Removed.
(_Jv_ThreadDestroy): Likewise.
* include/no-threads.h (_Jv_ThreadCancel): Removed.

444
libjava/configure vendored

File diff suppressed because it is too large Load Diff

View File

@ -229,8 +229,6 @@ case "$THREADS" in
;;
esac
;;
qt)
;;
decosf1 | irix | mach | os2 | solaris | win32 | dce | vxworks)
AC_MSG_ERROR(thread package $THREADS not yet supported)
;;
@ -258,17 +256,6 @@ case "$THREADS" in
AC_DEFINE(HAVE_PTHREAD_MUTEXATTR_INIT)
;;
qt)
THREADDEPS='$(top_builddir)/../qthreads/libgcjcoop.la'
# We include the path to the qthreads build directory.
# See Makefile.am to understand why.
THREADLIBS="$THREADDEPS -L\$(here)/../qthreads/$libsubdir"
THREADSPEC='-lgcjcoop'
THREADOBJS=quick-threads.lo
THREADINCS='-I$(top_srcdir)/../qthreads'
THREADH=quick-threads.h
;;
none)
THREADOBJS=no-threads.lo
THREADH=no-threads.h

View File

@ -1,130 +0,0 @@
// -*- c++ -*-
// quick-threads.h - Defines for using QuickThreads.
/* Copyright (C) 1998, 1999 Cygnus Solutions
This file is part of libgcj.
This software is copyrighted work licensed under the terms of the
Libgcj License. Please consult the file "LIBGCJ_LICENSE" for
details. */
#ifndef __JV_QUICK_THREADS__
#define __JV_QUICK_THREADS__
#include <coop.h>
//
// Typedefs.
//
typedef coop_c _Jv_ConditionVariable_t;
typedef coop_m _Jv_Mutex_t;
typedef coop_t *_Jv_Thread_t;
typedef void _Jv_ThreadStartFunc (java::lang::Thread *);
//
// Condition variables.
//
inline void
_Jv_CondInit (_Jv_ConditionVariable_t *cv)
{
coop_condition_variable_init (cv);
}
inline int
_Jv_CondWait (_Jv_ConditionVariable_t *cv, _Jv_Mutex_t *mu,
jlong millis, jint nanos)
{
long micros = millis * 1000 + nanos / 1000;
// Don't round to 0 inappropriately.
if (! micros && (millis || nanos))
micros = 1;
return coop_condition_variable_wait (cv, mu, micros);
}
inline int
_Jv_CondNotify (_Jv_ConditionVariable_t *cv, _Jv_Mutex_t *mu)
{
return coop_condition_variable_signal (cv, mu);
}
inline int
_Jv_CondNotifyAll (_Jv_ConditionVariable_t *cv, _Jv_Mutex_t *mu)
{
return coop_condition_variable_signal_all (cv, mu);
}
//
// Mutexes.
//
inline void
_Jv_MutexInit (_Jv_Mutex_t *mu)
{
coop_mutex_init (mu);
}
inline int
_Jv_MutexLock (_Jv_Mutex_t *mu)
{
coop_mutex_lock (mu);
return 0;
}
inline int
_Jv_MutexUnlock (_Jv_Mutex_t *mu)
{
return coop_mutex_unlock (mu);
}
//
// Thread creation and manipulation.
//
void _Jv_InitThreads (void);
inline void
_Jv_ThreadInitData (_Jv_Thread_t **data, java::lang::Thread *)
{
*data = new _Jv_Thread_t;
**data = (coop_t *) 0;
}
inline java::lang::Thread *
_Jv_ThreadCurrent (void)
{
extern int _Jv_ThreadKey;
return (java::lang::Thread *) coop_getspecific (_Jv_ThreadKey);
}
inline void
_Jv_ThreadYield (void)
{
coop_yield ();
}
inline void
_Jv_ThreadSetPriority (_Jv_Thread_t *, jint)
{
}
void _Jv_ThreadStart (java::lang::Thread *thread, _Jv_Thread_t *data,
_Jv_ThreadStartFunc *meth);
inline void
_Jv_ThreadWait (void)
{
coop_start ();
}
inline void
_Jv_ThreadInterrupt (_Jv_Thread_t *)
{
}
#endif /* __JV_QUICK_THREADS__ */

View File

@ -1,51 +0,0 @@
// quick-threads.cc - interface between libjava and QuickThreads.
/* Copyright (C) 1998, 1999 Cygnus Solutions
This file is part of libgcj.
This software is copyrighted work licensed under the terms of the
Libgcj License. Please consult the file "LIBGCJ_LICENSE" for
details. */
#include <config.h>
#include <gcj/cni.h>
#include <jvm.h>
#include <java/lang/Thread.h>
#include <java/lang/System.h>
// Identifier for our piece of thread-local data. Visible so that it
// can be used in quick-threads.h.
int _Jv_ThreadKey;
void
_Jv_ThreadStart (java::lang::Thread *thread, _Jv_Thread_t *data,
_Jv_ThreadStartFunc *meth)
{
*data = coop_create ((coop_userf_t *) meth, (void *) thread,
thread->isDaemon());
coop_setspecific (*data, _Jv_ThreadKey, thread);
}
static void
qthrow (void *except)
{
_Jv_Throw ((java::lang::Throwable *) except);
}
// Function to destroy thread-specific data item. We just don't care.
static void
destroy_data (void *)
{
}
void
_Jv_InitThreads (void)
{
coop_init ();
_Jv_ThreadKey = coop_key_create (destroy_data);
coop_set_throw_function (qthrow);
}