External Memory Algorithms and Data Structures. Winter 2004/2005

Similar documents
Cache-Oblivious Algorithms A Unified Approach to Hierarchical Memory Algorithms

Introduction to I/O Efficient Algorithms (External Memory Model)

Sorting atomic items. Chapter 5

Succinct Data Structures: Theory and Practice

Hierarchical Memory. Modern machines have complicated memory hierarchy

BRICS Research Activities Algorithms

Computer Organization

Massive Data Algorithmics

Computer Organization

Cache-Oblivious String Dictionaries

Algorithm Performance Factors. Memory Performance of Algorithms. Processor-Memory Performance Gap. Moore s Law. Program Model of Memory I

Data Storage and Query Answering. Data Storage and Disk Structure (2)

The Cost of Address Translation

Memory Hierarchies. Instructor: Dmitri A. Gusev. Fall Lecture 10, October 8, CS 502: Computers and Communications Technology

External Sorting. Chapter 13. Database Management Systems 3ed, R. Ramakrishnan and J. Gehrke 1

Lecture 9 March 15, 2012

Report Seminar Algorithm Engineering

CS542. Algorithms on Secondary Storage Sorting Chapter 13. Professor E. Rundensteiner. Worcester Polytechnic Institute

Lecture 24 November 24, 2015

Data Storage and Disk Structure

Massive Data Algorithmics. Lecture 1: Introduction

ICS 691: Advanced Data Structures Spring Lecture 8

The History of I/O Models Erik Demaine

ADDRESS TRANSLATION AND TLB

ADDRESS TRANSLATION AND TLB

ECE331: Hardware Organization and Design

I/O Efficieny of Highway Hierarchies

External Memory. Philip Bille

Storage Devices for Database Systems

Master Thesis Preparation. Algorithms. Gerth Stølting Brodal

EECS 482 Introduction to Operating Systems

COMP 273 Winter physical vs. virtual mem Mar. 15, 2012

ECE232: Hardware Organization and Design

C has been and will always remain on top for performancecritical

COMPUTER SYSTEM. COMPUTER SYSTEM IB DP Computer science Standard Level ICS3U. COMPUTER SYSTEM IB DP Computer science Standard Level ICS3U

Recap: Machine Organization

Module Outline. CPU Memory interaction Organization of memory modules Cache memory Mapping and replacement policies.

Lecture-14 (Memory Hierarchy) CS422-Spring

High Performance Computing Lecture 26. Matthew Jacob Indian Institute of Science

ECE232: Hardware Organization and Design

Memory hierarchy and cache

Lab Determining Data Storage Capacity

STORING DATA: DISK AND FILES

Algorithm Performance Factors. Memory Performance of Algorithms. Processor-Memory Performance Gap. Moore s Law. Program Model of Memory II

Virtual Memory. Daniel Sanchez Computer Science & Artificial Intelligence Lab M.I.T. November 15, MIT Fall 2018 L20-1

This calculation converts 3562 from base 10 to base 8 octal. Digits are produced right to left, so the final answer is 6752.

Lecture 2: Memory Systems

Electricity: Voltage. Gate: A signal enters the gate at a certain voltage. The gate performs operations on it, and sends it out was a new signal.

Chapter 12: Query Processing

External Sorting. Chapter 13. Database Management Systems 3ed, R. Ramakrishnan and J. Gehrke 1

Improving System. Performance: Caches

Virtual Memory Nov 9, 2009"

Cache Memory and Performance

Princeton University. Computer Science 217: Introduction to Programming Systems. The Memory/Storage Hierarchy and Virtual Memory

CSE 373 OCTOBER 23 RD MEMORY AND HARDWARE

Virtual Memory. Daniel Sanchez Computer Science & Artificial Intelligence Lab M.I.T. April 12, 2018 L16-1

Virtual Memory Review. Page faults. Paging system summary (so far)

Review of course COMP-251B winter 2010

6.033 Computer System Engineering

Management Information Systems OUTLINE OBJECTIVES. Information Systems: Computer Hardware. Dr. Shankar Sundaresan

CS162 - Operating Systems and Systems Programming. Address Translation => Paging"

12: Memory Management

Weaving Relations for Cache Performance

CSE 451: Operating Systems Winter Lecture 12 Secondary Storage. Steve Gribble 323B Sieg Hall.

COSC 6385 Computer Architecture. - Memory Hierarchies (I)

CS780: Topics in Computer Graphics

Virtual Memory - Objectives

The Memory Hierarchy & Cache

Administrivia. HW0 scores, HW1 peer-review assignments out. If you re having Cython trouble with HW2, let us know.

Topic 18 (updated): Virtual Memory

Engineering a Cache-Oblivious Sorting Algorithm

Preview. Memory Management

CS 310: Memory Hierarchy and B-Trees

Accelerating Foreign-Key Joins using Asymmetric Memory Channels

Cache Memory COE 403. Computer Architecture Prof. Muhamed Mudawar. Computer Engineering Department King Fahd University of Petroleum and Minerals

CMSC 104 -Lecture 2 John Y. Park, adapted by C Grasso

Virtual Memory. 11/8/16 (election day) Vote!

goals monitoring, fault tolerance, auto-recovery (thousands of low-cost machines) handle appends efficiently (no random writes & sequential reads)

Sort vs. Hash Join Revisited for Near-Memory Execution. Nooshin Mirzadeh, Onur Kocberber, Babak Falsafi, Boris Grot

Virtual Memory. Virtual Memory

Caches and Memory Hierarchy: Review. UCSB CS240A, Winter 2016

MEMORY BHARAT SCHOOL OF BANKING- VELLORE

Computer Organization

Algorithms and Data Structures: Lower Bounds for Sorting. ADS: lect 7 slide 1

Comparison Based Sorting Algorithms. Algorithms and Data Structures: Lower Bounds for Sorting. Comparison Based Sorting Algorithms

Intro to Computers in Arabic!!!!! MAI ELSHEHALY

Algorithms and Data Structures Group. Gerth Stølting Brodal

Georgia Institute of Technology ECE6102 4/20/2009 David Colvin, Jimmy Vuong

Distributed File Systems Part IV. Hierarchical Mass Storage Systems

CS61C Review of Cache/VM/TLB. Lecture 26. April 30, 1999 Dave Patterson (http.cs.berkeley.edu/~patterson)

CS 201 The Memory Hierarchy. Gerson Robboy Portland State University

CSE 326: Data Structures B-Trees and B+ Trees

Chapter 1: Introduction Dr. Ali Fanian. Operating System Concepts 9 th Edit9on

Fully Persistent B-Trees

Engineering a Cache-Oblivious Sorting Algorithm

Day 3. Storage Devices + Types of Memory + Measuring Memory + Computer Performance

Funnel Heap - A Cache Oblivious Priority Queue

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

Finding a Needle in a Haystack. Facebook s Photo Storage Jack Hartner

Chapter Seven. Memories: Review. Exploiting Memory Hierarchy CACHE MEMORY AND VIRTUAL MEMORY

Transcription:

External Memory Algorithms and Data Structures Winter 2004/2005 Riko Jacob Peter Widmayer Assignments: Yoshio Okamoto EMADS 04/ 05: Course Description Page 1

External Memory Algorithms and Data Structures Winter 2004/2005 Riko Jacob Peter Widmayer Assignments: Yoshio Okamoto based on a lecture in Aarhus, DK, by Gerth Stølting Brodal and Rolf Fagerberg EMADS 04/ 05: Course Description Page 1

Course Lectures: Based on articles. Theoretical. New stuff: 1995-2004. Aim: General principles and methods. EMADS 04/ 05: Course Description Page 2

Course Lectures: Based on articles. Theoretical. New stuff: 1995-2004. Aim: General principles and methods. Homepage: www.ti.inf.ethz.ch/ew/courses/emads04/ EMADS 04/ 05: Course Description Page 2

Analysis of algorithms The standard model: Memory CPU EMADS 04/ 05: Course Description Page 3

Analysis of algorithms The standard model: Memory CPU Add: 1 unit of time Mult: 1 unit of time Branch: 1 unit of time MemAccess: 1 unit of time EMADS 04/ 05: Course Description Page 3

Reality Memory hierarchy: RAM CPU Cache2 Reg. Cache1 Disk Tertiary Storage EMADS 04/ 05: Course Description Page 4

Reality Memory hierarchy: RAM CPU Cache2 Reg. Cache1 Disk Tertiary Storage Access time Volume Registers 1 cycle 1 Kb Cache 5 cycles 512 Kb RAM 50 cycles 512 Mb Disk 20,000,000 cycles 80 Gb EMADS 04/ 05: Course Description Page 4

