Computer Architecture and System Software Lecture 12: Review. Instructor: Rob Bergen Applied Computer Science University of Winnipeg

Size: px
Start display at page:

Download "Computer Architecture and System Software Lecture 12: Review. Instructor: Rob Bergen Applied Computer Science University of Winnipeg"

Transcription

1 Computer Architecture and System Software Lecture 12: Review Instructor: Rob Bergen Applied Computer Science University of Winnipeg

2 Announcements Assignment 5 due today Assignment 5 grades will be ed ASAP

3 Exam Information Date: April11th Time: 6:00 pm Room: 3D04 Duration: 3 hours

4 Exam Information We covered the following sections from the text Ch1: Sections Ch2: Sections (except 2.1.7) Ch6: Sections Ch8: Sections Ch9: Sections (except 9.4) + Fig 9.22 Exam will be more weighted towards assembly + Chapters 6 and onwards

5 Supplementary Notes 8086/88 Architecture Addressing modes Instruction set Assembly language programming Parallel Programming

6 Review The following slides will review and highlight key concepts from FP notation, assembly programming and chapters 6, 8, and 9 This review is not exhaustive please also review the other lectures, examples, labs and assignments

7 Floating Points

8 Floating Point Representation Encode values as (-1) s M 2 E Sign bit s determines whether number is negative or positive Bit representation Single bit encodes sign exp contains k bits encoding E frac contains n bits encoding M Total number of bits = 1+k+n s exp frac

9 Converting from decimal to FP Notation Step 1: Convert to binary Step 2: Normalize (convert to scientific notation) ( x 2 2 for example) Step 3: Compare with (-1) s x M x 2 E Step 4: Calculate exp and convert to unsigned Step 5: Put it all together Floating point to decimal: Reverse process

10 Floating Point Multiplication Multiply significands (M s) and add exponents (E) (add E not exp) Decimal (3 10^1) (5 10^2) = (1.5 10^4) Binary (1.001x2^2)(1.1x2^3) = (1.1011x2^5) Continue with conversion after this step

11 Floating Point Division Perform unsigned division on significands (M) Multiply both sides by same amount to get rid of decimal Subtract exponent (subtract E not exp) Decimal (5 10^2) / (2 10^1) = (2.5 10^1) Binary (1.10x2^2)/(1.0x2^1) = (1.10/1.00) x2^1 = (110/100) x2^1

12 Floating points - Key Areas Do not confuse E with exp! Treat all binary numbers (exp,frac) as unsigned. The sign bit exists for a reason. Show your work! Study examples in class, worksheets Only multiplication and division will be tested

13 Assembly

14 8086 / 8088 Architecture Two main units Bus interface unit (BIU) Execution unit (EU) 8086 Data bus size: 16 bit Instruction queue: 6 bytes 20 bit address bus

15 General Purpose Registers Used for arithmetic, logical, and other operations Can be configured as: Four 16-bit registers Eight 8-bit registers

16 Index and Pointer Registers BP, SI, DI, SP Can only be used as 16 bit registers SI, DI used for addressing, and string op. BP, SP are used for maintaining the stack

17 Segment Registers 16 bit registers labelled DS, CS, SS, ES Used to indicate the start of different segments in memory

18 Flag Register 16-bit register containing 9 1-bit flags Gives status of the last instruction and the processor

19 Segments Memory can be thought of as an array of bytes A program needs storage space within memory We partition memory into segments DS SS CS ES IP DATA SEGMENT STACK SEGMENT CODE SEGMENT

20 Summary of Addressing Modes Operand needed for an instruction may be located: Immediately in the operand field, e.g. MOV AX, 1234h In a register (register addressing), e.g. MOV DS, AX In memory at a an offset specified by one of the following (disp is a constant): The segment address is in DS (by default, except when BP is used) In memory locations given implicitly by string instructions At input/output ports specified by a register or a constant

21 BYTE PTR Example: Assume register si holds the address of the first character in a string mov byte ptr [si], 7 ;replaces first character of ;string in si with 7 BYTE PTR specifies that we want to move a byte of data into memory

22 BYTE PTR Without size specification, it is ambiguous what we want the assembler to do 7 in byte representation = in 16-bit (word) representation = Usually size specification is not necessary since registers are of fixed size

23 Buffered Keyboard Input Structure of buffered keyboard input in memory: max count Buffer 1 byte 1 byte N bytes where max = max number to characters read count = number of characters returned (not including enter) Buffer = contents of string

24 Buffered Keyboard input With this structure in mind, what do the following registers point to if mybstr is a buffered string? a) Lea dx, mybstr dx points to maximum # of chars to read b) Lea dx, mybstr inc dx dx points to total number of characters (not including enter) c) Lea dx, mybstr add dx, 2 dx points to first char of input string

25 Jumps, Conditionals, Loops Two types of jumps: Conditional, unconditional Conditional jumps + update scheme = loop Jumps always point to a label Conditions are checked through flags register If condition is met, jump instruction is ignored and code proceeds as normal

26 Procedures call myproc mov ax, bx ;call (procedure name) ;instruction returned to after ret myproc proc mov ah, 02h mov dl, S int 21 h ret myproc endp ; procedure defined here ;(procedure name) proc ;code for displaying S ;return to instruction after call ;(procedure name) endp

27 Procedures (Background) Stack Pointer (SP) points to the top of the stack Stack Segment (SS) points to the start of the stack segment in memory Call Return address (IP) is pushed to stack Jump to effective address given by operand Return address is the address of the instruction following the call Return Pop return address from stack Jump to that address

28 Parameter Passing There is little/no support for passing parameters to procedures When it comes to implementation Its up to the programmer to follow conventions Procedures are written to assume input data stored in default registers/stack Interrupts also follow these conventions (int 21h)

29 Assembly Language - Key Areas Practice, practice, practice Study labs, assignments 3, 4 & 5 (Q1) Know the names of all the registers, what they do, how big they are. Without this foundation, you can t get far. If you get stuck, try writing the same program in C (or any language of your choice). Converting to assembly may be easier once you figure out the general structure of your program. Don t forget to comment

30 Memory Hierarchy

31 SRAM vs DRAM Static RAM (SRAM) Each bit is stored in bistable memory Memory will store values unless disturbed 1 bit = 6 transistors Fast and expensive Dynamic RAM (DRAM) Stores each bit as a charge on a capacitor Has to be refreshed on regular basis Uses 1 transistor per bit Can be made very dense (lots of bits per inch) 100X cheaper 10X slower

32 Conventional DRAMs

33 Memory Module

34 Memory Module Example Module stores a total of 64 MB Uses eight 64-Mbit 8M x 8 DRAM chips Numbered 0-7 Each supercell consists of one byte of main memory Each 64-bit quadword at address A in main memory is represented by 8 supercells i.e. the supercells whose corresponding address is (i,j)

35 Memory Module To retrieve a 64-bit quadword at address A Memory controller converts A to a supercell address (i,j) Sends address to memory module Memory module broadcasts i and j to each DRAM DRAM outputs 8-bit contents of its (i,j) supercell Module collects these outputs and forms them into a 64-bit quadword Quadword returned to memory controller

36 Memory Module Main memory is an aggregate of multiple memory modules Each memory module stores part of the address space A module consists of DRAM chips DRAM chips consist of supercells containing a number of bits 4 GB of memory example: 1024 Mb (128 MB) DRAM chip 8 chips on a module (128MB x 8 chips = 1024 MB = 1GB) 1GB Requires 30 address lines Only ¼ of address spaces Need 4 banks of modules (32 DRAM chips) to get 4GB Memory controller determines which module to use based on last 2 lines

37 Components of a Memory System Memory Controller Manages memory chips Executes store/load requests Memory Chips: store actual data Two types of operations: Read transaction Write transaction

38 Read Transaction: mov ax, A Bus interface initiates a read transaction on the bus CPU places address A on the system bus via bus interface I/O bridge interprets request as memory read Forwards it on to memory bus Register file ax ALU Bus interface I/O bridge A Main memory x 0 A

39 Read Transaction: mov ax, A Main memory controller Senses the address signal on memory bus and reads it Fetches the data word from DRAM and writes it to memory bus I/O bridge translates the memory bus signal into a system bus signal and passes it along to the system bus Register file ax ALU Bus interface I/O bridge Main memory x 0 x A

40 Read Transaction: mov ax, A CPU: Senses data on system bus Reads it from the bus Copies it to register ax Register file ax x ALU I/O bridge Main memory 0 Bus interface x A

41 Disk Geometry Track: Partitioned into a collection of sectors Sector Contains an equal number of bits (typically 512 bytes) Separated by gaps where no data is recorded Gaps store formatting bits that identify sectors Cylinder A collection of tracks Located in the same location on each surface # of tracks per cylinder = # of surfaces Numbering Surfaces, tracks (cylinders), and sectors are numbered Location is defined as (surface, cylinder, sector)

42 Disk Capacity Maximum # of bits that can be recorded on the HD depends on Recording density (bits/in): # of bits in 1-inch of surface segment of a track Track density (tracks/in) : # of tracks in a 1-inch segment of the radius extending from the center of the patter Areal density (bits/in 2 ): The product of the recording density and the track density

43 Access Time How long to read or write a sector? Seek time: time to move head to correct cylinder Depends on previous position of head Speed of actuator arm Average seek time: measured by averaging time of several thousand seeks Max seek time can be as high as 20ms Rotational latency: time to wait before sector passes head Depends on rotation speed of disk Location of sector at time of operation Worst case: head just missed sector and must wait for complete rotation Average case: worst case divided by 2 Max. rotational latency in seconds (1/RPM) x 60 seconds

44 Access Time Transfer time (throughput): amount of time to r/w a sector Depends on rotation speed of disk & # of sectors per track Approx = (1/RPM) x (1/avg. # sectors per track) x 60 seconds Estimate the avg. time to access the contents of a disk sector as the sum of the avg. seek time, avg. rotational latency, and avg. transfer time Example: Disk 7200 RPM, 9ms seek, 400 sectors/track Access time = ms

45 Access Time Observations Seek time and rot. lat. dominate access time 2x seek time is good estimate of access time Access time to read 512-byte sized block: SRAM = 256 ns DRAM = 4000 ns Disk = 10 ms Disk access time is roughly 40000X greater than SRAM, and 2500X greater than DRAM

46 Solid State Disks Can provide an alternative to rotation disk

47 SSD Advantages/Disadvantages Advantages No moving parts Use less power More rugged Disadvantages SSDs have potential of wearing out More expensive

48 Direct Memory Access (DMA) Disk drives can sometimes directly access memory, bypassing CPU (See diagrams from Lecture 10) Short version: CPU sends r/w request with memory address to disk Disk controller communicates with memory controller until job is done More efficient for large amounts of data

49 Cache Hits and Misses Three types of cache misses: Compulsory misses: are those misses caused by an empty cache Empty cache is called a cold cache Conflict misses: Are those misses that could have been avoided, had the cache not evicted an entry earlier Capacity misses: Misses that occur solely due to finite size of the caches When a block is loaded into cache, it must have a place Ideal: a flexible policy to place block anywhere in cache

50 Summary of Memory Concepts Exploiting Temporal Locality: Objects will be accessed many times First time object is loaded into cache In the future object is accessed from the cache faster Exploiting Spatial Locality: Blocks contain multiple data objects First object causes block to be loaded into cache Next object accessed after first object will already be in the cache

51 Generic Cache Structure

52 Summary Of Cache Parameters

53 Example (pg. 601) Let (S,E,B,m) = (4, 1, 2, 4)

54 Types of Cache Caches are grouped into different classes based on E (# of cache lines per set) Direct-mapped caches: easiest to understand and implement Set associative caches: hard to implement Fully associative caches: hard to implement

55 Set Associative Caches Key characteristic: 1 < E < C/B Called E-way set associative caches Each set contains multiple lines

56 Fully Associative Caches Key Characteristic: E = C/B (S = 1) Cache is a single set with C / B lines Address is divided into tag and offset No s bits Analogous to a huge hash table Valid Tag Cache block Set 0: Valid Tag Cache block E = C/B lines in the one and only set Valid Tag Cache block

57 Which cache is best? Depends: Easy replacement policy increases speed at cost of hit rate Small caches have faster access time but they may thrash Large caches increase hit rate at expense of access time (more entries to search) Level of storage hierarchy determines which feature is most important

58 Memory Mountain

59 Memory Hierarchy Key Concepts Physical structure of DRAM, Disk What is the memory/disk controller s role? What is the relationship of bus size to address space size? What factors affect cache performance (Either positively or negatively)? Be able to explain the above. Example: A complicated replacement policy requires more sophisticated logic, therefore the caching process is slower, but the hit rate is higher. This type of replacement policy is suitable for a storage level low on the hierarchy (DRAM or disk), where cache misses are extremely expensive.

60 Memory Hierarchy Key Concepts Memory mountain Be able to reproduce sketch of 2D cross-sections (Read throughput vs stride) Read throughput vs working set size) Be able to explain prominent features Be able to identify how spatial and temporal locality play a role in computer performance

61 Processes, OS, Virtual Memory

62 Exceptions CPU is executing instruction I curr A significant change in the processor s state occurs (called an event) Examples: Divide by 0 Virtual memory page fault Arithmetic overflow I/O request completes Hardware timer

63 Exception Table When exception occurs (CPU detects an event) CPU determines ID of exception Uses ID to index into exception table Locates reference to corresponding handler Uses reference to make a procedure call to handler Exception table base register Exception number (x 4) + Address of entry for exception # k n-1 Exception table...

64 Class of Exceptions There are four classes of exceptions: Interrupts: caused by normal hardware events Traps: caused by program service requests Faults: caused by repairable program errors Aborts: caused by unrepairable program errors and HW errors

65 Processes A process consists of Program code and data Logical control flow of the program Private address space Information about a process is stored in a Process Control Block (PCB) Allocated by the OS when a process is created Is only accessible to the OS Used to store parts of the process context

66 Logical Control Flow Each process executes a portion of its flow and then is preempted A & B and A & C run concurrently, but B and C do not Process A Process B Process C Time

67 Exceptions Key Concepts Know the types of exceptions Be able to give one or two examples of each What is an exception handler? Logical control flow and processes How is control transferred from one process to another? Why is this important?

68 Virtual Memory

