#1 Re: Source Code repository » SynScaleMM - fast scaling memory manager for Delphi » 2018-01-17 16:55:25

Thanks. That was one approach I considered. But it looks like the changes were intended to avoid conditions where these pointers are freed after the memory manager is unregistered from system.pas, so rather than patch it at runtime to force it to go through my MM, I just recompiled system.pas to fix the bug...

#2 Re: Source Code repository » SynScaleMM - fast scaling memory manager for Delphi » 2018-01-17 13:43:27

TMonitor is being used many places in rtl now. I just did a search for TMonitor.Enter under source\rtl\sys -- there's a lot! If you use a third party memory manager and do any multi-thread code in 10.2.2, you can only avoid the bug if TMonitor.Enter is never called on a locked object...

#3 Re: Source Code repository » SynScaleMM - fast scaling memory manager for Delphi » 2018-01-17 05:15:44

Turns out this is a bug in System.pas.  I worked out the fix, but it requires rebuilding system.pas.

You might vote for the report here so they will hopefully release a hotfix. Pretty major bug for anyone using a different memory manager from GETMEM.INC.

https://quality.embarcadero.com/browse/RSP-19777

#4 Re: Source Code repository » SynScaleMM - fast scaling memory manager for Delphi » 2018-01-17 02:37:17

Starting with Delphi Tokyo 10.2.2, there is an instability with this. Seems that a change in the RTL might be the cause. With significant thread creation, there are access violations on TMonitor.Destroy and also in GetMonitor... I am wondering if anyone else is experiencing this and what might be done to resolve it. It is not very simple to experiment with changes in system.pas. :-(  Didn't have any trouble in Tokyo 10.2.1.

Board footer

Powered by FluxBB