Reality Memory hierarchy: RAM CPU Cache2 Reg. Cache1 Disk Tertiary Storage Access time Volume Registers 1 cycle 1 Kb Cache 5 cycles 512 Kb RAM 50 cycles 512 Mb Disk 20,000,000 cycles 80 Gb CPU speed improves faster than RAM access time and much faster than disk access time EMADS 04/ 05: Course Description Page 4

Reality Many real-life problems of Gigabyte, Terabyte, and even Petabyte size: Databases weather geology/geograpy astrology financial WWW phone companies Geographic Information Systems (maps). Computer graphics, animation. VLSI design. EMADS 04/ 05: Course Description Page 5

I/O bottleneck I/O is the bottleneck I/O should be optimized (not instruction count) EMADS 04/ 05: Course Description Page 6

Analysis of algorithms New I/O-model: CPU Memory 1 Block Memory 2 EMADS 04/ 05: Course Description Page 7

Analysis of algorithms New I/O-model: CPU Memory 1 Block Memory 2 Parameters: N = no. of elements in problem. M = no. of elements that fit in RAM. B = no. of elements in a block on disk. D = no. of disks (copies of Memory 2) EMADS 04/ 05: Course Description Page 7

Analysis of algorithms New I/O-model: CPU Memory 1 Block Memory 2 Parameters: N = no. of elements in problem. M = no. of elements that fit in RAM. B = no. of elements in a block on disk. D = no. of disks (copies of Memory 2) Cost: Number of I/O s (block transfers) between Memory 1 and Memory 2. EMADS 04/ 05: Course Description Page 7

Generic Example Consider two O(n) algorithms: 1. Memory accessed randomly page fault at each memory access. 2. Memory accessed sequentially page fault every B memory accesses. EMADS 04/ 05: Course Description Page 8

Generic Example Consider two O(n) algorithms: 1. Memory accessed randomly page fault at each memory access. 2. Memory accessed sequentially page fault every B memory accesses. EMADS 04/ 05: Course Description Page 8

Generic Example Consider two O(n) algorithms: 1. Memory accessed randomly page fault at each memory access. 2. Memory accessed sequentially page fault every B memory accesses. EMADS 04/ 05: Course Description Page 8

Generic Example Consider two O(n) algorithms: 1. Memory accessed randomly page fault at each memory access. 2. Memory accessed sequentially page fault every B memory accesses. EMADS 04/ 05: Course Description Page 8

Generic Example Consider two O(n) algorithms: 1. Memory accessed randomly page fault at each memory access. 2. Memory accessed sequentially page fault every B memory accesses. EMADS 04/ 05: Course Description Page 8

Generic Example Consider two O(n) algorithms: 1. Memory accessed randomly page fault at each memory access. 2. Memory accessed sequentially page fault every B memory accesses. EMADS 04/ 05: Course Description Page 8

Generic Example Consider two O(n) algorithms: 1. Memory accessed randomly page fault at each memory access. 2. Memory accessed sequentially page fault every B memory accesses. EMADS 04/ 05: Course Description Page 8

Generic Example Consider two O(n) algorithms: 1. Memory accessed randomly page fault at each memory access. 2. Memory accessed sequentially page fault every B memory accesses. EMADS 04/ 05: Course Description Page 8

Generic Example Consider two O(n) algorithms: 1. Memory accessed randomly page fault at each memory access. 2. Memory accessed sequentially page fault every B memory accesses. EMADS 04/ 05: Course Description Page 8

Generic Example Consider two O(n) algorithms: 1. Memory accessed randomly page fault at each memory access. 2. Memory accessed sequentially page fault every B memory accesses. O(N) I/Os vs. O(N/B) I/Os Typically, B 10 3. EMADS 04/ 05: Course Description Page 8

Specific Examples QuickSort sequential access vs. HeapSort random access QuickSort: HeapSort: O(N log 2 (N/M)/B) O(N log 2 (N/M)) EMADS 04/ 05: Course Description Page 9

Course Contents (approximate): The I/O model(s). Algorithms, data structures, and lower bounds for basic problems: Permuting Sorting Searching I/O efficient algorithms and data structures for problems from computational geometry, strings, graphs. EMADS 04/ 05: Course Description Page 10

Course Contents (approximate): The I/O model(s). Algorithms, data structures, and lower bounds for basic problems: Permuting Sorting Searching I/O efficient algorithms and data structures for problems from computational geometry, strings, graphs. Along the way I: Generic principles for designing I/O-efficient algorithms. Along the way II: Hands-on experience via projects. EMADS 04/ 05: Course Description Page 10