ArticleslgStudy

computer science

Simple-As-Possible computer

Simple-As-Possible computer is a computer science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Simple-As-Possible computer rather than just read about it. In short: The Simple-As-Possible (SAP) computer is a simplified computer architecture designed for educational purposes and described in the 1993 book Digital Computer Electronics by Albert Paul Malvino and Jerald A. Brown.

Simple-As-Possible computer — main illustration
Simple-As-Possible computer — illustration

Key takeaways

  • Simple-As-Possible computer belongs to computer science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Simple-As-Possible computer to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Simple-As-Possible computer from memory before moving on to harder problems.

Reference excerpt

The Simple-As-Possible (SAP) computer is a simplified computer architecture designed for educational purposes and described in the 1993 book Digital Computer Electronics by Albert Paul Malvino and Jerald A. Brown. The SAP architecture serves as an example in Digital Computer Electronics for building and analyzing complex logical systems with digital electronics. Digital Computer Electronics successively develops three versions of this computer, designated as SAP-1, SAP-2, and SAP-3. Each of the last two build upon the immediate previous version by adding additional computational, flow of control, and input/output capabilities. SAP-2 and SAP-3 are fully Turing-complete. The instruction set architecture (ISA) that the computer final version (SAP-3) is designed to implement is patterned after and upward compatible with the ISA of the Intel 8080/8085 microprocessor family. Therefore, the instructions implemented in the three SAP computer variations are, in each case, a subset of the 8080/8085 instructions.

Variants

Ben Eater's Design

YouTuber and former Khan Academy employee Ben Eater created a tutorial building an 8-bit Turing-complete SAP computer on breadboards from logical chips (7400-series) capable of running simple programs such as computing the Fibonacci sequence. Eater's design consists of the following modules:

An adjustable-speed (upper limitation of a few hundred Hertz) clock module that can be put into a "manual mode" to step through the clock cycles. Three register modules (Register A, Register B, and the Instruction Register) that "store small amounts of data that the CPU is processing." An arithmetic logic unit (ALU) capable of adding and subtracting 8-bit 2's complement integers from registers A and B. This module also has a flags register with two possible flags (Z and C). Z stands for "zero," and is activated if the ALU outputs zero. C stands for "carry," and is activated if the ALU produces a carry-out bit. A RAM module capable of storing 16 bytes. This means that the RAM is 4-bit addressable. As Eater's website puts it, "this is by far its [the computer's] biggest limitation". A 4-bit program counter that keeps track of the current processor instruction, corresponding to a 4-bit addressable RAM. An output register that displays its content on four 7-segment displays, capable of displaying both unsigned and 2's complement signed integers. The 7-segment display outputs are controlled by EEPROMs, which are programmed using an Arduino microcontroller. A bus that connects these components together. The components connect to the bus using tri-state buffers. A "control logic" module that defines "the opcodes the processor recognizes and what happens when it executes each instruction," as well as enabling the computer to be Turing-complete. The CPU microcodes are programmed into EEPROMs using an Arduino microcontroller. Ben Eater's design has inspired multiple other variants and improvements, primarily on Eater's Reddit forum. Some examples of improvements are:

An expanded RAM module capable of storing 256 bytes, utilizing the entire 8-bit address space. With the help of segmentation registers, the RAM module can be further expanded to a 16-bit address space, matching the standard for 8-bit computers. A stack register that allows incrementing and decrementing the stack pointer.

References

External links SAP-1 online simulator (in English, Spanish and Catalan) Design and Implementation of a Simple-As-Possible 1 (SAP-1) Computer using an FPGA and VHDL An implementation of Simple As Possible computer - SAP1, written in VHDL (in English and Portuguese) SAP-1 simulation using Digital Works (in English and Portuguese) Some of Ben Eater's computer videos including the 8-bit computer.

Worked examples

Example 1 — a first encounter with Simple-As-Possible computer

Start with the simplest possible case. Write down what Simple-As-Possible computer claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In computer science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Simple-As-Possible computer before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Simple-As-Possible computer ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Simple-As-Possible computer

In research
Simple-As-Possible computer appears in computer science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Simple-As-Possible computer in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Simple-As-Possible computer is common in secondary-school and first-year university syllabi. It links to neighbouring topics Computer architecture, so understanding it makes those chapters shorter.
In everyday life
Look for Simple-As-Possible computer outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.

Affiliate

Preply — study more efficiently by working with a personal tutor. 50% off.

How to study Simple-As-Possible computer in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Simple-As-Possible computer means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Simple-As-Possible computer out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Simple-As-Possible computer in simple terms?

The Simple-As-Possible (SAP) computer is a simplified computer architecture designed for educational purposes and described in the 1993 book Digital Computer Electronics by Albert Paul Malvino and Jerald A. Brown.

Why does Simple-As-Possible computer matter?

Because it connects several computer science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Simple-As-Possible computer?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Simple-As-Possible computer.

Tags

  • Computer architecture

Keep exploring