Glossary · Automation software engineering and architecture
Memory pool
Also known as: Fixed-size block allocation, Memory partition
German: Speicherpool
In embedded and real-time software, a memory pool is a region of memory reserved at startup and divided into blocks, usually of fixed size, that the program takes and returns at run time instead of using general heap allocation.
- Software engineering
In one sentence
A memory pool is memory reserved at startup and split into blocks that software takes and returns at run time, with predictable timing.
Example
The fieldbus stack of a drive reserves a pool of 64 message buffers at boot and reuses them for every telegram, so allocation time stays constant.
How it applies
- Engineering: Pools give deterministic allocation time and avoid fragmentation, which is why many Real-time operating system (RTOS) kernels offer them. The pool size must cover the worst case; if the pool is empty, the software needs a defined reaction.
- Verification: Tests should drive the system to pool exhaustion and check the behavior, for example that messages are rejected with a diagnostic instead of the controller stopping.
- Documentation: Where pool sizes limit what users can configure (number of connections, queued messages), state the limits in the technical data and describe the diagnostic message shown when they are reached.
Memory pool vs. heap
The heap serves requests of any size from one shared area, which is flexible but can fragment and has variable timing. A memory pool trades flexibility for predictability: fixed block sizes and a known maximum number of blocks.