CS 2011 Introduction of Computer System Lecture 1 (Week 2 notes)
CS 2011 Introduction of Computer System Lecture 1 (Week 2 notes) CS2011
Popular in Introduction to Computer Systems
Popular in Computer Science and Engineering
This 2 page Class Notes was uploaded by Nemesi Notetaker on Thursday January 28, 2016. The Class Notes belongs to CS2011 at University of Cincinnati taught by Dr.Eric Hozier in Spring 2016. Since its upload, it has received 32 views. For similar materials see Introduction to Computer Systems in Computer Science and Engineering at University of Cincinnati.
Reviews for CS 2011 Introduction of Computer System Lecture 1 (Week 2 notes)
Report this Material
What is Karma?
Karma is the currency of StudySoup.
Date Created: 01/28/16
University of Cincinnati Department of Computer Science ‘18 Module1 Moore’s Law = famously predicted in 1960 that the transistor capacity of integrated circuits would double every 1824 months. Not really a law, but has largely held true. Defining and measuring performance As an individual computer user, you are interested in reducing response time—the time between the start and completion of a task—also referred to as execution time. Throughput the number of tasks completed per unit time (Performance= 1/Execution time) Computers are often shared, however, and a processor may work on several programs simultaneously. In such cases, the system may try to optimize throughput rather than attempt to minimize the elapsed time for one program. So in this case we measure Ex. Time [CPU= electronic circuitry within a computer that carries out the instructions of a computer program by performing the basic arithmetic, and input/output (I/O) operations specified by the instructions. Fetch (find), Decode and Execute] CPU execution time Also called CPU time. The actual time the CPU spends computing for a specific task. It is divided in user CPU time The CPU time spent in a program itself. And system CPU time The CPU time spent in the operating system performing tasks on behalf of the program Almost all computers are constructed using a clock that determines when events take place in the hardware. These discrete time intervals are called clock cycles the time for one clock period, usually of the processor clock, which runs at a constant rate. Clock period The length of each clock cycle. Clock frequency – number of cycles per second. 1. CPU execution time for a program= CPU clock cycles for a program/Clock rate [GHz] This formula makes it clear that the hardware designer can improve performance by: reducing the number of clock cycles required for a program The length of the clock cycle. The performance equations above did not include any reference to the number of instructions needed for the program. The execution time must depend on the number of instructions in a program. Clock cycles per instruction (CPI) = Average number of clock cycles per instruction for a program or program fragment. 2. CPU clock cycles Instructions for a program X Average clock cycles per instruction We can now write this basic performance equation in terms of instruction count (1+2) CPU time = Instruction count x CPI x Clock cycle time Or CPU time = (Instruction count x CPI)/Clock rate *IC In a nutshell Performance depends on: Algorithm: affects IC, possibly CPI (it determines the number of instructions executed and hence the number of processor instructions executed) Programming language: affects IC, CPI (statements in the language are translated to processor instructions, which determine instruction count) Compiler: affects IC, CPI (the compiler speed determines the translation of the source language instructions into computer instructions.) Instruction set architecture: affects IC, CPI, Tc (The instruction set architecture affects all three aspects of CPU performance, since it affects the instructions needed for a function, the cost in cycles of each instruction, and the overall clock rate of the processor.)