30.12.2013 Views

T-Kernel Specification (1.B0.02)

T-Kernel Specification (1.B0.02)

T-Kernel Specification (1.B0.02)

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

4.6. MEMORY POOL MANAGEMENT FUNCTIONS 147<br />

4.6.1 Fixed-size Memory Pool<br />

A fixed-size memory pool is an object used for dynamic management of fixed-size memory blocks.<br />

Functions are provided for creating and deleting a fixed-size memory pool, getting and returning memory<br />

blocks in a fixed-size memory pool, and referencing the status of a fixed-size memory pool. A fixed-size<br />

memory pool is an object identified by an ID number called a fixed-size memory pool ID.<br />

A fixed-size memory pool has a memory space used as the fixed-size memory pool (called a fixedsize<br />

memory pool area or simply memory pool area), and a queue for tasks waiting for memory block<br />

allocation. A task wanting to allocate a memory block from a fixed-size memory pool that lacks sufficient<br />

available memory space goes to WAIT state for fixed-size memory block until memory blocks are returned<br />

to the pool. A task in this state is put in the task queue of the fixed-size memory pool.<br />

[Additional Notes]<br />

When memory blocks of various sizes are needed from fixed-size memory pools, it is necessary to provide<br />

multiple memory pools of different sizes.<br />

Copyright c○ 2002, 2003 by T-Engine Forum<br />

T-<strong>Kernel</strong> <strong>1.B0.02</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!