69 Private Address Space Each process has illusion of exclusive use of system s address space In actuality, a process provides each program with its own private address space Private address spaces have similar layouts: Code, data, heap, stack, kernel space Why do we need this abstraction? To multitask

70 Virtual Memory and Caching At any point in time, virtual memory consists of the following types of pages: Unallocated: Contains no data and does not occupy any disk space Cached: Page contains data Page is assigned to a frame (physical page in memory) Uncached: Page contains data Page is not assigned to a frame (physical page in memory) Page is stored on disk

71 Paging Tables Task: The MMU has to translate addresses for each running process Basic approach: for each virtual address determine Which virtual page corresponds to the address Whether virtual page is allocated and cached Determine location of frame containing the page

72 Page Allocation Pages are allocated under three conditions When a process is created Enough pages are allocated to hold code, data, stack, and small heap When a process needs more heap memory Process uses system call to request pages from OS OS responds by Allocating pages for the heap Returns to the process # of pages that were added When process needs more stack OS automatically detects when a process needs more stack Allocates more pages to the stack

73 Address Translation Page Hit Page Miss

74 TLB Problem: this process requires accessing more memory (to read PTE) Solution: use a special cache called Translation Lookaside Buffer Most programs have good locality i.e. accesses are spatially and temporally localized Many accesses will occur within the same set of virtual pages and hence within the same set of physical frames

75 TLB Idea: Cache PTEs of recently accessed virtual pages in a cache Located in the MMU Called TLB Instead of looking up PTE in page table first check TLB If PTE is in TLB, use it Else look in page table Load TLB with new PTE (may need to evict another one) TLBs are efficient (95% hit rates)

76 Virtual Addressing Example

77 Example Page table for 8 VP 1, 2, 4, and 7 are cached 0 and 5 not allocated 3 and 6 are not cached Note: any physical page can contain any virtual page

78 Memory Protection Page tables with permission bits Process i: VP 0: VP 1: VP 2: SUP No No Yes READ WRITE Address Yes No PP 6 Yes Yes PP 4 Yes Yes PP 2 Physical memory PP 0 PP 2 PP 4 Process j: SUP VP 0: No VP 1: Yes VP 2: No READ WRITE Address Yes No PP 9 Yes Yes PP 6 Yes Yes PP 11 PP 6 PP 9 PP 11

79 Address Translation

80 TLBs Translation Lookaside Buffer is used as a cache for page table entries Indexing into a TLB is done through tag (TLBT) and index (TLBI) bits Very similar to caching in chapter 6

81 Virtual Memory Key Concepts Why is virtual memory useful? Keeps processes separate Allows us to have an ordered, contiguous block of memory space for each process Memory protection Know how the MMU translates from virtual to physical addresses Be able to put it all together (Ch6 + Ch9) From virtual addressing to supercell addressing and all the steps along the way

82 Parallel Computing

83 Recall: Threads Processes with multiple executions A process can have more than one execution Each execution is called a thread Threads execute concurrently as well Differences: Process do not share memory Threads view: it does not have the whole machine to itself

84 Multi-threading

85 CPU: Multi-threading Single-core CPU manages multiple threads at once using flow of control Threads on different cores of the CPU can truly execute in parallel However, an X-core processor does not multiply processing power by X

86 Why? There must be some level of communication between cores Cores have their own private memory, as well as shared memory storage between all cores Therefore: threads on separate cores are not truly independent

87 GPUs Graphics Processing Units Used to process pixel and texture data Relies heavily on parallel execution Becoming more and more popular in scientific and general purpose computing

88 Serial Vs. Parallel A computer program can be separated into two parts Serial part Parallel part Size of each part determines amount of speed up that can be gained

89 Amdahl s Law Maximum achievable speed up: B: Fraction of algorithm that is serial n: Number of threads S n = 1 B + 1 (1 B) n

90 Amdahl s Law Example: 16 threads, ½ serial S = 1.83 (83% speed up) 32 threads, ½ serial S = threads, ½ serial S = 2

91 GPU Grid

92 GPU Grid In actuality, blocks and threads are abstractions. In reality, multi/stream processors manage one or more blocks/threads, respectively Blocks can never be divided into more than one multiprocessor

93 Why Massively Parallel Processing? GPU: Designed for massive throughput of one task Little flexibility required (less branching) Architecture is less complex CPU: Handles wide variety of tasks, so lots of flexibility required Architecture is more complex In other words, GPUs will not replace CPUs.

94 Parallel Computing - Key Concepts Know basic GPU architecture Grids, blocks, threads, and if/how they share memory Know general process of GPU computing How do the CPU and GPU interact with one another? Be able to compare CPUs and GPUs with specific examples Matrix addition You will only be asked conceptual questions You can ignore slides on matrix multiplication and programming examples

95 Lab Lab is tomorrow (make up day for Good Friday) Review caching process in Chapter 6

Computer Architecture and System Software Lecture 09: Memory Hierarchy. Instructor: Rob Bergen Applied Computer Science University of Winnipeg

Computer Architecture and System Software Lecture 09: Memory Hierarchy. Instructor: Rob Bergen Applied Computer Science University of Winnipeg Computer Architecture and System Software Lecture 09: Memory Hierarchy Instructor: Rob Bergen Applied Computer Science University of Winnipeg Announcements Midterm returned + solutions in class today SSD

More information

Computer Architecture and System Software Lecture 08: Assembly Language Programming + Memory Hierarchy

Computer Architecture and System Software Lecture 08: Assembly Language Programming + Memory Hierarchy Computer Architecture and System Software Lecture 08: Assembly Language Programming + Memory Hierarchy Instructor: Rob Bergen Applied Computer Science University of Winnipeg Announcements Chapter 6 The

More information

Random-Access Memory (RAM) Systemprogrammering 2007 Föreläsning 4 Virtual Memory. Locality. The CPU-Memory Gap. Topics

Random-Access Memory (RAM) Systemprogrammering 2007 Föreläsning 4 Virtual Memory. Locality. The CPU-Memory Gap. Topics Systemprogrammering 27 Föreläsning 4 Topics The memory hierarchy Motivations for VM Address translation Accelerating translation with TLBs Random-Access (RAM) Key features RAM is packaged as a chip. Basic

More information

Processes and Virtual Memory Concepts

Processes and Virtual Memory Concepts Processes and Virtual Memory Concepts Brad Karp UCL Computer Science CS 37 8 th February 28 (lecture notes derived from material from Phil Gibbons, Dave O Hallaron, and Randy Bryant) Today Processes Virtual

More information

Random-Access Memory (RAM) Systemprogrammering 2009 Föreläsning 4 Virtual Memory. Locality. The CPU-Memory Gap. Topics! The memory hierarchy

Random-Access Memory (RAM) Systemprogrammering 2009 Föreläsning 4 Virtual Memory. Locality. The CPU-Memory Gap. Topics! The memory hierarchy Systemprogrammering 29 Föreläsning 4 Topics! The memory hierarchy! Motivations for VM! Address translation! Accelerating translation with TLBs Random-Access (RAM) Key features! RAM is packaged as a chip.!

More information

Carnegie Mellon. Bryant and O Hallaron, Computer Systems: A Programmer s Perspective, Third Edition

