* src/threads/posix/thread-posix.hpp: Removed public semaphore interface.
authorMichael Starzinger <michi@complang.tuwien.ac.at>
Mon, 2 Nov 2009 12:23:42 +0000 (13:23 +0100)
committerMichael Starzinger <michi@complang.tuwien.ac.at>
Mon, 2 Nov 2009 12:23:42 +0000 (13:23 +0100)
* src/threads/posix/thread-posix.cpp: Moved includes here from header.

src/threads/posix/thread-posix.cpp
src/threads/posix/thread-posix.hpp

index 6a0e54adce134c6c7828b12e4a4797b93288f34e..031823ee561e9a7a6a3c2b3c62b4b138b43a3a50 100644 (file)
 
 #include "vm/jit/asmpart.h"
 
-#if !defined(__DARWIN__)
+#if defined(__DARWIN__)
+# include <mach/mach.h>
+
+typedef struct {
+       Mutex* mutex;
+       Condition* cond;
+       int value;
+} sem_t;
+
+#else
 # include <semaphore.h>
 #endif
 
index 9257ce8131db2e1bedea4e3d865da2c2092e2795..32503c4da1a20bb7395b27ff561811d5231694c2 100644 (file)
@@ -214,19 +214,6 @@ inline static threadobject* thread_get_current(void);
 #include "vm/jit/intrp/intrp.h"
 #endif
 
-#if defined(__DARWIN__)
-# include <mach/mach.h>
-
-typedef struct {
-       Mutex* mutex;
-       Condition* cond;
-       int value;
-} sem_t;
-
-#else
-# include <semaphore.h>
-#endif
-
 
 // FIXME
 #ifdef __cplusplus
@@ -289,10 +276,6 @@ inline static void threads_set_current_stackframeinfo(struct stackframeinfo_t* s
 
 /* functions ******************************************************************/
 
-void threads_sem_init(sem_t *sem, bool shared, int value);
-void threads_sem_wait(sem_t *sem);
-void threads_sem_post(sem_t *sem);
-
 void threads_start_thread(threadobject *thread, functionptr function);
 
 void threads_set_thread_priority(pthread_t tid, int priority);