Hardware manual
Disks: The Alto File System
This document describes the disk formats used in the Alto File System. It also describes a "disk object," a
Bcpl software construct that is used to interface low-level disk drivers with packages that implement
higher-level objects, such as streams.
The primary focus of the description will be for the "standard" Alto disks: either (1) up to 2 Diablo Model
31 disk drives or (2) one Diablo Model 44 disk drive. The low-level drivers for these disks are called "Bfs"
(Basic File System). With minor modifications, the description below applies to the Trident Model T80
and T300 disk drives, when formatted for Alto file system conventions. The differences are flagged with
the string [Trident]. Low-level drivers for the Trident disks are called "Tfs."
1. Distribution
Relocatable binary files for the BFS are kept in <Alto>BFSBrs.dm. The sources, command files, and test
program (described later in this document) are kept in <AltoSource>BFSSources.dm Relocatable binary
files for the TFS are kept in <Alto>TFS.dm; sources are kept on <AltoSource>TFSSources.dm.
2. File and Disk Structure
This section describes the conventions of the Alto file system. The files AltoFileSys.D and Bfs.D contain
Bcpl structure declarations that correspond to this description ([Trident]: See also "Tfs.D").
The unit of transfer between disk and memory, and hence that of the file system, is the
disk sector. Each
sector has three fields: a 2-word header, an 8-word label, and a 256-word data page. ([Trident]: The fields
are a 2-word header, a 10-word label, and a 1024-word data page.)
A sector is identified by a disk address; there are two kinds of disk addresses, real and virtual. The
hardware deals in real addresses, which have a somewhat arbitrary format. An unfortunate consequence is
that the real addresses for all the pages on a disk unit are sparse in the set of 16 bit integers. To correct this
defect, virtual addresses have been introduced. They have the property that the pages of a disk unit which
holds n pages have virtual addresses 0 ... (n-1). Furthermore, the ordering of pages by virtual address is
such that successive pages in the virtual space are usually sequential on the disk. As a result, assigning a
sequence of pages to consecutive virtual addresses will ensure that they can be read in as fast as possible.
2.1. Legal Alto Files
An Alto file is a data structure that contains two sorts of information: some is mandatory, and is required
for all legal files; the remainder is "hints". Programs that operate on files should endeavor to keep the
hints accurate, but should never depend on the accuracy of a hint.
A legal Alto file consists of a sequence of pages held together by a doubly-linked list recorded in the label
fields. Each label contains the mandatory information:
The forward and backward links, recorded as real disk addresses.
A page number which gives the position of the page in the file; pages are numbered from 0.
A count of the number of characters of data in the page (numchars). This may range from 0 (for a
Disks & Bfs August 10, 1980 51
For Xerox Internal Use Only -- December 15, 1980










