Jump to content

Block allocation map

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Dexter Nextnumber (talk | contribs) at 21:28, 7 December 2009 (Added info on what a BAM is. Also added a link to "Commodore DOS"). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
File:View BAM.gif
Here, the View BAM utility on the Commodore 1541 Test/Demo Disk is displaying a portion of the block allocation map for that disk.

In computer file systems, a block allocation map (BAM) is a data structure used to track disk blocks that are considered "allocated" or "free for writing."

Very rapid file access was made possible by consulting a Block Allocation Map only when it absolutely had to (that is, when writing), and ignoring it when reading. This arguably made writing to the disk more time consuming than reading. Nonetheless, the difference between reading and writing was negligible when taking into account the time involved waiting for the medium to speed up, and synchronize into position. Regardless of whether the medium was a 5.25 inch floppy diskette, or a 3.5 inch 'semi-rigid' diskette, most of the time was spent waiting for the medium to get into place before reading or writing was suitable.

In terms of Commodore Business Machines compatible Disk Drives, the BAM was located at a different physical track and sector on each of the Commodore 1541, Commodore 1571, and Commodore 1581 disk drives. It is not the same thing as a simple bitmap because it actually involves a series of 1 byte counters (denoting how many blocks are free on that track) and a bitmap (which sectors on that track are allocated, and which are free).

See also