Carnegie Mellon. Bryant and O Hallaron, Computer Systems: A Programmer s Perspective, Third Edition Carnegie Mellon Virtual Memory: Concepts 5-23: Introduction to Computer Systems 7 th Lecture, October 24, 27 Instructor: Randy Bryant 2 Hmmm, How Does This Work?! Process Process 2 Process n Solution:

More information

Microcomputer Architecture..Second Year (Sem.2).Lecture(2) مدرس المادة : م. سندس العزاوي... قسم / الحاسبات

Microcomputer Architecture..Second Year (Sem.2).Lecture(2) مدرس المادة : م. سندس العزاوي... قسم / الحاسبات 1) Input/output In computing, input/output or I/O, is the communication between an information processing system (such as a computer) and the outside world, possibly a human or another information processing

More information

Computer Systems. Memory Hierarchy. Han, Hwansoo

Computer Systems. Memory Hierarchy. Han, Hwansoo Computer Systems Memory Hierarchy Han, Hwansoo Random-Access Memory (RAM) Key features RAM is traditionally packaged as a chip. Basic storage unit is normally a cell (one bit per cell). Multiple RAM chips

More information

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 26, FALL 2012

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 26, FALL 2012 CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 26, FALL 2012 TOPICS TODAY Homework 5 RAM in Circuits Memory Hierarchy Storage Technologies (RAM & Disk) Caching HOMEWORK 5 RAM IN

More information

CS429: Computer Organization and Architecture

CS429: Computer Organization and Architecture CS429: Computer Organization and Architecture Dr. Bill Young Department of Computer Sciences University of Texas at Austin Last updated: November 28, 2017 at 14:31 CS429 Slideset 18: 1 Random-Access Memory

More information

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 26, SPRING 2013

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 26, SPRING 2013 CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 26, SPRING 2013 TOPICS TODAY End of the Semester Stuff Homework 5 Memory Hierarchy Storage Technologies (RAM & Disk) Caching END OF

More information

CS429: Computer Organization and Architecture

CS429: Computer Organization and Architecture CS429: Computer Organization and Architecture Dr. Bill Young Department of Computer Sciences University of Texas at Austin Last updated: April 9, 2018 at 12:16 CS429 Slideset 17: 1 Random-Access Memory

More information

Computer Architecture and System Software Lecture 06: Assembly Language Programming

Computer Architecture and System Software Lecture 06: Assembly Language Programming Computer Architecture and System Software Lecture 06: Assembly Language Programming Instructor: Rob Bergen Applied Computer Science University of Winnipeg Announcements Assignment 3 due thursday Midterm

More information

14 May 2012 Virtual Memory. Definition: A process is an instance of a running program

14 May 2012 Virtual Memory. Definition: A process is an instance of a running program Virtual Memory (VM) Overview and motivation VM as tool for caching VM as tool for memory management VM as tool for memory protection Address translation 4 May 22 Virtual Memory Processes Definition: A

More information

Computer Systems. Virtual Memory. Han, Hwansoo

Computer Systems. Virtual Memory. Han, Hwansoo Computer Systems Virtual Memory Han, Hwansoo A System Using Physical Addressing CPU Physical address (PA) 4 Main memory : : 2: 3: 4: 5: 6: 7: 8:... M-: Data word Used in simple systems like embedded microcontrollers

More information

Carnegie Mellon. 16 th Lecture, Mar. 20, Instructors: Todd C. Mowry & Anthony Rowe

Carnegie Mellon. 16 th Lecture, Mar. 20, Instructors: Todd C. Mowry & Anthony Rowe Virtual Memory: Concepts 5 23 / 8 23: Introduction to Computer Systems 6 th Lecture, Mar. 2, 22 Instructors: Todd C. Mowry & Anthony Rowe Today Address spaces VM as a tool lfor caching VM as a tool for

More information

Virtual Memory: Concepts

Virtual Memory: Concepts Virtual Memory: Concepts 5-23: Introduction to Computer Systems 7 th Lecture, March 2, 27 Instructors: Franz Franchetti & Seth Copen Goldstein Hmmm, How Does This Work?! Process Process 2 Process n Solution:

More information

Computer Architecture and System Software Lecture 07: Assembly Language Programming

Computer Architecture and System Software Lecture 07: Assembly Language Programming Computer Architecture and System Software Lecture 07: Assembly Language Programming Instructor: Rob Bergen Applied Computer Science University of Winnipeg Announcements New assembly examples uploaded to

More information

CSE 153 Design of Operating Systems

CSE 153 Design of Operating Systems CSE 53 Design of Operating Systems Winter 28 Lecture 6: Paging/Virtual Memory () Some slides modified from originals by Dave O hallaron Today Address spaces VM as a tool for caching VM as a tool for memory

More information

Storage Technologies and the Memory Hierarchy

Storage Technologies and the Memory Hierarchy Storage Technologies and the Memory Hierarchy 198:231 Introduction to Computer Organization Lecture 12 Instructor: Nicole Hynes nicole.hynes@rutgers.edu Credits: Slides courtesy of R. Bryant and D. O Hallaron,

More information

Virtual Memory. Motivations for VM Address translation Accelerating translation with TLBs

Virtual Memory. Motivations for VM Address translation Accelerating translation with TLBs Virtual Memory Today Motivations for VM Address translation Accelerating translation with TLBs Fabián Chris E. Bustamante, Riesbeck, Fall Spring 2007 2007 A system with physical memory only Addresses generated

More information

Computer Organization: A Programmer's Perspective

Computer Organization: A Programmer's Perspective A Programmer's Perspective Computer Architecture and The Memory Hierarchy Gal A. Kaminka galk@cs.biu.ac.il Typical Computer Architecture CPU chip PC (Program Counter) register file ALU Main Components

More information

Motivations for Virtual Memory Virtual Memory Oct. 29, Why VM Works? Motivation #1: DRAM a Cache for Disk

Motivations for Virtual Memory Virtual Memory Oct. 29, Why VM Works? Motivation #1: DRAM a Cache for Disk class8.ppt 5-23 The course that gives CMU its Zip! Virtual Oct. 29, 22 Topics Motivations for VM Address translation Accelerating translation with TLBs Motivations for Virtual Use Physical DRAM as a Cache

More information

Virtual Memory. CS61, Lecture 15. Prof. Stephen Chong October 20, 2011

Virtual Memory. CS61, Lecture 15. Prof. Stephen Chong October 20, 2011 Virtual Memory CS6, Lecture 5 Prof. Stephen Chong October 2, 2 Announcements Midterm review session: Monday Oct 24 5:3pm to 7pm, 6 Oxford St. room 33 Large and small group interaction 2 Wall of Flame Rob

More information

Module 1: Basics and Background Lecture 4: Memory and Disk Accesses. The Lecture Contains: Memory organisation. Memory hierarchy. Disks.

Module 1: Basics and Background Lecture 4: Memory and Disk Accesses. The Lecture Contains: Memory organisation. Memory hierarchy. Disks. The Lecture Contains: Memory organisation Example of memory hierarchy Memory hierarchy Disks Disk access Disk capacity Disk access time Typical disk parameters Access times file:///c /Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture4/4_1.htm[6/14/2012

More information

Virtual Memory Oct. 29, 2002

