|
||||||
| C and C++ C and C++ forum for discussing all forms of C except for C#. These languages are powerful low level languages used for creating Operating Systems, Device Drivers, compilers and much more. |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
|
|||
|
What are advantages/disadvantages of using
sem_wait() and sem_post() instead of pthread_cond_wait() and pthread_cond_broadcast() for sincronizing pthreads? I guess but please correct me: Advantages: (1) sem_wait() can be used inside signal handlers or async call backs (pthread_cond need pthread_mutex which is not signal handler safe) Disadvantages: (1) sem_wait()/post() is slower? Last edited by mynickmynick; 05-07-2008 at 10:13 AM. |
| Sponsored Links |
|
|
|
|||||
|
So you do know the pros/cons already?
__________________
[TRUTH] TcM is the best moderator ever! [/TRUTH] "Valid XHTML is like sex - everybody claims to have the same goal, but everybody has their own tricks and results vary wildly." To view links or images in signatures your post count must be 0 or greater. You currently have 0 posts. | To view links or images in signatures your post count must be 0 or greater. You currently have 0 posts. | To view links or images in signatures your post count must be 0 or greater. You currently have 0 posts. | To view links or images in signatures your post count must be 0 or greater. You currently have 0 posts. |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
| Xav | ........ | 1276.19 |
| MeTh0Dz|Reb0rn | ........ | 1048.58 |
| marwex89 | ........ | 869.98 |
| John | ........ | 868.39 |
| morefood2001 | ........ | 868.04 |
| WingedPanther | ........ | 761.06 |
| Brandon W | ........ | 684.87 |
| chili5 | ........ | 294.12 |
| Steve.L | ........ | 216.18 |
| dargueta | ........ | 192.86 |
Goal: 100,000 Posts
Complete: 81%