Changes between Version 2 and Version 3 of user_synchro


Ignore:
Timestamp:
Oct 9, 2018, 12:54:19 PM (6 years ago)
Author:
alain
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • user_synchro

    v2 v3  
    55== A) General Principles ==
    66
    7 All data structure defined by  ALMOS-MKH to support the user-level, POSIX compliant, synchronization services are fully specific, and do NOT use the kernel level synchronization primitives described in section. does NOT use the 
     7All data structure defined by  ALMOS-MKH to support the user-level, POSIX compliant, synchronization services are fully specific, and do NOT use the kernel level synchronization primitives described in section J.
     8 * A '''mutex''' is declared by a given user process as a ''pthread_mutex_t'' global variable.
     9 * A '''condvar'''  is declared by a given user process as a ''pthread_cond_t'' global variable.
     10 * A '''barrier'''  is declared by a given user process as a ''pthread_barrier_t'' global variable.
     11 * A '''semaphore''' is declared by a given user process as a ''sem_t'' global variable.
     12All these user types are implemented by ALMOS-MKH as ''unsigned long'', but the value stored in user space is NOT used by the kernel. ALMOS-MKH uses only the virtual address as an identifier for a given synchronization variable.
     13For each type of variable, ALMOS-MKH defines a specific internal data structure described below.
    814
    915== B) Mutex ==
     
    1218
    1319It can be used by muti-threaded user applications to synchronise user threads running in different clusters.
    14 
    15 A mutex is declared by a given user process as a ''pthread_mutex_t'' global variable. This user type is implemented by ALMOS-MKH as an ''unsigned long'', but the value stored in user space is NOT used by the kernel. ALMOS-MKH uses only the mutex virtual address as an identifier for the mutex.
    1620
    1721The kernel implementation of a mutex is defined in the [https://www-soc.lip6.fr/trac/almos-mkh/browser/trunk/kernel/libk/remote_mutex.h remote_mutex.h] and [https://www-soc.lip6.fr/trac/almos-mkh/browser/trunk/kernel/libk/remote_mutex.c remote_mutex.c] files.
     
    2226== C) Condvar ==
    2327
     28The user level, POSIX compliant, condvar API is defined in the '''pthread''' library implemented by the [https://www-soc.lip6.fr/trac/almos-mkh/browser/trunk/libs/libpthread/pthread.h pthread.h] and [https://www-soc.lip6.fr/trac/almos-mkh/browser/trunk/libs/libpthread/pthread.c pthread.c] files.
     29
    2430== D) Semaphore ==
    2531