Home Up Honesty in History Sequence Detector
Home Teaching Glossary ARM Processors Supplements Prof issues About

THE COMPUTER HIERARCHY

We can look at complex systems at different levels of abstraction. For example, the human being can be viewed at one level by a psychiatrist, at another level by a surgeon, and at the third level by a microbiologist. Note the hierarchical nature of these levels. The cells build the organs and structure of a human, and the brain (constructed from cells) provides the highest level of abstraction, human consciousness. The computer can be divided into nine levels of abstraction at Figure 1 shows.























Figure 1 The computer as an abstraction

At the core of Figure 1 are the atoms from which the computer is made. These were fabricated in the heart of a star a long time ago, and then refined and converted into the semiconductor used to fabricate a chip. The next layer out is the device layer (labeled transistors) that is concerned with the electronic switches that make up a digital circuit. The chip and circuit designer is interested in this layer.

Above the transistor layer is the gates layer. Gates are the basic building blocks of any digital system and are the subject of Chapter 2. The next layer is the microarchitecture layer. This layer uses gates to implement the computer itself. This is the layer that we are concerned with in chapters 7 and 8. Operations at the microarchitecture level include actions such as  moving data into a register or adding numbers in an arithmetic and logic unit.

The microarchitecture implements the ISA or instruction set architecture in the next layer. It is this layer that defines the computer in terms of its instruction set and operational characters. This layer determines the type or family of a chip; for example, it distinguishes between an Intel IA32 processor and an ARM or MIPS processor. It is entirely possible for an IA32 chip and an ARM chip to have identical inner layers from atoms to microarchitecture, but different ISAs. The ISA layer is also described as the programmer’s view of the chip. Chapter 3 introduces the microarchitecture layer.

The barrier between the ISA and assembly language layers is depicted as a bold line. Everything within the bold line is part of a chip’s hardware and cannot be changed by the programmer or user. However, some chips do now include programmable logic which makes it possible to alter the gate and microarchitecture layers.

The first layer outside the barrier is the assembly language layer. This layer is the human representation of the instruction set architecture; for example, the binary sequence 0000101110100111 may be the machine code that is interpreted by the microarchitecture as ADD r0,r1,r2 (add two registers to a third).

In many ways you could argue that the ISA and assembly language layers are the same; the only difference being that one is meaningful to humans because it is written in a textual notation. However, that is not the whole story. An assembler can make life simpler for the programmer by providing facilities such as macros and conditional assembly. The assembly language can often provide shortcuts by letting the programmer write instructions that don’t actually exist, and then translating them into real instructions. We look at this in Chapter 3 when we introduce the ARM.

Above the assembly language layer is the operating system layer. This layer is different to all the other layers because it controls the system and its resources. It is not necessary to have an operating system in a dedicated computer that performs a single function. Moreover, you could argue that the operating system should be above the high-level language layer or even the application layer.

The penultimate layer is the high-level language layer that interprets operations in a form such as IF x < 3 THEN y = y + 4. The high-level language is machine-independent, because a compiler is used to translate a program in high-level language into the appropriate assembly language (or machine code) for a target processor. That is, programmers can write high-level language code without worrying about the target processor.

Finally, the outermost layer is the applications layer. This is the only layer of interest to the user. A programmer writes a program in a high-level language to carry out some application. In this example, the function is Ng1-f3 Qg5xg3+ which represents a pair of movements in chess. At this level the user sees no difference between a machine that is a dedicated chess player and one that is a computer running a program.


Abstraction

Like any other discipline, computer science has its own special vocabulary that distinguishes its followers from other mortals. One such key word in computer science is abstraction.

The dictionary definition of abstraction defines it as “a general term or idea” or “the act of considering something as a general characteristic free from actual instances”.  In computer science abstraction is concerned with separating meaning from implementation. In everyday life we could say that the word “go” was an abstraction because it hides the specific instance (go by walking, cycling, riding, flying).

Abstraction is an important concept because it separates what we do from how we do it. This is an important concept because it helps us to build complex systems by decomposing them into subtasks or activities.