typedef int perl_mutex;
typedef int perl_key;
-typedef struct thread *perl_thread;
+typedef struct thread *perl_os_thread;
/* With fake threads, thr is global(ish) so we don't need dTHR */
#define dTHR extern int errno
/* Ask thread.h to include our per-thread extras */
#define HAVE_THREAD_INTERN
struct thread_intern {
- perl_thread next_run, prev_run; /* Linked list of runnable threads */
+ perl_os_thread next_run, prev_run; /* Linked list of runnable threads */
perl_cond wait_queue; /* Wait queue that we are waiting on */
IV private; /* Holds data across time slices */
I32 savemark; /* Holds MARK for thread join values */
#else
/* POSIXish threads */
-typedef pthread_t perl_thread;
+typedef pthread_t perl_os_thread;
#ifdef OLD_PTHREADS_API
# define pthread_mutexattr_init(a) pthread_mutexattr_create(a)
# define pthread_mutexattr_settype(a,t) pthread_mutexattr_setkind_np(a,t)
SV * oursv;
HV * cvcache;
- perl_thread self; /* Underlying thread object */
+ perl_os_thread self; /* Underlying thread object */
U32 flags;
AV * threadsv; /* Per-thread SVs ($_, $@ etc.) */
AV * specific; /* Thread-specific user data */
perl_cond_signal(cp)
perl_cond *cp;
{
- perl_thread t;
+ perl_os_thread t;
perl_cond cond = *cp;
if (!cond)
perl_cond_broadcast(cp)
perl_cond *cp;
{
- perl_thread t;
+ perl_os_thread t;
perl_cond cond, cond_next;
for (cond = *cp; cond; cond = cond_next) {
#define _WIN32THREAD_H
typedef struct win32_cond { LONG waiters; HANDLE sem; } perl_cond;
typedef DWORD perl_key;
-typedef HANDLE perl_thread;
+typedef HANDLE perl_os_thread;
#ifndef DONT_USE_CRITICAL_SECTION