Virtual Memory Oct. 29, 2002 5-23 The course that gives CMU its Zip! Virtual Memory Oct. 29, 22 Topics Motivations for VM Address translation Accelerating translation with TLBs class9.ppt Motivations for Virtual Memory Use Physical

More information

Program controlled semiconductor device (IC) which fetches (from memory), decodes and executes instructions.

Program controlled semiconductor device (IC) which fetches (from memory), decodes and executes instructions. 8086 Microprocessor Microprocessor Program controlled semiconductor device (IC) which fetches (from memory), decodes and executes instructions. It is used as CPU (Central Processing Unit) in computers.

More information

Processes and Tasks What comprises the state of a running program (a process or task)?

Processes and Tasks What comprises the state of a running program (a process or task)? Processes and Tasks What comprises the state of a running program (a process or task)? Microprocessor Address bus Control DRAM OS code and data special caches code/data cache EAXEBP EIP DS EBXESP EFlags

More information

CS 61C: Great Ideas in Computer Architecture. Direct Mapped Caches

CS 61C: Great Ideas in Computer Architecture. Direct Mapped Caches CS 61C: Great Ideas in Computer Architecture Direct Mapped Caches Instructor: Justin Hsia 7/05/2012 Summer 2012 Lecture #11 1 Review of Last Lecture Floating point (single and double precision) approximates

More information

CS24: INTRODUCTION TO COMPUTING SYSTEMS. Spring 2015 Lecture 23

CS24: INTRODUCTION TO COMPUTING SYSTEMS. Spring 2015 Lecture 23 CS24: INTRODUCTION TO COMPUTING SYSTEMS Spring 205 Lecture 23 LAST TIME: VIRTUAL MEMORY! Began to focus on how to virtualize memory! Instead of directly addressing physical memory, introduce a level of

More information

Computer Systems C S Cynthia Lee Today s materials adapted from Kevin Webb at Swarthmore College

Computer Systems C S Cynthia Lee Today s materials adapted from Kevin Webb at Swarthmore College Computer Systems C S 0 7 Cynthia Lee Today s materials adapted from Kevin Webb at Swarthmore College 2 Today s Topics TODAY S LECTURE: Caching ANNOUNCEMENTS: Assign6 & Assign7 due Friday! 6 & 7 NO late

More information

virtual memory Page 1 CSE 361S Disk Disk

virtual memory Page 1 CSE 361S Disk Disk CSE 36S Motivations for Use DRAM a for the Address space of a process can exceed physical memory size Sum of address spaces of multiple processes can exceed physical memory Simplify Management 2 Multiple

More information

CS24: INTRODUCTION TO COMPUTING SYSTEMS. Spring 2018 Lecture 23

CS24: INTRODUCTION TO COMPUTING SYSTEMS. Spring 2018 Lecture 23 CS24: INTRODUCTION TO COMPUTING SYSTEMS Spring 208 Lecture 23 LAST TIME: VIRTUAL MEMORY Began to focus on how to virtualize memory Instead of directly addressing physical memory, introduce a level of indirection

More information

198:231 Intro to Computer Organization. 198:231 Introduction to Computer Organization Lecture 14

198:231 Intro to Computer Organization. 198:231 Introduction to Computer Organization Lecture 14 98:23 Intro to Computer Organization Lecture 4 Virtual Memory 98:23 Introduction to Computer Organization Lecture 4 Instructor: Nicole Hynes nicole.hynes@rutgers.edu Credits: Several slides courtesy of

More information

CS 201 The Memory Hierarchy. Gerson Robboy Portland State University

CS 201 The Memory Hierarchy. Gerson Robboy Portland State University CS 201 The Memory Hierarchy Gerson Robboy Portland State University memory hierarchy overview (traditional) CPU registers main memory (RAM) secondary memory (DISK) why? what is different between these

More information

CISC 360. The Memory Hierarchy Nov 13, 2008

CISC 360. The Memory Hierarchy Nov 13, 2008 CISC 360 The Memory Hierarchy Nov 13, 2008 Topics Storage technologies and trends Locality of reference Caching in the memory hierarchy class12.ppt Random-Access Memory (RAM) Key features RAM is packaged

More information

CS 261 Fall Mike Lam, Professor. Virtual Memory

CS 261 Fall Mike Lam, Professor. Virtual Memory CS 261 Fall 2016 Mike Lam, Professor Virtual Memory Topics Operating systems Address spaces Virtual memory Address translation Memory allocation Lingering questions What happens when you call malloc()?

More information

Chapter 5. Large and Fast: Exploiting Memory Hierarchy

Chapter 5. Large and Fast: Exploiting Memory Hierarchy Chapter 5 Large and Fast: Exploiting Memory Hierarchy Principle of Locality Programs access a small proportion of their address space at any time Temporal locality Items accessed recently are likely to

More information

Giving credit where credit is due

Giving credit where credit is due CSCE 230J Computer Organization The Memory Hierarchy Dr. Steve Goddard goddard@cse.unl.edu http://cse.unl.edu/~goddard/courses/csce230j Giving credit where credit is due Most of slides for this lecture

More information

NEXT SET OF SLIDES FROM DENNIS FREY S FALL 2011 CMSC313.

NEXT SET OF SLIDES FROM DENNIS FREY S FALL 2011 CMSC313. NEXT SET OF SLIDES FROM DENNIS FREY S FALL 211 CMSC313 http://www.csee.umbc.edu/courses/undergraduate/313/fall11/" The Memory Hierarchy " Topics" Storage technologies and trends" Locality of reference"

More information

CS252 S05. Main memory management. Memory hardware. The scale of things. Memory hardware (cont.) Bottleneck

CS252 S05. Main memory management. Memory hardware. The scale of things. Memory hardware (cont.) Bottleneck Main memory management CMSC 411 Computer Systems Architecture Lecture 16 Memory Hierarchy 3 (Main Memory & Memory) Questions: How big should main memory be? How to handle reads and writes? How to find

More information

CISC 360. Virtual Memory Dec. 4, 2008

CISC 360. Virtual Memory Dec. 4, 2008 CISC 36 Virtual Dec. 4, 28 Topics Motivations for VM Address translation Accelerating translation with TLBs Motivations for Virtual Use Physical DRAM as a Cache for the Disk Address space of a process

More information

Random Access Memory (RAM)

Random Access Memory (RAM) Random Access Memory (RAM) Key features RAM is traditionally packaged as a chip. Basic storage unit is normally a cell (one bit per cell). Multiple RAM chips form a memory. Static RAM (SRAM) Each cell

More information

Handout 4 Memory Hierarchy

Handout 4 Memory Hierarchy Handout 4 Memory Hierarchy Outline Memory hierarchy Locality Cache design Virtual address spaces Page table layout TLB design options (MMU Sub-system) Conclusion 2012/11/7 2 Since 1980, CPU has outpaced

More information

Locality. CS429: Computer Organization and Architecture. Locality Example 2. Locality Example

Locality. CS429: Computer Organization and Architecture. Locality Example 2. Locality Example Locality CS429: Computer Organization and Architecture Dr Bill Young Department of Computer Sciences University of Texas at Austin Principle of Locality: Programs tend to reuse data and instructions near

More information

Denison University. Cache Memories. CS-281: Introduction to Computer Systems. Instructor: Thomas C. Bressoud

