DelphiTools – …or why you can’t hide under the complexity carpet As uncovered in previous episodes, one of the keys behind TMonitor performance issues is that it allocates a dynamic block of memory for its locking purposes, and when those blocks end up allocated on the same CPU cache line, the two TMonitor on the same cache line will end up fighting for the cache line, resulting in a drastic drop of performance and thread contention. The technical term for that behavior is false sharing. A quick fix that can come to mind would be to force the allocation of TMonitor’s blocks early on, so ...
Visits by Source
Users who voted for this posting