Virtual Memory: 4 VM Chains

Up: GEOS SDK TechDocs | Up | Down | Prev: 3 Using Virtual Memory | Next: 5 Huge Arrays

A VM file is just a collection of blocks. These blocks are not kept in any particular order. If the application wants to keep the blocks in some kind of order, it must set up some mechanism to do this.

One common mechanism is the VM chain. This is simply a way of arranging blocks in a sequence, in which each block contains the handle of the next block. GEOS has a standard format for VM chains and provides utility routines which work with chains of this format.

In general usage, a "chain" is a simple tree in which each block has a link to at most one other block. However, the GEOS VM chain can also contain special "tree blocks," which may have links to any number of child blocks. By using these blocks, an application can set up VM trees of unlimited complexity.


Up: GEOS SDK TechDocs | Up | Down | Prev: 3 Using Virtual Memory | Next: 5 Huge Arrays