This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

POSIX thread library


Hi,
  Is it possible to implement all the standard POSIX thread library 
calls in ecos namely,

General
------
pthread_create        <-->        cyg_thread_create
pthread_exit        <-->        cyg_thread_exit
pthread_detach        <-->        ??

Mutexes
------
pthread_mutex_init        <-->        cyg_mutex_init
pthread_mutex_lock        <-->        cyg_mutex_lock
pthread_mutex_unlock    <-->        cyg_mutex_unlock
pthread_mutexattr_init        <-->        ??
pthread_mutexattr_setkind_np        <-->        ??

Doubt : Now for example the cyg_mutex_unlock expects that it should not 
be called on an unlocked mutex but the behaviour has not been specfied 
in case it happens. To specify the behaviour for the same we have the 
last two calls against which I couldn't figure out any equivalent call. 
can anybody please throw some light on this.

Conditional variables
--------------
pthread_cond_init           <-->        cyg_cond_init
pthread_cond_wait        <-->        cyg_cond_wait
pthread_cond_signal        <-->        cyg_cond_signal
pthread_cond_timedwait        <-->        cyg_cond_timed_wait
pthread_cond_broadcast        <-->        cyg_cond_broadcast


Others
-----
pthread_attr_init        <-->        ??
pthread_attr_setdetachstate        <-->        ??
pthread_attr_setschedpolicy        <-->        ??
pthread_attr_setschedparam        <-->        ??
pthread_attr_setinheritsched        <-->        ??

I just want to know if there are any known issues/limtations with the 
equivalent commands listed above as compared to their POSIX counterparts 
and if anything could be done for those which are not there. Please also 
suggest if there is any workaround if possible in any of the cases 
listed above for which there are no equivalent commands.

regards,
vipin


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]