Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/concurrency/kernel/private.hfa

    r9cd5bd2 r31c967b  
    2020#endif
    2121
    22 #include <signal.h>
    23 
    2422#include "kernel.hfa"
    2523#include "thread.hfa"
     
    5149#endif
    5250
    53 extern "C" {
    54         __attribute__((visibility("protected"))) int __cfaabi_pthread_create(pthread_t *_thread, const pthread_attr_t *attr, void *(*start_routine) (void *), void *arg);
    55         __attribute__((visibility("protected"))) int __cfaabi_pthread_join(pthread_t _thread, void **retval);
    56         __attribute__((visibility("protected"))) pthread_t __cfaabi_pthread_self(void);
    57         __attribute__((visibility("protected"))) int __cfaabi_pthread_attr_init(pthread_attr_t *attr);
    58         __attribute__((visibility("protected"))) int __cfaabi_pthread_attr_destroy(pthread_attr_t *attr);
    59         __attribute__((visibility("protected"))) int __cfaabi_pthread_attr_setstack( pthread_attr_t *attr, void *stackaddr, size_t stacksize );
    60         __attribute__((visibility("protected"))) int __cfaabi_pthread_attr_getstacksize( const pthread_attr_t *attr, size_t *stacksize );
    61         __attribute__((visibility("protected"))) int __cfaabi_pthread_sigqueue(pthread_t _thread, int sig, const union sigval value);
    62         __attribute__((visibility("protected"))) int __cfaabi_pthread_sigmask( int how, const sigset_t *set, sigset_t *oset);
    63 }
     51// #define READYQ_USE_LINEAR_AVG
     52#define READYQ_USE_LOGDBL_AVG
     53// #define READYQ_USE_LOGINT_AVG
     54
     55#if   defined(READYQ_USE_LINEAR_AVG)
     56typedef unsigned long long __readyQ_avg_t;
     57#elif defined(READYQ_USE_LOGDBL_AVG)
     58typedef double __readyQ_avg_t;
     59#elif defined(READYQ_USE_LOGDBL_AVG)
     60typedef unsigned long long __readyQ_avg_t;
     61#else
     62#error must pick a scheme for averaging
     63#endif
    6464
    6565//-----------------------------------------------------------------------------
    6666// Scheduler
     67union __attribute__((aligned(64))) __timestamp_t {
     68        struct {
     69                volatile unsigned long long tv;
     70                volatile __readyQ_avg_t ma;
     71        } t;
     72        char __padding[192];
     73};
     74
    6775extern "C" {
    6876        void disable_interrupts() OPTIONAL_THREAD;
Note: See TracChangeset for help on using the changeset viewer.