Jump to content

  • Log In with Google      Sign In   
  • Create Account

FREE SOFTWARE GIVEAWAY

We have 4 x Pro Licences (valued at $59 each) for 2d modular animation software Spriter to give away in this Thursday's GDNet Direct email newsletter.


Read more in this forum topic or make sure you're signed up (from the right-hand sidebar on the homepage) and read Thursday's newsletter to get in the running!


fast memory manager


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
5 replies to this topic

#1 Pooya65   Members   -  Reputation: 121

Like
0Likes
Like

Posted 02 August 2013 - 10:34 AM

hello

 

i want a fast memory allocation library or alogritm  that supports multithreading ( before it i try some library like as ned malloc and doug lea). are u know any other library or alogrithm ?



Sponsor:

#2 DemonRad   Members   -  Reputation: 290

Like
1Likes
Like

Posted 02 August 2013 - 11:47 AM

http://goog-perftools.sourceforge.net/doc/tcmalloc.html

The only reason why I still not used it is that in my applications I really don't need complex allocations and I tend to use a simple custom pool allocator. Otherwise I think TCmalloc is what you need


Edited by DemonRad, 02 August 2013 - 11:49 AM.

Peace and love, now I understand really what it means! Guardian Angels exist! Thanks!


#3 Ameise   Members   -  Reputation: 766

Like
0Likes
Like

Posted 02 August 2013 - 01:18 PM

I use http://www.gii.upv.es/tlsf/ TLSF personally



#4 Adam_42   Crossbones+   -  Reputation: 2619

Like
1Likes
Like

Posted 03 August 2013 - 02:41 PM

A general purpose allocator will usually be slower than something written specifically for the problem you have, because you can use knowledge of the allocation pattern to speed it up.

 

For example if you can avoid allocating memory one one thread, and freeing it on another you can save on a bunch of expensive synchronization by giving each thread it's own heap.



#5 Matt-D   Crossbones+   -  Reputation: 1469

Like
1Likes
Like

Posted 03 August 2013 - 03:38 PM

Intel TBB, http://threadingbuildingblocks.org/, has some potentially useful building blocks: http://threadingbuildingblocks.org/docs/doxygen/a00426.html

 

For example, take a look at the "Multi-threaded memory allocators" section in the "Optimizing Game Architectures" article:

http://software.intel.com/en-us/articles/optimizing-game-architectures-with-intel-threading-building-blocks


Edited by Matt-D, 03 August 2013 - 03:40 PM.


#6 Radikalizm   Crossbones+   -  Reputation: 2989

Like
3Likes
Like

Posted 03 August 2013 - 03:41 PM

hello

 

i want a fast memory allocation library or alogritm  that supports multithreading ( before it i try some library like as ned malloc and doug lea). are u know any other library or alogrithm ?

 

Is memory allocation actually causing a bottleneck in your code, or do you just want to drop in a different memory allocator for the sake of having one?

If memory allocation actually is causing performance problems you should first have a look at how you are allocating and freeing memory throughout your code.

 

Are you doing a lot of (small) allocations which get freed right afterwards?

Could you maybe remove some free store allocations in favor of stack allocations?

Is there a possibility of allocating a bunch of memory up front an re-using this pool of memory throughout your application?

 

Always try to look for solutions to your problems higher up before you try to mess with these lower level mechanics, you might be causing more problems than you're solving.


I gets all your texture budgets!





Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS