Discussion Session 9. CS/ECE 552 Ramkumar Ravi 26 Mar 2012



Similar documents
Outline. Cache Parameters. Lecture 5 Cache Operation

The Quest for Speed - Memory. Cache Memory. A Solution: Memory Hierarchy. Memory Hierarchy

We r e going to play Final (exam) Jeopardy! "Answers:" "Questions:" - 1 -

Base Conversion written by Cathy Saxton

Table 1 below is a complete list of MPTH commands with descriptions. Table 1 : MPTH Commands. Command Name Code Setting Value Description

Counting in base 10, 2 and 16

Useful Number Systems

Board Notes on Virtual Memory

CS101 Lecture 11: Number Systems and Binary Numbers. Aaron Stevens 14 February 2011

Outlook 2003/2007 NK2 File Format and Developer Guidelines

The Big Picture. Cache Memory CSE Memory Hierarchy (1/3) Disk

CS201: Architecture and Assembly Language

GW-7552 PRIFIBUS/MODBUS GATEWAY

Decimal to Binary Conversion

1. Give the 16 bit signed (twos complement) representation of the following decimal numbers, and convert to hexadecimal:

Technical Support Bulletin Nr.18 Modbus Tips

18-548/ Associativity 9/16/98. 7 Associativity / Memory System Architecture Philip Koopman September 16, 1998

ELEG3924 Microprocessor Ch.7 Programming In C

ACR122 NFC Contactless Smart Card Reader

Homework # 2. Solutions. 4.1 What are the differences among sequential access, direct access, and random access?

CS 61C: Great Ideas in Computer Architecture Virtual Memory Cont.

Memory ICS 233. Computer Architecture and Assembly Language Prof. Muhamed Mudawar

Chapter 7 Lab - Decimal, Binary, Octal, Hexadecimal Numbering Systems

Computer Architecture

Experiment # 9. Clock generator circuits & Counters. Eng. Waleed Y. Mousa

Number of bits needed to address hosts 8

WIZnet S2E (Serial-to-Ethernet) Device s Configuration Tool Programming Guide

Internet Addresses (You should read Chapter 4 in Forouzan)

Binary Representation

Fingerprint Based Biometric Attendance System

Nemo 96HD/HD+ MODBUS

Lecture 2. Binary and Hexadecimal Numbers

Counters. Present State Next State A B A B

Numbering Systems. InThisAppendix...

SRF08 Ultra sonic range finder Technical Specification

Machine Architecture and Number Systems. Major Computer Components. Schematic Diagram of a Computer. The CPU. The Bus. Main Memory.

Dualog Connection Suite Hardware and Software Requirements

Memory is implemented as an array of electronic switches

Chapter 5 Instructor's Manual

ENGG*44200 Real Time System Design Lab3 Implement VoIP on ARM Outline

UM0853 User manual. 1 Introduction. M24LRxx application software user guide

x10* CP290 HOME CONTROL INTERFACE PROGRAMMING GUIDE FOR ADVANCED PROGRAMMERS

Computer Organization and Architecture. Characteristics of Memory Systems. Chapter 4 Cache Memory. Location CPU Registers and control unit memory

Section 1.4 Place Value Systems of Numeration in Other Bases

14.1 Rent-or-buy problem

Binary, Hexadecimal, Octal, and BCD Numbers

Lab 17: Building a 4-Digit 7-Segment LED Decoder

Lecture 11: Number Systems

Lecture 17: Virtual Memory II. Goals of virtual memory

SYMETRIX SOLUTIONS: TECH TIP August 2015

=

ISOBUS Task Controller Workshop. Presented by Andy Beck / Hans Nissen John Deere

Caml Virtual Machine File & data formats Document version: 1.4

Let s put together a Manual Processor

Instruction Set Architecture (ISA)

Getting started with DfuSe USB device firmware upgrade STMicroelectronics extension

plc numbers Encoded values; BCD and ASCII Error detection; parity, gray code and checksums

The Hexadecimal Number System and Memory Addressing

Today. Binary addition Representing negative numbers. Andrew H. Fagg: Embedded Real- Time Systems: Binary Arithmetic

361 Computer Architecture Lecture 14: Cache Memory

Absolute Backdoor Revisited. Vitaliy Kamlyuk, Kaspersky Lab Sergey Belov, Kaspersky Lab Anibal Sacco, Cubica Labs

isppac-powr1220at8 I 2 C Hardware Verification Utility User s Guide

FREE TV AUSTRALIA OPERATIONAL PRACTICE OP42

Consult protocol, Nissan Technical egroup, Issue 6

MODBUS APPLICATION PROTOCOL SPECIFICATION V1.1b3 CONTENTS

BCD (ASCII) Arithmetic. Where and Why is BCD used? Packed BCD, ASCII, Unpacked BCD. BCD Adjustment Instructions AAA. Example

The Orca Chip... Heart of IBM s RISC System/6000 Value Servers

UNIVERSITY OF CALIFORNIA, DAVIS Department of Electrical and Computer Engineering. EEC180B Lab 7: MISP Processor Design Spring 1995

MODBUS APPLICATION PROTOCOL SPECIFICATION V1.1b CONTENTS

USB Simply Buffered (USB) Mass Storage Class Bulk-Only Transport

2011, The McGraw-Hill Companies, Inc. Chapter 3

Byte Ordering of Multibyte Data Items

Traditional IBM Mainframe Operating Principles

Application Note. Introduction AN2471/D 3/2003. PC Master Software Communication Protocol Specification

Chapter 1 Computer System Overview

A Predictive Model for Cache-Based Side Channels in Multicore and Multithreaded Microprocessors

Bluetooth HID Profile

3. Convert a number from one number system to another

APP INVENTOR. Test Review

PROGRAMMABLE LOGIC CONTROLLERS Unit code: A/601/1625 QCF level: 4 Credit value: 15 TUTORIAL OUTCOME 2 Part 1

CPU Organisation and Operation

SUBNETS, CIDR, AND CLASSLESS ADDRESSING

CS:APP Chapter 4 Computer Architecture. Wrap-Up. William J. Taffe Plymouth State University. using the slides of

Hacking cars in the style of Stuxnet

Dolphin In-Circuit programming Updating Firmware in the field

Application Programming Interface

IBM Emulation Mode Printer Commands

Life Cycle of a Memory Request. Ring Example: 2 requests for lock 17

CS/COE1541: Introduction to Computer Architecture. Memory hierarchy. Sangyeun Cho. Computer Science Department University of Pittsburgh

Memory Management Simulation Interactive Lab

Solution for Homework 2

Mifare DESFire Specification

Section 29. Real-Time Clock and Calendar (RTCC)

Data Acquisition Module with I2C interface «I2C-FLEXEL» User s Guide

Chapter 4: Computer Codes

Addressing The problem. When & Where do we encounter Data? The concept of addressing data' in computations. The implications for our machine design(s)

Transcription:

Discussion Session 9 CS/ECE 55 Ramkumar Ravi 6 Mar CS/ECE 55, Spring

Mark your calendar IMPORTANT DATES TODAY 4/ Spring break 4/ HW5 due 4/ Project Demo HW5 discussion Error in mem_system_randbench.v (will be corrected and uploaded in course webpage) Other test-bench modules look OK Modification to problem 5 Discussion of a sample state-machine and show sample code (if time permits)

Problems and 4 Cache Parameters SIZE = total amount of cache data storage, in bytes BLOCKSIZE = total number of bytes in a single ASSOC = associativity, i.e., # of lines in a set Equation for # of cache lines in cache = size / size Equation for # of sets in cache = size / (size * associativity) You may need this for few of the problems in this HW

Address Fields Tag field is compared to the (s) of the ed cache line(s). If it matches, is there (hit). If it doesn t match, is not there (miss). Used to look up a set, whose lines contain one or more memory s. (The # of lines per set is the associativity.) Once a is found, the selects a particular byte or word of data in the.

Address Fields (cont.) Widths of address fields (# bits) # bits = log (# sets) # bits = log ( size) # bits = # bits # bits Assuming -bit addresses

Example of cache operation Example: Processor accesses a 56-byte direct-mapped cache, which has -byte lines, with the following sequence of addresses. Show contents of the cache after each access. Count # of hits and # of replacements. # bits = log (# sets) = log (8) = # bits = log ( size) = log ( bytes) = 5 # bits = total # address bits # bits # bits = bits bits 5 bits = 4 Thus, the top 6 nibbles (4 bits) of address form the and lower nibbles (8 bits) of address form the and fields.

Example address sequence Address (hex) Tag (hex) Index & bits (binary) xff4e xbeef5c xff4e xff4e8 x78 x8e x64 x55c x544 Index (decimal) Comment

Analysis of results follows next Address (hex) Tag (hex) Index & bits (binary) Index (decimal) Comment xff4e xff4 7 Miss xbeef5c xbeef Miss xff4e xff4 7 Hit xff4e8 xff4 7 Hit x78 x Miss x8e x8 7 Miss+Replace x64 x Hit x55c x5 Miss+Replace x544 x5 Hit

4 4 5 6 7 8 7 5 4 FF4 7 Data FF4 FF4 BEEF FF4 FF4 8 5 5 Get from memory (slow)

4 4 5 6 7 8 7 5 4 BEEF Data BEEF FF4 FF4 BEEF FF4 FF4 8 5 5 Get from memory (slow)

4 4 5 6 7 8 7 5 4 FF4 7 Data BEEF FF4 FF4 BEEF FF4 FF4 8 5 5

4 4 5 6 7 8 7 5 4 FF4 7 Data BEEF FF4 FF4 BEEF FF4 FF4 8 5 5

4 4 5 6 7 8 7 5 4 Data BEEF FF4 FF4 BEEF FF4 FF4 8 5 5 Get from memory (slow)

4 4 5 6 7 8 7 5 4 8 7 Data BEEF 8 FF4 FF4 BEEF FF4 FF4 8 5 5 Get from Memory (slow)

4 4 5 6 7 8 7 5 4 BEEF 8 Data FF4 BEEF FF4 FF4 8 5 5

4 4 5 6 7 8 7 5 4 5 5 BEEF 8 Data FF4 BEEF FF4 FF4 8 5 5 Get from memory (slow)

4 4 5 6 7 8 7 5 4 5 Data 5 8 FF4 BEEF FF4 FF4 8 5 5

Set-Associative Example Example: Processor accesses a 56-byte -way set-associative cache, which has line size of bytes, with the following sequence of addresses. Show contents of cache after each access. Count # of hits and # of replacements. # bits = log (# sets) = log (4) = # bits = log ( size) = log ( bytes) = 5 # bits = total # address bits # bits # bits = bits bits 5 bits = 5

Address (hex) Tag (hex) Index & bits (binary) Index (decimal) Comment xff4e xfe8 Miss xbeef5c x7dde Miss x78 x Miss xff4e xfe8 Hit x78 x Hit x8e x47 Miss/Replace x64 x Hit

7 6 5 4 FE8 5 FE8 Data not shown for convenience

7 6 5 4 7DDE 7DDE 5 FE8 Data not shown for convenience

7 6 5 4 7DDE 5 FE8 Data not shown for convenience

7 6 5 4 FE8 7DDE 5 FE8 Data not shown for convenience

7 6 5 4 7DDE 5 FE8 Data not shown for convenience

7 6 5 4 47 7DDE 47 5 FE8 Data not shown for convenience

7 6 5 4 7DDE 5 47 Data not shown for convenience

PROBLEM 5 Total cache storage (capacity) (64-byte s) * (5 sets) * (# of ways) Total number of bits Tag size = 4 bits - # bits - # bits Block size = valid + dirty + LRU + + data

PROBLEMS and Sample FSM presentation Understanding the requirements of the problem