[fpc-pascal] Synchronize(dummyproc) with Linux.
Sven Barth
pascaldragon at googlemail.com
Thu May 2 13:51:16 CEST 2013
Am 02.05.2013 13:25, schrieb Fred van Stappen:
> > that is the slowest system (by a big margin) I have
> > available.
>
> Im very interested by the result.
> But i continue to think there is something strange with synchronize().
> In my logic, synchronize(dummyproc) must have NO effect on the parent
> thread.
> And it have.
It seems that you didn't read what I wrote. Synchronize always blocks
until the given method was executed by the main thread. So even if your
method is empty there will be a delay until the mainthread processes the
synchronized method. And the more busy the main thread is (e.g. updating
the GUI) the more time it takes until it can process a synchronized
message. Also multiple Synchronize events will be executed in multiple
runs of CheckSynchronize runs, because the "queue" in pre-2.7.1 can only
hold one element. In 2.7.1 the queue can hold multiple methods enqueue
by Synchronize and Queue.
Regards,
Sven
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20130502/5c488884/attachment.html>
More information about the fpc-pascal
mailing list