Hi Jonas,
thanks very much!!!
I am sorry for the wrong things that I wrote. Now I can clearly see that
the memory is not lost on the FPC heap. The total heap size doesn't even
change at all. So there's no difference with CMem either.
More work to do ...
Cheers,
Tobias
On 26 Oct 2010, at 21:28, Tobias Giesen wrote:
> Upon exit, the memory does seem to be freed correctly now according to
> heaptrc. But MacOS stops giving memory to the app after a while and
> then it quits.
>
> Could it be that the memory manager has been changed since FPC 2.2 and
> is now more
Hello,
I have been making tests all day long and I do not have any conclusive
results. I fixed a small memory leak in my code too. This leak may have
misled me to believe that the compiler has a leak. However after all the
efforts, the application still uses more and more memory while it is
doing
Hi,
I was wrong, UniqueString does not help after all. I am now using an
extended version of the heaptrc unit to show the reference count (and
string value) for unfreed WideStrings and they usually have 1 as a
reference count.
Will keep you posted.
Cheers,
Tobias
Am 26.10.2010 10:55, schrieb Tobias Giesen:
>> A bug may show anytime anywhere, but the built in ref counted string
>> types are AFAIK thread safe what concerns the ref count per se. I
>> suspect a subtle flaw in the client code is more probable.
>
> No, it is a compiler bug. The same code works 1
> A bug may show anytime anywhere, but the built in ref counted string
> types are AFAIK thread safe what concerns the ref count per se. I
> suspect a subtle flaw in the client code is more probable.
No, it is a compiler bug. The same code works 100% perfectly on
Windows using Delphi, as well as
2010/10/26 Tobias Giesen :
> I think the problem might be that Widestring reference counting is not
> thread safe. But it worked fine in FPC 2.2.
A bug may show anytime anywhere, but the built in ref counted string
types are AFAIK thread safe what concerns the ref count per se. I
suspect a subtle
Hi,
I think the problem might be that Widestring reference counting is not
thread safe. But it worked fine in FPC 2.2.
I will add some UniqueString calls and also try to isolate the issue.
Cheers,
Tobias
___
fpc-pascal maillist - fpc-pascal@lists.
On 25 Oct 2010, at 23:25, Tobias Giesen wrote:
> is it possible to turn off reference counting, for a test?
No.
> Is there a difference between UnicodeString and WideString on the
> Mac version (i386) of FPC 2.4 / 2.5?
No. UnicodeString and WideString only differ on Windows.
Jonas
__