comp.lang.ada
 help / color / mirror / Atom feed
* Allocation from storage pools
@ 1999-06-28  0:00 Andy Askey
  1999-06-28  0:00 ` Jeffrey D. Cherry
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Andy Askey @ 1999-06-28  0:00 UTC (permalink / raw)


I am trying to figure out the best method (most efficient-least runtime
hit) to allocate/deallocate memory to dynamic objects.  Here is what I
want to do, in general:

1) Grab a chunk of memory during program initialization to serve as a
dynamic allocation pool for subsequent object memory allocation.

2) Allocate new objects (various types) from the previous allocated
chunk of memory.  I'd like to do something like this:

  newobj := new newobj_type; (or some form like that, not necessarily
overloading new, that grabs memory from the chunk)

3) Deallocate the objects when I am done with in (freeing up the memory
from the big chunk).

I am developing in Apex Ada95 on a Solaris OS.  I found some
documentation about this in
System.Storage_Pools.Rational.Storage_Pools.  I do not really want to
use something that is Apex specific.

My questions:

Does Ada95 give me anything I can use to implement 1,2,&3 above?  I can
write my own code fairly easily to do this, but I want to take advantage
of anything already provided by Ada95.

Any help on this topic will be greatly appreciated.

Thanx.
Andy

-- 
---------------------------------------------------
|                 Andy Askey                      |
|              Software Engineer                  |
|           Raytheon Systems Company              |
|   670 Discovery Drive, Huntsville, AL  35806    |
|   Phone: (256) 971-2367  Fax: (256) 971-2306    |
|        andrew_j_askey@res.raytheon.com          |
---------------------------------------------------




^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~1999-07-01  0:00 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-06-28  0:00 Allocation from storage pools Andy Askey
1999-06-28  0:00 ` Jeffrey D. Cherry
1999-06-29  0:00 ` JClezy
1999-06-29  0:00   ` Jeffrey D. Cherry
1999-07-01  0:00 ` Andy Askey

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox