Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2012-04

heaptrc question

4 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Carver Carver

I am experiencing strange heaptrc output can someone please explain what sort of error could trigger this

Heap dump by heaptrc unit
6590 memory blocks allocated : 6484894/6508528
6590 memory blocks freed     : 6484894/6508528 0 unfreed memory blocks : 0
True heap size : 229376
True free heap : 282512
Should be : 229376

Reply by email

Jonas Maebe
to Carver Carver
Carver Carver wrote 9 lines
I am experiencing strange heaptrc output can someone please explain what sort of error could trigger this Heap dump by heaptrc unit 6590 memory blocks allocated : 6484894/6508528 6590 memory blocks freed : 6484894/6508528 0 unfreed memory blocks : 0 True heap size : 229376 True free heap : 282512 Should be : 229376

Unless heap trace reports that there are unfreed blocks, there is no error. The fact that the other numbers don't match up exactly is due to allocations that occur before the heaptrc unit is initialized (e.g., in the startup code of the system unit).

Jonas

Reply by email

Carver Carver
to Jonas Maebe

thanks for the reply, but it doesn't really explain why this error is suddenly occurring. I am working on a layout manager to control pages within a form. when the first page is added to the first manager no problem. a second page to the first manager no problem. a second page to the second manager the error occurs and continues to grow with each page added. there is no difference code wise just different managers 

________________________________

Earlier message 24 lines
From: Jonas Maebe To: Carver Carver ; FPC-Pascal users discussions Sent: Friday, April 27, 2012 9:53 AM Subject: Re: [fpc-pascal] heaptrc question On 27 Apr 2012, at 17:50, Carver Carver wrote: > I am experiencing strange heaptrc output can someone please explain what sort of error could trigger this > > Heap dump by heaptrc unit > 6590 memory blocks allocated : 6484894/6508528 > 6590 memory blocks freed    : 6484894/6508528 > 0 unfreed memory blocks : 0 > True heap size : 229376 > True free heap : 282512 > Should be : 229376 Unless heap trace reports that there are unfreed blocks, there is no error. The fact that the other numbers don't match up exactly is due to allocations that occur before the heaptrc unit is initialized (e.g., in the startup code of the system unit). Jonas_______________________________________________ fpc-pascal maillist  -  http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply by email

Reinier Olislagers
to Carver Carver
Carver Carver wrote 6 lines
thanks for the reply, but it doesn't really explain why this error is suddenly occurring. I am working on a layout manager to control pages within a form. when the first page is added to the first manager no problem. a second page to the first manager no problem. a second page to the second manager the error occurs and continues to grow with each page added. there is no difference code wise just different managers

Maybe it's a good idea to indicate you're crossposting to the forum and the FPC mailing list...

Also, giving your FPC,Lazarus version, OS,widgetset may help people in answering your questions...

Anyway, I think Jonas indicated the heaptrc output you gave is NOT an error... so perhaps you can expand on what the error you're seeing??

Regards,
Reinier

Reply by email