LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices

Reply
 
Search this Thread
Old 01-05-2007, 05:51 AM   #1
jasdeep.js
LQ Newbie
 
Registered: Jan 2007
Posts: 2

Rep: Reputation: 0
how to acheive "wait for an event" mechanism in pthreads


Hi,
I am using RH9-2.4.21 and working with pthreads.
i want to implement the event mechanism-- like waiting for an event,signaling to the waiting task when the event has occured etc.

how to acheive the event mechanism in linux in general and pthreads in particular.

Thanks
jasdeep
 
Old 01-05-2007, 06:09 AM   #2
wjevans_7d1@yahoo.co
Member
 
Registered: Jun 2006
Location: Mariposa
Distribution: Slackware 9.1
Posts: 938

Rep: Reputation: 30
pthreads programming

I've discovered a few things in my (rather extensive) experience with pthreads.

It isn't a good idea to find a recipe to do a particular thing in pthreads, and then go do it. It's much better in the long run to get a thorough understanding of how pthreads work. The reason for this is that debugging programs using pthreads can be frustrating and time-consuming, and it is easy (if you don't know thoroughly and anally what you're doing) to write a program that's impossible to debug well.

I'd recommend that you fork over a few bucks and get David R. Butenhof's book _Programming with POSIX Threads_, published by Addison Wesley. Do _not_ get _Pthreads Programming_ from O'Reilly. It doesn't convey the deeper understanding you really need to do pthreads programming correctly.

Hope this helps.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Question about Suse, Apache and Apache's "Threads" mechanism wessie Linux - General 0 07-28-2006 03:31 AM
"My posts" and "My threads" should be exempt from the wait time before searches vharishankar LQ Suggestions & Feedback 6 03-06-2006 08:10 PM
LXer: "a Watershed Event for Open Source Office Suites": LinuxWorld ... LXer Syndicated Linux News 0 01-20-2006 07:01 PM
cyrus denies login and reports "no mechanism available" in logs tisource Linux - Networking 0 04-20-2005 10:44 PM
" [drm-i830-wait-ring] *Error*Lookup" zameer_india Linux - Networking 1 10-04-2004 11:46 PM


All times are GMT -5. The time now is 08:52 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration