1 <html><head><meta http-equiv=
"Content-Type" content=
"text/html; charset=UTF-8"><title>Chapter
20. The mt_allocator
</title><meta name=
"generator" content=
"DocBook XSL-NS Stylesheets V1.76.1"><meta name=
"keywords" content=
"
5 "><meta name=
"keywords" content=
"
9 "><meta name=
"keywords" content=
"
15 "><link rel=
"home" href=
"../index.html" title=
"The GNU C++ Library"><link rel=
"up" href=
"extensions.html" title=
"Part III. Extensions"><link rel=
"prev" href=
"bk01pt03ch19s07.html" title=
"Diagnostics"><link rel=
"next" href=
"bk01pt03ch20s02.html" title=
"Design Issues"></head><body bgcolor=
"white" text=
"black" link=
"#0000FF" vlink=
"#840084" alink=
"#0000FF"><div class=
"navheader"><table width=
"100%" summary=
"Navigation header"><tr><th colspan=
"3" align=
"center">Chapter
20. The mt_allocator
</th></tr><tr><td width=
"20%" align=
"left"><a accesskey=
"p" href=
"bk01pt03ch19s07.html">Prev
</a> </td><th width=
"60%" align=
"center">Part III.
18 </th><td width=
"20%" align=
"right"> <a accesskey=
"n" href=
"bk01pt03ch20s02.html">Next
</a></td></tr></table><hr></div><div class=
"chapter" title=
"Chapter 20. The mt_allocator"><div class=
"titlepage"><div><div><h2 class=
"title"><a name=
"manual.ext.allocator.mt"></a>Chapter
20. The mt_allocator
</h2></div></div></div><div class=
"toc"><p><b>Table of Contents
</b></p><dl><dt><span class=
"section"><a href=
"mt_allocator.html#allocator.mt.intro">Intro
</a></span></dt><dt><span class=
"section"><a href=
"bk01pt03ch20s02.html">Design Issues
</a></span></dt><dd><dl><dt><span class=
"section"><a href=
"bk01pt03ch20s02.html#allocator.mt.overview">Overview
</a></span></dt></dl></dd><dt><span class=
"section"><a href=
"bk01pt03ch20s03.html">Implementation
</a></span></dt><dd><dl><dt><span class=
"section"><a href=
"bk01pt03ch20s03.html#allocator.mt.tune">Tunable Parameters
</a></span></dt><dt><span class=
"section"><a href=
"bk01pt03ch20s03.html#allocator.mt.init">Initialization
</a></span></dt><dt><span class=
"section"><a href=
"bk01pt03ch20s03.html#allocator.mt.deallocation">Deallocation Notes
</a></span></dt></dl></dd><dt><span class=
"section"><a href=
"bk01pt03ch20s04.html">Single Thread Example
</a></span></dt><dt><span class=
"section"><a href=
"bk01pt03ch20s05.html">Multiple Thread Example
</a></span></dt></dl></div><p>
19 </p><div class=
"section" title=
"Intro"><div class=
"titlepage"><div><div><h2 class=
"title" style=
"clear: both"><a name=
"allocator.mt.intro"></a>Intro
</h2></div></div></div><p>
20 The mt allocator [hereinafter referred to simply as
"the allocator"]
21 is a fixed size (power of two) allocator that was initially
22 developed specifically to suit the needs of multi threaded
23 applications [hereinafter referred to as an MT application]. Over
24 time the allocator has evolved and been improved in many ways, in
25 particular it now also does a good job in single threaded
26 applications [hereinafter referred to as a ST application]. (Note:
27 In this document, when referring to single threaded applications
28 this also includes applications that are compiled with gcc without
29 thread support enabled. This is accomplished using ifdef's on
30 __GTHREADS). This allocator is tunable, very flexible, and capable
33 The aim of this document is to describe - from an application point of
34 view - the
"inner workings" of the allocator.
35 </p></div></div><div class=
"navfooter"><hr><table width=
"100%" summary=
"Navigation footer"><tr><td width=
"40%" align=
"left"><a accesskey=
"p" href=
"bk01pt03ch19s07.html">Prev
</a> </td><td width=
"20%" align=
"center"><a accesskey=
"u" href=
"extensions.html">Up
</a></td><td width=
"40%" align=
"right"> <a accesskey=
"n" href=
"bk01pt03ch20s02.html">Next
</a></td></tr><tr><td width=
"40%" align=
"left" valign=
"top">Diagnostics
</td><td width=
"20%" align=
"center"><a accesskey=
"h" href=
"../index.html">Home
</a></td><td width=
"40%" align=
"right" valign=
"top"> Design Issues
</td></tr></table></div></body></html>