multithreading - Multi-threaded access of components in Delphi -


Can you suggest an approach when design-time components are given to the general code (VCL or others) and myself Threads? The problem is that when I have complete control over my sources, then I know that when I should use Mutex. In the case of design time elements, I have no control over the code related to the least VCL. One variant has to wrap the handle message in the Mute X access code. The idea behind this is that all the things related to VCL are from the message processing code (exception is straight sendase handling), but seeing the sources, I did not find any "official" way to handle messages in any kind of code piece.

Do not try to go there too. For Google to "Global Interpreter Lock" (Python-specific) to see that a bad habit is such a hurdle.

If you need access to the data, try to minimize lock access as much as possible, and lock you do not need any higher in the call range. If you have objects used with many threads, then synchronize them within their way.


Comments

Popular posts from this blog

c# - How to capture HTTP packet with SharpPcap -

php - Multiple Select with Explode: only returns the word "Array" -

php - jQuery AJAX Post not working -