2005/9/27, Lefteris Tsintjelis <[EMAIL PROTECTED]>:
> Hi,
>
>      What makes me wonder is that the same test, with the code
> stripped down, to my surprise, is significantly faster that the
> multi threaded one, no matter how many times I run the tests. I am
> including the code for both tests I run.
>      Since I couldn't find a good example of mutex locking the
> following one is something that worked for me. However, I am not
> sure if its as optimized as it should be, so I would appreciate an
> expert's opinion about this. Is this a good example of mutex
> locking? Are there any other better ways for this? Is this an OS
> or MySQL issue? I am currently running 4.1.14 on a FreeBSD5 box.

You ran several queries with multiple thread, fine, but they are all
serialised over one connection, so you get all the overhead of locking
and thread-creation, for no advantage... So that's the result
expected.
(So, yes forthe troll, it's an OS issue, threads creation are somewhat
slow on FreeBSD :)

--
Pooly
Webzine Rock : http://www.w-fenec.org/

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to