Burroughs Large Systems - Stack Architecture

Stack Architecture

In many early systems and languages, programmers were often told not to make their routines too small. Procedure calls and returns were expensive, because a number of operations had to be performed to maintain the stack. The B5000 was designed as a stack machine – all program data except for arrays (which include strings and objects) was kept on the stack. This meant that stack operations were optimized for efficiency. As a stack-oriented machine, there are no programmer addressable registers.

Multitasking is also very efficient on B5000 machines. There is one specific instruction to perform process switches – MVST (move stack). Each stack represents a process (task or thread) and tasks can become blocked waiting on resource requests (which includes waiting for a processor to run on if the task has been interrupted because of preemptive multitasking). User programs cannot issue an MVST, and there is only one line of code in the operating system where this is done.

So a process switch proceeds something like this – a process requests a resource that is not immediately available, maybe a read of a record of a file from a block which is not currently in memory, or the system timer has triggered an interrupt. The operating system code is entered and run on top of the user stack. It turns off user process timers. The current process is placed in the appropriate queue for the resource being requested, or the ready queue waiting for the processor if this is a preemptive context switch. The operating system determines the first process in the ready queue and invokes the instruction move_stack, which makes the process at the head of the ready queue active.

Read more about this topic:  Burroughs Large Systems

Famous quotes containing the words stack and/or architecture:

    “Farewell to barn and stack and tree,
    Farewell to Severn shore.
    Terence, look your last at me,
    For I come home no more.
    —A.E. (Alfred Edward)

    And when his hours are numbered, and the world
    Is all his own, retiring, as he were not,
    Leaves, when the sun appears, astonished Art
    To mimic in slow structures, stone by stone,
    Built in an age, the mad wind’s night-work,
    The frolic architecture of the snow.
    Ralph Waldo Emerson (1803–1882)