U++ framework
Do not panic. Ask here before giving up.

Home » U++ Library support » ArrayCtrl, HeaderCtrl & GridCtrl » GridControl release memory (GridCtrl unable to reset memory usage)
Re: GridControl release memory [message #49064 is a reply to message #49063] Mon, 11 December 2017 10:27 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 14290
Registered: November 2005
Ultimate Member
chis.adrian wrote on Mon, 11 December 2017 10:06
Thank You,
I understand I was afraid of this answer since I saw on other C,C++ Grid,Table ... implementations.

Anyway is there a way to access Grids Vector<Vector (Exposed) so I can try shrink it my self?
I already done it in a C program and new C++ has std::vector::shrink_to_fit maybe I can use it.




Ah, you do not understand. That would not help. Memory is correctly released, there are no leaks and nothing to be shrunk.

However, that released memory is kept in reserve by U++ memory management subsystem (aka "memory allocator") for further allocations.

The reason is that a) retrieving memory from system is somewhat expensive b) U++ allocator "formats" memory blocks, which is something that can be avoided if memory is kept in reserve instead being returned to the system and then retrieved again

(and then there is that technical problem with Win32, which only allows limited granularity)
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: GridCtrl
Next Topic: SOLVED: Array and Grid on high definition monitor
Goto Forum:
  


Current Time: Sat Apr 25 23:35:05 GMT+2 2026

Total time taken to generate the page: 0.00803 seconds