Computer Organization and Design Course PDF

Summary

These lecture notes provide a high-level overview of computer organization and design, covering topics such as course objectives, a tentative outline, different levels of abstraction, programming languages, and virtual machines. The document also discusses the history of computer generations and the evolution of multilevel machines.

Full Transcript

Welcome to Computer Organization and Design Course Spring Semester 2024/2025 Instructor: Eng. Basim Al-shar’ Course Objectives What the course is about: – Understand how computers are organized and why they are organized that way – Understand hardware and software l...

Welcome to Computer Organization and Design Course Spring Semester 2024/2025 Instructor: Eng. Basim Al-shar’ Course Objectives What the course is about: – Understand how computers are organized and why they are organized that way – Understand hardware and software layouts from the system-level view of computers. – Introduce the Digital Logic, Microarchitecture, Instruction Set Architecture, and Operating Systems levels – Learn how components and devices are organized into an architectural configuration Our goal: show you how to understand modern computer architecture in its rapidly changing form. Tentative Outline Chapter 1 - Intro to Computer Organization Chapter 2 - Basic Computer System Organization Concepts Chapter 3 - Digital Logic Level – Gates → circuits, Boolean algebra, buses. Chapter 4 - Microarchitecture Level – “Implementation” of the ISA Chapter 5 - Instruction Set Architecture Level *Chapter 6 – Operating System Level *Chapter 8 – Parallel Computer Architecture Chapter One Introduction to Computer Organization What are Computer, Program, and Machine language? Computer is “a machine that can solve problems for people by carrying out instructions given to it.” – General purpose computers- e.g. PC, Workstations, Mainframes, etc. – Special purpose- e.g. the computers in cars, washing machines, Microwaves, cell phones, …etc The current spectrum of available computers. Program: is a sequence of instructions for performing a certain task. Machine language: Instructions that can be executed by the hardware of a computer. For example, – Add two numbers. – Check a number to see if it is zero. – Copy a piece of data from one memory location to another. Machine programs are difficult and tedious for people to use. How can we manage the complexity of computer systems? – A computer can be regarded as a hierarchy of levels. Each level performs some well-defined function. Each level is implemented on top of the next lower level. The lowest level is the physical level (hardware). – Each level serves as a layer of abstraction. An abstraction omits unneeded details, helps us cope with complexity. It hides the details of the lower layers from the upper layers. – We can understand a computer on different layers of abstraction. Programming Languages 1. High-level languages: – Easier for humans to work with, because they provide many useful things not found in most CPU instruction sets: Control flow instructions Functions and procedures Ability of checking to eliminate errors at compile time Portability between very different processors. 2. Low-level languages – Each CPU has its own instruction set, or assembly language, which closely reflects the processor design. – Low-level languages instruction sets are NOT easy to work with! Because: Limited control flow Limited support for functions and procedures Very little error checking provided Very low portability between CPUs Programs Executing Every machine has its own machine language, assume we have another language rather than the built in machine language, what do we need to do? – Language L0 (Machine language) executed by computer. – Language L1 used by people. The answer is that the L1 language should be converted into Machine language (L0), How? This can be done by one of the following methods: 1. Translation Replace every instruction in L1 program (the source) by an equivalent L0 instruction (the target). The output is completely L0 program. The computer executes the generated L0 program. 2. Interpretation Write an L0 program that takes L1 programs as inputs and executes them. The computer executes the L0 program (the interpreter). Virtual Machine Imagine a virtual machine. – Hypothetical computer M1 whose machine language is L1. – If such a machine can be constructed, no need for machine executing L0. People can write programs for virtual machine. – M1 may be built in hardware. – L1 programs may be translated to L0 programs. – L1 programs may be interpreted by L0 program. After the invention of the series of the programming languages, the computer can be viewed as a series of layers or levels. Therefore, a computer with n levels can be viewed as n different virtual machines. Each machine has its own language that can execute and understand. Languages, Levels, Virtual Machines A multilevel machine Contemporary Multilevel Machines A six-level computer Level 0 – Digital Logic Level This level is the machine true hardware which executes the machine language programs In this level, there is no concept of a program Interesting objects in this level are logic gates. – Built from transistors (analog components). Operates on digital inputs. – Signals representing 0 or 1. – Computes simple function on inputs (AND, OR,... ). Gates can be used to implement registers. – Groups of 1-bit memories (e.g., 16, 32, or 64). Level1 – Microarchitecture Level or Microprogramming Level This level contains a group of registers, the Arithmetic Logic Unit (ALU), Control Unit (CU) Registers are connected to the ALU to form a data path over which data flows ALU operates on the values in the registers and stores the result back into the memory or into one of the registers CU controls the data path so that data is moved where and when it should be. Data path is controlled by a program called microprogram Microprogram is an interpreter for the instructions in Level2. No two computers have identical microprogramming level. Level 2 – Instruction Set Architecture (ISA) Level or Conventional Level This level defines the instruction set of the computer. Some computers may not have a microprogramming level, therefore, the ISA level instruction will be directly carried out by L0. Due to that, ISA instruction can be executed by hardware or be interpreted by a microprogram (L1) This set of instructions are published by processor manufacturer in reference manual. Level 3 - Operating System Machine Level Some of this level’s instructions are also in level 2 A series of programs serves as a kind of protective shell or buffer to serve users and application programs from the complexities of the hardware. Operating system controls the sharing and interaction among various computer units as they execute application programs. Operating system also aids in process as a resource allocator such as sharing memory resource among users and application programs. Level 4 – Assembly Language Level This level language is textual, i.e., uses words, abbreviations and symbols to write programs which more meaningful and understandable than the numeric ones. Programs in Level 4 are first translated to Level 1, 2 or 3 languages and then interpreted by the appropriate machine to Level 0 (digital logic level) An assembler translates programs written in an assembly language into a sequence of machine instructions. Level 5 – Problem Oriented Language Level This level represents the high level languages which are much easier for human to understand than assembly language program like C++, Visual BASIC, PASCAL. Therefore, this level uses languages needed by the application programmers. Programs at these levels are usually translated to level 3 or 4. Such translators are known as Compilers. There is a break between the L3 and L4 The lowest 3 levels are used by the system programmers who build interpreters and translators to support higher levels Level 4 and above are used by application programmers with specific problem to solve L3 and L2 are always interpreted (i.e., uses interpretation) L4 and L5 and above usually uses translation L1, L2 and L3 machine languages are numeric L4, L5 and above languages are words, abbreviations and symbols. Programmers 1. System programmers: these are responsible for developing programs for the operating systems, interpreters, etc. These are more closer to the system. 2. High level programmers: these are responsible for developing application programs e.g. word processing, image manipulation, web browsers. These are more away from the system. Hardware and Software Computer hardware: – Tangible objects (ICs, boards, cables, power supplies, memories,... ) – Based on electronics, optics, magnetic,... Computer software: – Algorithms (instructions to perform a task) in a particular computer representation (programs). – Software can be stored on physical media (hard disk, floppy, CD-ROM,... ). – Essence of software is their information content, not their physical representation. Distinction has considerably blurred. – Functionality implemented in hardware can be performed in software and vice versa. – Hardware and software are logically equivalent. Evolution of Multilevel Machines Early digital computers (in 1940s) were simple which typically consisted of two levels: 1. ISA – where all the programming were done in the machine language of the computer. 2. Digital logic level – which executed the above programs – As the ISA level got more complicated, the digital logic level got more complicated, unreliable and expensive. In 1950s, this gave the way to the 3- level computers, where in addition to the ISA and the digital logic level, the microprogramming level was added: 1. This addition aimed to reduce the complexity of the hardware. 2. Microprogram interpreted the language in the ISA level – rather than directly by the electronics. Invention of Operating System Early computers had to be managed/operated by the programmers This includes loading the compiler, the program, the data, … etc. Then load the next level interpreter Then load and execute the machine language program That was a tedious process which led to the invention of the operating system to – Facilitates multi-user access to computers and simultaneous access from remote terminals: timesharing Migration of Functionality to Microcode Designers realized power of microcode. Add instructions by extending the microprogram. – Add/modify “hardware" by programming. Explosion of machine instruction sets. – Instruction sets became bigger and bigger. – Perform tasks faster than by existing instructions. – Example: integer multiplication/division, floating-point arithmetic, procedure call/return, looping instructions, string instructions,... Replace instruction sequences by new machine instructions. Milestones in Computer Architecture Generation 0: Mechanical Computers (1642- 1945) Generation 1: Vacuum Tubes (1945-1955) Generation 2: Transistors (1955-1965) Generation 3: Integrated Circuits (1965-1980) Generation 4: Very Large Scale Integration (1980-2020?) These are structured by fundamental changes in underlying technologies. Generation 0: Mechanical Computers Mechanical computers which were based on using gears, cranks and hand operating Simple calculators: add, subtract, multiply and divide First calculating machine was invented by Blaise Pascal in 1642 Father of computing – Charles Babbage During 1937-1942, John Vincent Atanasoff from Iowa State College and Clifford Berry built the Atanasoff Berry Computer (ABC) who were declared later in 1973 to be the inventors of the electronic digital computer. Generation 1: Vacuum Tubes The first general purpose electronic computer- Electronic Numerical Integrator and Computer (ENIAC) by Eckert and Mauchley at University of Pennsylvania 18,000 vacuum tubes, 1500 relays, 2 feet long registers, 30 ton and consumed 140KW of power. Data entered using punch cards Tedious to program In this period the von Neumann Machine appeared. von Neumann Machine is the basic of the all digital computers Programs and data are stored in the same memory and the computer itself can be an editor and calculator at the same time – Input: data and instructions from the outside world – Memory: stores data and instructions – ALU: arithmetic and logical operations – Control: interpret the instructions – Output: from memory to the outside world Generation 2: Transistors Invention of the Transistor technology at the Bell Labs in 1948 This made the vacuum tubes obsolete This led to smaller, faster, low power, cheaper computers System software (e.g. OS) for managing the computer Generation 3: Integrated Circuits (ICs) ICs allowed dozens of transistors on a single chip. Enable even smaller, faster and cheaper computers This allows for the appearance of computer families/series – like IBM Multiprogramming and multi-user systems Generation 4: Very Large Scale Integration (VLSI) This allows for millions of transistors on a chip – systems based on chips Complementary Metal Oxide Semiconductor (CMOS) technology for transistors for building circuits with high densities Small Scale Integration (SSI), Medium SI (MSI), Large SI (LSI), Very Large SI (VLSI), Very Very Large SI (VVLSI) Chip area of 100-300 mm2 , Board area of 200 cm2 (was 140m2), i.e., improvement of 104 Performance: – 64 bit multiply in about 1 ns (multiplication of two 10- digit numbers was in 2 ms), i.e., improvement of 106 Generation 5: ? What will come in 2020? 3-dimensional circuit designs. – Pack transistors in cubes instead of chips. Optical computing. – Replace electronics by optics. Molecular computing – Use chemical/biological processes for computing. Quantum computing – Use other physical properties for computing. – Special applications only, e.g., quantum cryptography. Computer Zoo (Advances in Computer Industry) Computer industry is one of the fastest growing technologies – where complicated chips and circuits with increasing number of transistors each year are rapidly growing which will provide larger memories and more powerful processors. Gordon Moore (co-founder of and Intel chairman) stated that – The number of transistors on a chip double every 18 month, – Memory capacity quadruples every 3 years Therefore, faster processors, bigger memories and larger programs. This is known as Moore’s Law (Observation) The Current Spectrum of Available Computers 1. Disposable Computers These include the Radio Frequency Identification (RFID) Chip: it is the most important technology in the area of throwaway computers, which can be used in: – Single chip inside greeting cards – Bar codes elimination – Cars tracking – Airlines baggage 2. Microcontrollers These are computers that are embedded inside devices which can be used to manage the devices and handle the user interface, like: – Appliances (washer machines, clocks, Microwaves,....) – Communications (mobiles, cordless phones) – Entertainments devices – Imaging devices If RFID are minimal, then the microcontrollers are small but complete computers (i.e., include processor, memory,…etc) All microcontrollers operate in real time Embedded systems have many restrictions in terms of size, weight, battery, … 3. Computer Games: These are normal computers with special graphics and sound capabilities like, the Sony Play-station 2 which includes a 295MHz CPU, 32MB RAM memory, DVD, … etc. 4. Personal Computers (PCs) 5. Servers: These are usually computers or Workstations which are used as network servers for LANs or Internet with high-speed, space and memory sizes networking capabilities (with single or multiple processors). 6. Collection of Workstations: These include large number of workstations to form Clusters of PCs or workstations connected by a network which allows all the machines to work on the same problem. 7. Mainframes and supercomputers: these are very large computers which consists of fast CPUs, very fast disks and networks, gigabytes memories.

Use Quizgecko on...
Browser
Browser