Patchwork [09/10] htl: Add C11 threads types definitions

login
register
mail settings
Submitter Samuel Thibault
Date Jan. 14, 2020, 6:52 p.m.
Message ID <20200114185255.25813-11-samuel.thibault@ens-lyon.org>
Download mbox | patch
Permalink /patch/37377/
State New
Headers show

Comments

Samuel Thibault - Jan. 14, 2020, 6:52 p.m.
---
 sysdeps/htl/bits/thread-shared-types.h | 13 +++++++++++++
 1 file changed, 13 insertions(+)

Patch

diff --git a/sysdeps/htl/bits/thread-shared-types.h b/sysdeps/htl/bits/thread-shared-types.h
index c280f2e182..819682a07b 100644
--- a/sysdeps/htl/bits/thread-shared-types.h
+++ b/sysdeps/htl/bits/thread-shared-types.h
@@ -20,5 +20,18 @@ 
 #define _THREAD_SHARED_TYPES_H 1
 
 #include <bits/pthreadtypes-arch.h>
+#include <bits/types/struct___pthread_once.h>
+
+typedef int __tss_t;
+typedef int __thrd_t;
+
+typedef union
+{
+  struct __pthread_once __data;
+  int __align __ONCE_ALIGNMENT;
+  char __size[__SIZEOF_PTHREAD_ONCE_T];
+} __once_flag;
+
+#define __ONCE_FLAG_INIT { { __PTHREAD_ONCE_INIT } }
 
 #endif /* _THREAD_SHARED_TYPES_H  */