From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,2caa964596702891,start X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!postnews.google.com!m73g2000cwd.googlegroups.com!not-for-mail From: msimonides@power.com.pl Newsgroups: comp.lang.ada Subject: Ada.Containers and Storage_Pools Date: 9 Aug 2006 05:04:00 -0700 Organization: http://groups.google.com Message-ID: <1155125040.715167.132300@m73g2000cwd.googlegroups.com> NNTP-Posting-Host: 62.111.211.178 Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: posting.google.com 1155125046 11269 127.0.0.1 (9 Aug 2006 12:04:06 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Wed, 9 Aug 2006 12:04:06 +0000 (UTC) User-Agent: G2/0.2 X-HTTP-UserAgent: Opera/9.00 (X11; Linux i686; U; en),gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: m73g2000cwd.googlegroups.com; posting-host=62.111.211.178; posting-account=YHdqRw0AAAAIPYzcJprg4QGlRlBwcPu_ Xref: g2news2.google.com comp.lang.ada:6103 Date: 2006-08-09T05:04:00-07:00 List-Id: I'm working on a caching DNS resolver for our project. The structures used to hold data in cache make use of Ada.Containers packages (e.g. each node stores a map of list resource records for each data type, so there is a lot of individual containers). Currently we're using Containers that come with GNAT 3.4.5 but we plan to move to Ada 2005 containers in newer GNAT. The problem I'm facing (and that is certain to show up in other parts of our project) is that I need to limit the size of cache in memory. To do this I would need to be able to have the containers allocate their nodes from a user-specified storage pool with some limiting mechanism (I already have such a pool and use it for objects that are allocated by my code). So I have a question: is there a possibility, either in GNAT 3.4.5 or in Ada 2005, to specify a custom storage pool for use by containers? If not, is there any other solution to limiting the size of memory used by containers? The only solution that I have found is using some other containers library (I've seen that Booch components allow for specifying custom storage pools), but I'd really prefer to stick with the standard ones. -- Marcin Simonides