Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/bits/defs.hfa

    rb443db0 r428adbc  
    2121#include <stdint.h>
    2222#include <assert.h>
     23#include <signal.h>
    2324
    2425#define likely(x)   __builtin_expect(!!(x), 1)
    2526#define unlikely(x) __builtin_expect(!!(x), 0)
     27#define thread_local _Thread_local
    2628
    2729typedef void (*fptr_t)();
     
    3638#endif
    3739
    38 
    39 #if defined(__has_attribute)
    40 #if !__has_attribute(__noclone__)
    41 #define ATTRIBUTE_NOCLONE
    42 #endif
    43 #endif
    44 #ifndef ATTRIBUTE_NOCLONE
    45 #define ATTRIBUTE_NOCLONE __attribute__((__noclone__))
    46 #endif
    47 
    4840#define libcfa_public __attribute__((visibility("default")))
    49 #define libcfa_nopreempt __attribute__((section("cfatext_nopreempt"))) __attribute__((__noinline__)) ATTRIBUTE_NOCLONE
    50 
    51 struct __cfa_nopreempt_region {
    52         void * start;
    53         void * stop;
    54 };
    5541
    5642#ifdef __cforall
     
    5844void abort( bool signalAbort, const char fmt[], ... ) __attribute__ (( format(printf, 2, 3), __nothrow__, __leaf__, __noreturn__ ));
    5945extern "C" {
    60 #endif
    61 void __cabi_abort( const char fmt[], ... ) __attribute__ (( format(printf, 1, 2), __nothrow__, __leaf__, __noreturn__ ));
    62 #ifdef __cforall
     46        #include <pthread.h>
     47        void __cabi_abort( const char fmt[], ... ) __attribute__ (( format(printf, 1, 2), __nothrow__, __leaf__, __noreturn__ ));
     48        int real_pthread_create(pthread_t *_thread, const pthread_attr_t *attr, void *(*start_routine) (void *), void *arg);
     49        int real_pthread_join(pthread_t _thread, void **retval);
     50        pthread_t real_pthread_self(void);
     51        int real_pthread_attr_init(pthread_attr_t *attr);
     52        int real_pthread_attr_destroy(pthread_attr_t *attr);
     53        int real_pthread_attr_setstack( pthread_attr_t *attr, void *stackaddr, size_t stacksize );
     54        int real_pthread_attr_getstacksize( const pthread_attr_t *attr, size_t *stacksize );
     55        int real_pthread_sigqueue(pthread_t _thread, int sig, const union sigval value);
     56        int real_pthread_sigmask( int how, const sigset_t *set, sigset_t *oset);
    6357}
    6458#endif
Note: See TracChangeset for help on using the changeset viewer.