OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [libgomp/] [config/] [posix95/] [omp-lock.h] - Blame information for rev 422

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 273 jeremybenn
/* This header is used during the build process to find the size and
2
   alignment of the public OpenMP locks, so that we can export data
3
   structures without polluting the namespace.
4
 
5
   In this POSIX95 implementation, we map the two locks to the
6
   same PTHREADS primitive.  */
7
 
8
#include <pthread.h>
9
#include <semaphore.h>
10
 
11
typedef pthread_mutex_t omp_lock_25_t;
12
typedef struct { pthread_mutex_t lock; pthread_t owner; int count; } omp_nest_lock_25_t;
13
#ifdef HAVE_BROKEN_POSIX_SEMAPHORES
14
/* If we don't have working semaphores, we'll make all explicit tasks
15
   tied to the creating thread.  */
16
typedef pthread_mutex_t omp_lock_t;
17
typedef struct { pthread_mutex_t lock; int count; void *owner; } omp_nest_lock_t;
18
#else
19
typedef sem_t omp_lock_t;
20
typedef struct { sem_t lock; int count; void *owner; } omp_nest_lock_t;
21
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.