Denison University. Cache Memories. CS-281: Introduction to Computer Systems. Instructor: Thomas C. Bressoud Cache Memories CS-281: Introduction to Computer Systems Instructor: Thomas C. Bressoud 1 Random-Access Memory (RAM) Key features RAM is traditionally packaged as a chip. Basic storage unit is normally

More information

The Memory Hierarchy /18-213/15-513: Introduction to Computer Systems 11 th Lecture, October 3, Today s Instructor: Phil Gibbons

The Memory Hierarchy /18-213/15-513: Introduction to Computer Systems 11 th Lecture, October 3, Today s Instructor: Phil Gibbons The Memory Hierarchy 15-213/18-213/15-513: Introduction to Computer Systems 11 th Lecture, October 3, 2017 Today s Instructor: Phil Gibbons 1 Today Storage technologies and trends Locality of reference

More information

ECE468 Computer Organization and Architecture. Virtual Memory

ECE468 Computer Organization and Architecture. Virtual Memory ECE468 Computer Organization and Architecture Virtual Memory ECE468 vm.1 Review: The Principle of Locality Probability of reference 0 Address Space 2 The Principle of Locality: Program access a relatively

More information

ECE4680 Computer Organization and Architecture. Virtual Memory

ECE4680 Computer Organization and Architecture. Virtual Memory ECE468 Computer Organization and Architecture Virtual Memory If I can see it and I can touch it, it s real. If I can t see it but I can touch it, it s invisible. If I can see it but I can t touch it, it

More information

Lecture 15: Caches and Optimization Computer Architecture and Systems Programming ( )

Lecture 15: Caches and Optimization Computer Architecture and Systems Programming ( ) Systems Group Department of Computer Science ETH Zürich Lecture 15: Caches and Optimization Computer Architecture and Systems Programming (252-0061-00) Timothy Roscoe Herbstsemester 2012 Last time Program

More information

CS 33. Memory Hierarchy I. CS33 Intro to Computer Systems XVI 1 Copyright 2016 Thomas W. Doeppner. All rights reserved.

CS 33. Memory Hierarchy I. CS33 Intro to Computer Systems XVI 1 Copyright 2016 Thomas W. Doeppner. All rights reserved. CS 33 Memory Hierarchy I CS33 Intro to Computer Systems XVI 1 Copyright 2016 Thomas W. Doeppner. All rights reserved. Random-Access Memory (RAM) Key features RAM is traditionally packaged as a chip basic

More information

Systems Programming and Computer Architecture ( ) Timothy Roscoe

Systems Programming and Computer Architecture ( ) Timothy Roscoe Systems Group Department of Computer Science ETH Zürich Systems Programming and Computer Architecture (252-0061-00) Timothy Roscoe Herbstsemester 2016 AS 2016 Caches 1 16: Caches Computer Architecture

More information

Real instruction set architectures. Part 2: a representative sample

Real instruction set architectures. Part 2: a representative sample Real instruction set architectures Part 2: a representative sample Some historical architectures VAX: Digital s line of midsize computers, dominant in academia in the 70s and 80s Characteristics: Variable-length

More information

The Memory Hierarchy 10/25/16

The Memory Hierarchy 10/25/16 The Memory Hierarchy 10/25/16 Transition First half of course: hardware focus How the hardware is constructed How the hardware works How to interact with hardware Second half: performance and software

More information

virtual memory. March 23, Levels in Memory Hierarchy. DRAM vs. SRAM as a Cache. Page 1. Motivation #1: DRAM a Cache for Disk

virtual memory. March 23, Levels in Memory Hierarchy. DRAM vs. SRAM as a Cache. Page 1. Motivation #1: DRAM a Cache for Disk 5-23 March 23, 2 Topics Motivations for VM Address translation Accelerating address translation with TLBs Pentium II/III system Motivation #: DRAM a Cache for The full address space is quite large: 32-bit

More information

CS24: INTRODUCTION TO COMPUTING SYSTEMS. Spring 2014 Lecture 14

