Unit 2: Instructions: Hardware Language
In order to understand computer architecture, you need to understand the components that comprise a computer and their interconnections. Sets of instructions, called programs, describe the computations that computers carry out. The instructions are strings of binary digits. When symbols are used for the binary strings, the instructions are called assembly language instructions. Components interpret the instructions and send signals to other components that cause the instruction to be carried out.
In this unit, you will build on your knowledge of programming from CS102 to learn how to program with an assembly language. You will use the instructions of a real processor, MIPS, to understand the basics of hardware language. We will also discuss the different classes of instructions typically found in computers and compare the MIPS instructions to those found in other popular processors made by Intel and ARM.
Completing this unit should take you approximately 12 hours.
2.1: Computer Hardware Operations
Study these lecture notes to learn about the basic operations, or machine instructions, of a computer processor.
2.2: Number Representation in Computers
Read through slide 37. These slides explain how numbers are represented, i.e., encoded by using a string of bits - or binary digits. These lecture notes also describe how the sign of a number is represented and how 2's complement representation. Finally, skim slides 38-88 to get a basic understanding of what they cover: redundant number systems and residue number systems. This material may or may not be difficult, depending on your mathematical background; make sure to take your time as you study this material.
Read this chapter on numeration systems. This is an alternative reading for number representation used for digital hardware devices.
2.3: Instruction Representation
Read this article for an introduction to the three different instruction formats for the MIPS processor: the R-Format, the I-Format, and the J-Format instructions. MIPS is an acronym that stands for Microprocessor Instructions without Interlocked Pipeline Stages. MIPS is a RISC (Reduced Instruction Set Computer) introduced by MIPS technologies. Also, ISA, if you encounter it, stands for Instruction Set Architecture.
2.4: Logical and Arithmetic Instructions
Read this article to learn about arithmetic and logical instructions for the MIPS processor.
2.5: Control Instructions
Read this article to learn about the control flow instructions for the MIPS processor, including the basic ones: jump and branch instructions.
2.6: Instructions for Memory Operations
Read this article to learn about memory instructions for the MIPS processor.
2.7: Different Modes for Addressing Memory
Read this article to study the various formats for addressing memory.
MIPS assembly is an assembly language, which is a mnemonic or meaningful code for the machine language format in computer programming. Read this section to get a sense of how the addresses to memory are coded in a MIPS microprocessor.
2.8: Case Study: Intel and ARM Instructions
Read this article. This article and the following provide two examples of instructions set architectures (ISAs). Look over how the different microprocessors address memory. Take note of similarities and differences of format, instructions and type of instructions, and addressing modes between these two as well as between these and the MIPS instructions of the previous sections.
Read this article. It and the previous provide two examples of instructions set architectures (ISAs). Look over how the different microprocessors address memory. Take note of similarities and differences of format, instructions and type of instructions, and addressing modes between these two as well as between these and the MIPS instructions of the previous sections.
Unit 2 Assessment
Please take this assessment to check your understanding of the materials presented in this unit.
Notes:
- There is no minimum required score to pass this assessment, and your score on this assessment will not factor into your overall course grade.
- This assessment is designed to prepare you for the Final Exam that will determine your course grade. Upon submission of your assessment you will be provided with the correct answers and/or other feedback meant to help in your understanding of the topics being assessed.
- You may attempt this assessment as many times as needed, whenever you would like.