From: Giuliano Catrambone <giuliano.catrambone@catrasoftware.it>
To: pthreads-win32@sources.redhat.com
Subject: Windows process very slow using more than one condition variable
Date: Fri, 13 Oct 2006 21:03:00 -0000 [thread overview]
Message-ID: <452FFFF7.20005@catrasoftware.it> (raw)
Hello guys
I have a program which is portable on windows and Linux and I'm
using pthread-win32
for the Windows version.
In my scenario I have one events queue and many threads acceding to
this queue
to get events (consumers) and to add events (producers).
Every event has, as property, the consumer thread type addressee
which has to get the event.
In my implementation I use as many condition variables as the number
of different cunsumer types.
In this way, every time an event for the consumer X is added into
the queue, a pthread_cond_signal
is called on the condition variable where only the consumer X is in
timedwait.
If I have only one consumer type, and then one condition variable,
the process on Windows is very fast
and works fine.
If I have more than one consumer types, and then more than one
condition variables, the process on Windows
is very slow.
BTW, the same code, on linux, works fine also with many consumer
types threads and then many condition variables.
Do you have some ideas why Windows seems works very slow using more
than one condition variables?
Thanks
giu
--
-----------------------------------------------------------------
Giuliano Catrambone
Director, Professional Services
Open source projects:
http://sourceforge.net/projects/catralibraries/
http://sourceforge.net/projects/openstreaming/
CatraSoftware:
Home page: http://www.catrasoftware.it
Streaming page:
http://www.catrasoftware.it/Streaming/CatraStreamingPlatform.htm
Mobile +39.393.8816655
Fixed: +39.02.90377228
Skype: Catrambone Giuliano
msn: giulianocatrambone@hotmail.com
Jabber: giuliano.catrambone@Jabber.org
Yahoo: giuliano.catrambone
-----------------------------------------------------------------
next reply other threads:[~2006-10-13 21:03 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-13 21:03 Giuliano Catrambone [this message]
2006-10-16 13:16 ` Giuliano Catrambone
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=452FFFF7.20005@catrasoftware.it \
--to=giuliano.catrambone@catrasoftware.it \
--cc=pthreads-win32@sources.redhat.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).