CS24: INTRODUCTION TO COMPUTING SYSTEMS. Spring 2014 Lecture 14 CS24: INTRODUCTION TO COMPUTING SYSTEMS Spring 2014 Lecture 14 LAST TIME! Examined several memory technologies: SRAM volatile memory cells built from transistors! Fast to use, larger memory cells (6+ transistors

More information

CS356: Discussion #9 Memory Hierarchy and Caches. Marco Paolieri Illustrations from CS:APP3e textbook

CS356: Discussion #9 Memory Hierarchy and Caches. Marco Paolieri Illustrations from CS:APP3e textbook CS356: Discussion #9 Memory Hierarchy and Caches Marco Paolieri (paolieri@usc.edu) Illustrations from CS:APP3e textbook The Memory Hierarchy So far... We modeled the memory system as an abstract array

More information

Basic characteristics & features of 8086 Microprocessor Dr. M. Hebaishy

Basic characteristics & features of 8086 Microprocessor Dr. M. Hebaishy Basic characteristics & features of 8086 Microprocessor Dr. M. Hebaishy Digital Logic Design Ch1-1 8086 Microprocessor Features: The 8086 microprocessor is a 16 bit microprocessor. The term 16 bit means

More information

LECTURE 4: LARGE AND FAST: EXPLOITING MEMORY HIERARCHY

LECTURE 4: LARGE AND FAST: EXPLOITING MEMORY HIERARCHY LECTURE 4: LARGE AND FAST: EXPLOITING MEMORY HIERARCHY Abridged version of Patterson & Hennessy (2013):Ch.5 Principle of Locality Programs access a small proportion of their address space at any time Temporal

More information

CS 61C: Great Ideas in Computer Architecture. The Memory Hierarchy, Fully Associative Caches

CS 61C: Great Ideas in Computer Architecture. The Memory Hierarchy, Fully Associative Caches CS 61C: Great Ideas in Computer Architecture The Memory Hierarchy, Fully Associative Caches Instructor: Alan Christopher 7/09/2014 Summer 2014 -- Lecture #10 1 Review of Last Lecture Floating point (single

More information

Memory Management! How the hardware and OS give application pgms:" The illusion of a large contiguous address space" Protection against each other"

Memory Management! How the hardware and OS give application pgms: The illusion of a large contiguous address space Protection against each other Memory Management! Goals of this Lecture! Help you learn about:" The memory hierarchy" Spatial and temporal locality of reference" Caching, at multiple levels" Virtual memory" and thereby " How the hardware

More information

CS162 Operating Systems and Systems Programming Lecture 14. Caching (Finished), Demand Paging

CS162 Operating Systems and Systems Programming Lecture 14. Caching (Finished), Demand Paging CS162 Operating Systems and Systems Programming Lecture 14 Caching (Finished), Demand Paging October 11 th, 2017 Neeraja J. Yadwadkar http://cs162.eecs.berkeley.edu Recall: Caching Concept Cache: a repository

More information

Chapter 5 (Part II) Large and Fast: Exploiting Memory Hierarchy. Baback Izadi Division of Engineering Programs

Chapter 5 (Part II) Large and Fast: Exploiting Memory Hierarchy. Baback Izadi Division of Engineering Programs Chapter 5 (Part II) Baback Izadi Division of Engineering Programs bai@engr.newpaltz.edu Virtual Machines Host computer emulates guest operating system and machine resources Improved isolation of multiple

More information

CSE 153 Design of Operating Systems

CSE 153 Design of Operating Systems CSE 153 Design of Operating Systems Winter 2018 Lecture 20: File Systems (1) Disk drives OS Abstractions Applications Process File system Virtual memory Operating System CPU Hardware Disk RAM CSE 153 Lecture

More information

CS24: INTRODUCTION TO COMPUTING SYSTEMS. Spring 2018 Lecture 24

CS24: INTRODUCTION TO COMPUTING SYSTEMS. Spring 2018 Lecture 24 CS24: INTRODUCTION TO COMPUTING SYSTEMS Spring 2018 Lecture 24 LAST TIME Extended virtual memory concept to be a cache of memory stored on disk DRAM becomes L4 cache of data stored on L5 disk Extend page

More information

icroprocessor istory of Microprocessor ntel 8086:

icroprocessor istory of Microprocessor ntel 8086: Microprocessor A microprocessor is an electronic device which computes on the given input similar to CPU of a computer. It is made by fabricating millions (or billions) of transistors on a single chip.

More information

Page 1. Review: Address Segmentation " Review: Address Segmentation " Review: Address Segmentation "

Page 1. Review: Address Segmentation  Review: Address Segmentation  Review: Address Segmentation Review Address Segmentation " CS162 Operating Systems and Systems Programming Lecture 10 Caches and TLBs" February 23, 2011! Ion Stoica! http//inst.eecs.berkeley.edu/~cs162! 1111 0000" 1110 000" Seg #"

More information

Memory Technology. Chapter 5. Principle of Locality. Chapter 5 Large and Fast: Exploiting Memory Hierarchy 1

Memory Technology. Chapter 5. Principle of Locality. Chapter 5 Large and Fast: Exploiting Memory Hierarchy 1 COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface Chapter 5 Large and Fast: Exploiting Memory Hierarchy 5 th Edition Memory Technology Static RAM (SRAM) 0.5ns 2.5ns, $2000 $5000 per GB Dynamic

More information

Microprocessor. By Mrs. R.P.Chaudhari Mrs.P.S.Patil

Microprocessor. By Mrs. R.P.Chaudhari Mrs.P.S.Patil Microprocessor By Mrs. R.P.Chaudhari Mrs.P.S.Patil Chapter 1 Basics of Microprocessor CO-Draw Architecture Of 8085 Salient Features of 8085 It is a 8 bit microprocessor. It is manufactured with N-MOS technology.

More information

Lecture 5:8086 Outline: 1. introduction 2. execution unit 3. bus interface unit

Lecture 5:8086 Outline: 1. introduction 2. execution unit 3. bus interface unit Lecture 5:8086 Outline: 1. introduction 2. execution unit 3. bus interface unit 1 1. introduction The internal function of 8086 processor are partitioned logically into processing units,bus Interface Unit(BIU)

More information

Random-Access Memory (RAM) Lecture 13 The Memory Hierarchy. Conventional DRAM Organization. SRAM vs DRAM Summary. Topics. d x w DRAM: Key features

Random-Access Memory (RAM) Lecture 13 The Memory Hierarchy. Conventional DRAM Organization. SRAM vs DRAM Summary. Topics. d x w DRAM: Key features Random-ccess Memory (RM) Lecture 13 The Memory Hierarchy Topics Storage technologies and trends Locality of reference Caching in the hierarchy Key features RM is packaged as a chip. Basic storage unit

More information

SPRING TERM BM 310E MICROPROCESSORS LABORATORY PRELIMINARY STUDY

SPRING TERM BM 310E MICROPROCESSORS LABORATORY PRELIMINARY STUDY BACKGROUND 8086 CPU has 8 general purpose registers listed below: AX - the accumulator register (divided into AH / AL): 1. Generates shortest machine code 2. Arithmetic, logic and data transfer 3. One

More information

CS 31: Intro to Systems Caching. Kevin Webb Swarthmore College March 24, 2015

CS 31: Intro to Systems Caching. Kevin Webb Swarthmore College March 24, 2015 CS 3: Intro to Systems Caching Kevin Webb Swarthmore College March 24, 205 Reading Quiz Abstraction Goal Reality: There is no one type of memory to rule them all! Abstraction: hide the complex/undesirable

More information

Lecture 19: Virtual Memory: Concepts

Lecture 19: Virtual Memory: Concepts CSCI-UA.2-3 Computer Systems Organization Lecture 9: Virtual Memory: Concepts Mohamed Zahran (aka Z) mzahran@cs.nyu.edu http://www.mzahran.com Some slides adapted (and slightly modified) from: Clark Barrett

More information

Memory Hierarchy, Fully Associative Caches. Instructor: Nick Riasanovsky

Memory Hierarchy, Fully Associative Caches. Instructor: Nick Riasanovsky Memory Hierarchy, Fully Associative Caches Instructor: Nick Riasanovsky Review Hazards reduce effectiveness of pipelining Cause stalls/bubbles Structural Hazards Conflict in use of datapath component Data

More information

Memory Management. Goals of this Lecture. Motivation for Memory Hierarchy

Memory Management. Goals of this Lecture. Motivation for Memory Hierarchy Memory Management Goals of this Lecture Help you learn about: The memory hierarchy Spatial and temporal locality of reference Caching, at multiple levels Virtual memory and thereby How the hardware and

More information

Embedded Systems Dr. Santanu Chaudhury Department of Electrical Engineering Indian Institute of Technology, Delhi

Embedded Systems Dr. Santanu Chaudhury Department of Electrical Engineering Indian Institute of Technology, Delhi Embedded Systems Dr. Santanu Chaudhury Department of Electrical Engineering Indian Institute of Technology, Delhi Lecture - 13 Virtual memory and memory management unit In the last class, we had discussed

More information

Virtual Memory. Computer Systems Principles

Virtual Memory. Computer Systems Principles Virtual Memory Computer Systems Principles Objectives Virtual Memory What is it? How does it work? Virtual Memory Address Translation /7/25 CMPSCI 23 - Computer Systems Principles 2 Problem Lots of executing

More information

Memory Management! Goals of this Lecture!

Memory Management! Goals of this Lecture! Memory Management! Goals of this Lecture! Help you learn about:" The memory hierarchy" Why it works: locality of reference" Caching, at multiple levels" Virtual memory" and thereby " How the hardware and

More information

CS6303 Computer Architecture Regulation 2013 BE-Computer Science and Engineering III semester 2 MARKS

CS6303 Computer Architecture Regulation 2013 BE-Computer Science and Engineering III semester 2 MARKS CS6303 Computer Architecture Regulation 2013 BE-Computer Science and Engineering III semester 2 MARKS UNIT-I OVERVIEW & INSTRUCTIONS 1. What are the eight great ideas in computer architecture? The eight

More information

Operating Systems CMPSCI 377 Spring Mark Corner University of Massachusetts Amherst

Operating Systems CMPSCI 377 Spring Mark Corner University of Massachusetts Amherst Operating Systems CMPSCI 377 Spring 2017 Mark Corner University of Massachusetts Amherst Last Class: Intro to OS An operating system is the interface between the user and the architecture. User-level Applications

More information

Virtual Memory I. CSE 351 Spring Instructor: Ruth Anderson

Virtual Memory I. CSE 351 Spring Instructor: Ruth Anderson Virtual Memory I CSE 35 Spring 27 Instructor: Ruth Anderson Teaching Assistants: Dylan Johnson Kevin Bi Linxing Preston Jiang Cody Ohlsen Yufang Sun Joshua Curtis Administrivia Midterms Graded If you did

More information

CS 33. Architecture and Optimization (3) CS33 Intro to Computer Systems XVI 1 Copyright 2018 Thomas W. Doeppner. All rights reserved.

CS 33. Architecture and Optimization (3) CS33 Intro to Computer Systems XVI 1 Copyright 2018 Thomas W. Doeppner. All rights reserved. CS 33 Architecture and Optimization (3) CS33 Intro to Computer Systems XVI 1 Copyright 2018 Thomas W. Doeppner. All rights reserved. Hyper Threading Instruction Control Instruction Control Retirement Unit

More information

Review: Performance Latency vs. Throughput. Time (seconds/program) is performance measure Instructions Clock cycles Seconds.

Review: Performance Latency vs. Throughput. Time (seconds/program) is performance measure Instructions Clock cycles Seconds. Performance 980 98 982 983 984 985 986 987 988 989 990 99 992 993 994 995 996 997 998 999 2000 7/4/20 CS 6C: Great Ideas in Computer Architecture (Machine Structures) Caches Instructor: Michael Greenbaum

More information

Chapter 5 Memory Hierarchy Design. In-Cheol Park Dept. of EE, KAIST

Chapter 5 Memory Hierarchy Design. In-Cheol Park Dept. of EE, KAIST Chapter 5 Memory Hierarchy Design In-Cheol Park Dept. of EE, KAIST Why cache? Microprocessor performance increment: 55% per year Memory performance increment: 7% per year Principles of locality Spatial

More information

16-Bit Intel Processor Architecture

16-Bit Intel Processor Architecture IBM-PC Organization 16-Bit Intel Processor Architecture A-16 bit microprocessor can operate on 16 bits of data at a time. 8086/8088 have the simplest structure 8086/8088 have the same instruction set,

More information

The x86 Microprocessors. Introduction. The 80x86 Microprocessors. 1.1 Assembly Language

The x86 Microprocessors. Introduction. The 80x86 Microprocessors. 1.1 Assembly Language The x86 Microprocessors Introduction 1.1 Assembly Language Numbering and Coding Systems Human beings use the decimal system (base 10) Decimal digits: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 Computer systems use the

More information

The Memory Hierarchy / : Introduction to Computer Systems 10 th Lecture, Feb 12, 2015

The Memory Hierarchy / : Introduction to Computer Systems 10 th Lecture, Feb 12, 2015 The Memory Hierarchy 15-213 / 18-213: Introduction to Computer Systems 10 th Lecture, Feb 12, 2015 Instructors: Seth Copen Goldstein, Franz Franchetti, Greg Kesden 1 Today The Memory Abstraction DRAM :

More information

Assembly Language. Lecture 2 - x86 Processor Architecture. Ahmed Sallam

Assembly Language. Lecture 2 - x86 Processor Architecture. Ahmed Sallam Assembly Language Lecture 2 - x86 Processor Architecture Ahmed Sallam Introduction to the course Outcomes of Lecture 1 Always check the course website Don t forget the deadline rule!! Motivations for studying

More information

+ Random-Access Memory (RAM)

+ Random-Access Memory (RAM) + Memory Subsystem + Random-Access Memory (RAM) Key features RAM is traditionally packaged as a chip. Basic storage unit is normally a cell (one bit per cell). Multiple RAM chips form a memory. RAM comes

More information

Computer Systems Architecture I. CSE 560M Lecture 18 Guest Lecturer: Shakir James

Computer Systems Architecture I. CSE 560M Lecture 18 Guest Lecturer: Shakir James Computer Systems Architecture I CSE 560M Lecture 18 Guest Lecturer: Shakir James Plan for Today Announcements No class meeting on Monday, meet in project groups Project demos < 2 weeks, Nov 23 rd Questions

More information

Reducing Hit Times. Critical Influence on cycle-time or CPI. small is always faster and can be put on chip

Reducing Hit Times. Critical Influence on cycle-time or CPI. small is always faster and can be put on chip Reducing Hit Times Critical Influence on cycle-time or CPI Keep L1 small and simple small is always faster and can be put on chip interesting compromise is to keep the tags on chip and the block data off

More information

Assembly Language. Lecture 2 x86 Processor Architecture

Assembly Language. Lecture 2 x86 Processor Architecture Assembly Language Lecture 2 x86 Processor Architecture Ahmed Sallam Slides based on original lecture slides by Dr. Mahmoud Elgayyar Introduction to the course Outcomes of Lecture 1 Always check the course

More information

VM as a cache for disk

VM as a cache for disk Virtualization Virtual Memory Computer Systems Organization (Spring 2017) CSCI-UA 201, Section 3 Instructor: Joanna Klukowska Virtualization of a resource: presenting a user with a different view of that

More information

The Memory Hierarchy Sept 29, 2006

The Memory Hierarchy Sept 29, 2006 15-213 The Memory Hierarchy Sept 29, 2006 Topics Storage technologies and trends Locality of reference Caching in the memory hierarchy class10.ppt Random-Access Memory (RAM) Key features RAM is traditionally

More information

Last class: Today: Course administration OS definition, some history. Background on Computer Architecture

Last class: Today: Course administration OS definition, some history. Background on Computer Architecture 1 Last class: Course administration OS definition, some history Today: Background on Computer Architecture 2 Canonical System Hardware CPU: Processor to perform computations Memory: Programs and data I/O

More information

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 27, SPRING 2013

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 27, SPRING 2013 CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 27, SPRING 2013 CACHING Why: bridge speed difference between CPU and RAM Modern RAM allows blocks of memory to be read quickly Principle

More information

Chapter 5. Large and Fast: Exploiting Memory Hierarchy

Chapter 5. Large and Fast: Exploiting Memory Hierarchy Chapter 5 Large and Fast: Exploiting Memory Hierarchy Processor-Memory Performance Gap 10000 µproc 55%/year (2X/1.5yr) Performance 1000 100 10 1 1980 1983 1986 1989 Moore s Law Processor-Memory Performance

More information

John Wawrzynek & Nick Weaver

John Wawrzynek & Nick Weaver CS 61C: Great Ideas in Computer Architecture Lecture 23: Virtual Memory John Wawrzynek & Nick Weaver http://inst.eecs.berkeley.edu/~cs61c From Previous Lecture: Operating Systems Input / output (I/O) Memory

More information

Virtual Memory. Reading. Sections 5.4, 5.5, 5.6, 5.8, 5.10 (2) Lecture notes from MKP and S. Yalamanchili

Virtual Memory. Reading. Sections 5.4, 5.5, 5.6, 5.8, 5.10 (2) Lecture notes from MKP and S. Yalamanchili Virtual Memory Lecture notes from MKP and S. Yalamanchili Sections 5.4, 5.5, 5.6, 5.8, 5.10 Reading (2) 1 The Memory Hierarchy ALU registers Cache Memory Memory Memory Managed by the compiler Memory Managed

More information