All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Luciano Moreira - igLnx" <lucianolnx@ig.com.br>
To: Glynn Clements <glynn.clements@virgin.net>, ronkhu@ntsp.nec.co.jp
Cc: linux-c-programming@vger.kernel.org
Subject: Re: (non-member) wait-notify mechanism in pthreads
Date: Mon, 28 Apr 2003 14:02:36 -0300	[thread overview]
Message-ID: <016801c30da7$fa4ebeb0$0b00a8c0@SPLUCIANO> (raw)
In-Reply-To: 16045.13129.643228.647757@cerise.nosuchdomain.co.uk

If you dont need to execute something while waiting a thread to exit, you
can use only pthread API instead mutex, waiting a thread to join.

Luciano

----- Original Message ----- 
From: "Glynn Clements" <glynn.clements@virgin.net>
To: <ronkhu@ntsp.nec.co.jp>
Cc: <linux-c-programming@vger.kernel.org>
Sent: Monday, April 28, 2003 10:57 AM
Subject: Re: (non-member) wait-notify mechanism in pthreads


>
> ronkhu wrote:
>
> > Im not a member of this list but I've got a question:
> > How does one go about implementing a wait-notify mechanism in pthreads
> > in lieu of the
> > busy-waiting approach( which tends to be a cpu-hog)?
>
> Mutexes, condition variables, or POSIX semaphores. See the "POSIX
> Threads" section in the "libc" Info file for more details.
>
> -- 
> Glynn Clements <glynn.clements@virgin.net>
> -
> To unsubscribe from this list: send the line "unsubscribe
linux-c-programming" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
>



      reply	other threads:[~2003-04-28 17:02 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-04-28  8:37 (non-member) wait-notify mechanism in pthreads ronkhu
2003-04-28 13:57 ` Glynn Clements
2003-04-28 17:02   ` Luciano Moreira - igLnx [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='016801c30da7$fa4ebeb0$0b00a8c0@SPLUCIANO' \
    --to=lucianolnx@ig.com.br \
    --cc=glynn.clements@virgin.net \
    --cc=linux-c-programming@vger.kernel.org \
    --cc=ronkhu@ntsp.nec.co.jp \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.