Towards Optimal I/O Scheduling for MEMS-based Storage

Similar documents
The Greedy Method. Outline and Reading. Change Money Problem. Greedy Algorithms. Applications of the Greedy Strategy. The Greedy Method Technique

Parallelism for Nested Loops with Non-uniform and Flow Dependences

6.854 Advanced Algorithms Petar Maymounkov Problem Set 11 (November 23, 2005) With: Benjamin Rossman, Oren Weimann, and Pouya Kheradpour

An Optimal Algorithm for Prufer Codes *

Compiler Design. Spring Register Allocation. Sample Exercises and Solutions. Prof. Pedro C. Diniz

Support Vector Machines

R s s f. m y s. SPH3UW Unit 7.3 Spherical Concave Mirrors Page 1 of 12. Notes

Load Balancing for Hex-Cell Interconnection Network

A Binarization Algorithm specialized on Document Images and Photos

A MOVING MESH APPROACH FOR SIMULATION BUDGET ALLOCATION ON CONTINUOUS DOMAINS

Constructing Minimum Connected Dominating Set: Algorithmic approach

Problem Definitions and Evaluation Criteria for Computational Expensive Optimization

A mathematical programming approach to the analysis, design and scheduling of offshore oilfields

Hermite Splines in Lie Groups as Products of Geodesics

Repeater Insertion for Two-Terminal Nets in Three-Dimensional Integrated Circuits

Dynamic wetting property investigation of AFM tips in micro/nanoscale

Efficient Distributed File System (EDFS)

2x x l. Module 3: Element Properties Lecture 4: Lagrange and Serendipity Elements

Classifier Selection Based on Data Complexity Measures *

A Topology-aware Random Walk

K-means and Hierarchical Clustering

The Shortest Path of Touring Lines given in the Plane

Module Management Tool in Software Development Organizations

Problem Set 3 Solutions

An Entropy-Based Approach to Integrated Information Needs Assessment

Kent State University CS 4/ Design and Analysis of Algorithms. Dept. of Math & Computer Science LECT-16. Dynamic Programming

For instance, ; the five basic number-sets are increasingly more n A B & B A A = B (1)

Parallel matrix-vector multiplication

Non-Split Restrained Dominating Set of an Interval Graph Using an Algorithm

Overview. Basic Setup [9] Motivation and Tasks. Modularization 2008/2/20 IMPROVED COVERAGE CONTROL USING ONLY LOCAL INFORMATION


Quality Improvement Algorithm for Tetrahedral Mesh Based on Optimal Delaunay Triangulation

Programming in Fortran 90 : 2017/2018

SLAM Summer School 2006 Practical 2: SLAM using Monocular Vision

All-Pairs Shortest Paths. Approximate All-Pairs shortest paths Approximate distance oracles Spanners and Emulators. Uri Zwick Tel Aviv University

DESIGNING TRANSMISSION SCHEDULES FOR WIRELESS AD HOC NETWORKS TO MAXIMIZE NETWORK THROUGHPUT

Harvard University CS 101 Fall 2005, Shimon Schocken. Assembler. Elements of Computing Systems 1 Assembler (Ch. 6)

Course Introduction. Algorithm 8/31/2017. COSC 320 Advanced Data Structures and Algorithms. COSC 320 Advanced Data Structures and Algorithms

CHAPTER 2 PROPOSED IMPROVED PARTICLE SWARM OPTIMIZATION

A Fast Content-Based Multimedia Retrieval Technique Using Compressed Data

Improvement of Spatial Resolution Using BlockMatching Based Motion Estimation and Frame. Integration

The Codesign Challenge

Content Based Image Retrieval Using 2-D Discrete Wavelet with Texture Feature with Different Classifiers

CSE 326: Data Structures Quicksort Comparison Sorting Bound

A New Approach For the Ranking of Fuzzy Sets With Different Heights

Topology Design using LS-TaSC Version 2 and LS-DYNA

LOOP ANALYSIS. The second systematic technique to determine all currents and voltages in a circuit

Learning-Based Top-N Selection Query Evaluation over Relational Databases

Outline. Type of Machine Learning. Examples of Application. Unsupervised Learning

Fast Computation of Shortest Path for Visiting Segments in the Plane

Routing in Degree-constrained FSO Mesh Networks

Solitary and Traveling Wave Solutions to a Model. of Long Range Diffusion Involving Flux with. Stability Analysis

TPL-Aware Displacement-driven Detailed Placement Refinement with Coloring Constraints

Assembler. Shimon Schocken. Spring Elements of Computing Systems 1 Assembler (Ch. 6) Compiler. abstract interface.

Accounting for the Use of Different Length Scale Factors in x, y and z Directions

Assignment # 2. Farrukh Jabeen Algorithms 510 Assignment #2 Due Date: June 15, 2009.

Virtual Memory. Background. No. 10. Virtual Memory: concept. Logical Memory Space (review) Demand Paging(1) Virtual Memory

Hierarchical clustering for gene expression data analysis

Cordial and 3-Equitable Labeling for Some Star Related Graphs

Channel 0. Channel 1 Channel 2. Channel 3 Channel 4. Channel 5 Channel 6 Channel 7

VRT012 User s guide V0.1. Address: Žirmūnų g. 27, Vilnius LT-09105, Phone: (370-5) , Fax: (370-5) ,

X- Chart Using ANOM Approach

Cluster Analysis of Electrical Behavior

Analysis of Collaborative Distributed Admission Control in x Networks

Learning the Kernel Parameters in Kernel Minimum Distance Classifier

Module 6: FEM for Plates and Shells Lecture 6: Finite Element Analysis of Shell

Unsupervised Learning

NUMERICAL SOLVING OPTIMAL CONTROL PROBLEMS BY THE METHOD OF VARIATIONS

An Approach in Coloring Semi-Regular Tilings on the Hyperbolic Plane

Subspace clustering. Clustering. Fundamental to all clustering techniques is the choice of distance measure between data points;

VISUAL SELECTION OF SURFACE FEATURES DURING THEIR GEOMETRIC SIMULATION WITH THE HELP OF COMPUTER TECHNOLOGIES

Video Proxy System for a Large-scale VOD System (DINA)

Simulation Based Analysis of FAST TCP using OMNET++

Reducing Frame Rate for Object Tracking

An Iterative Solution Approach to Process Plant Layout using Mixed Integer Optimisation

User Authentication Based On Behavioral Mouse Dynamics Biometrics

Design of Structure Optimization with APDL

Related-Mode Attacks on CTR Encryption Mode

SHAPE RECOGNITION METHOD BASED ON THE k-nearest NEIGHBOR RULE

Avoiding congestion through dynamic load control

Reading. 14. Subdivision curves. Recommended:

Lecture 5: Multilayer Perceptrons

A SYSTOLIC APPROACH TO LOOP PARTITIONING AND MAPPING INTO FIXED SIZE DISTRIBUTED MEMORY ARCHITECTURES

Virtual Machine Migration based on Trust Measurement of Computer Node

Analysis on the Workspace of Six-degrees-of-freedom Industrial Robot Based on AutoCAD

Tsinghua University at TAC 2009: Summarizing Multi-documents by Information Distance

the nber of vertces n the graph. spannng tree T beng part of a par of maxmally dstant trees s called extremal. Extremal trees are useful n the mxed an

CSE 326: Data Structures Quicksort Comparison Sorting Bound

Intra-Parametric Analysis of a Fuzzy MOLP

Data Representation in Digital Design, a Single Conversion Equation and a Formal Languages Approach

UC Berkeley Working Papers

An Application of the Dulmage-Mendelsohn Decomposition to Sparse Null Space Bases of Full Row Rank Matrices

Sorting Review. Sorting. Comparison Sorting. CSE 680 Prof. Roger Crawfis. Assumptions

Sum of Linear and Fractional Multiobjective Programming Problem under Fuzzy Rules Constraints

Report on On-line Graph Coloring

Dynamic Voltage Scaling of Supply and Body Bias Exploiting Software Runtime Distribution

The Research of Ellipse Parameter Fitting Algorithm of Ultrasonic Imaging Logging in the Casing Hole

CMPS 10 Introduction to Computer Science Lecture Notes

AADL : about scheduling analysis

Machine Learning: Algorithms and Applications

Transcription:

Introducton Towards Optmal I/O Schedulng for MEMS-based Storage Halng Yu, Dvyakant Agrawal, and Amr El Abbad Department of Computer Scence Unversty of Calforna, Santa Barbara {halng,agrawal,amr}@csucsbedu Magnetc dsks have been the domnant on-lne storage technology for more than three decades Dsks have mantaned ths domnance n spte of other competng storage technologes such as bubble memory, holographc stores, and mproved DRAMs Although magnetc dsks have enjoyed ths poston n the persstent storage arena, more recently the memory herarchy has suffered from problems of latency, bandwdth, and cost gap In partcular, due to the advances n processor technology and semconductor manufacturng, the processor-to-dsk performance gap has been consstently growng Fortunately, the processor-to-memory performance gap n the memory herarchy has been partally mtgated by the ntegraton of very fast caches In spte of these efforts, the RAM-to-DISK gap has remaned unflled Currently ths gap has wdened to sx-orders of magntude and future trends ndcate that unless a breakthrough occurs n the dsk technology, ths gap wll contnue to wden by about 50% annually The RAM-to-Dsk performance gap arses due to the physcal characterstcs of dsk drves Although the dsk capacty growth has been phenomenal about 60% per year), the mechancal postonng system n the dsks lmts the access tmes mprovements to only about 7% per year Mcro-ElectroMechancal Systems MEMS) [,] based storage systems are beng developed as an alternatve to conventonal rotatonal dsks for the non-volatle storage of large amounts of data MEMS are extremely small mechancal structures formed by the ntegraton of mechancal elements, actuators, electroncs and sensors These are fabrcated on slcon chps usng photolthographc processes smlar to those employed n manufacturng standard semconductor devces As a result, MEMS devces can be produced and manufactured at a very low cost MEMS based systems can be used n a varety of applcatons due to ther mproved cost, sze, capacty and power consumpton Specfcally, MEMS based systems can be used n moble applcaton platforms such as PDA's, laptops and bo-medcal montorng systems Unlke tradtonal dsks, MEMS based storage devces [] do not make use of rotatng platters due to the dffculty n manufacturng effcent and relable rotatng parts n slcon The emergng paradgm for such systems s that of a large scale MEMS array whch, lke dsk drves, has read/wrte heads and a recordng meda surface The read/wrte heads are probe tps mounted on mcro-cantlevers embedded n a semconductor wafer and arranged n a rectangular fashon The recordng meda s another rectangular slcon wafer called the meda sled) that can use conventonal technques for recordng data In general power consumpton of MEMS devces s consderably lower than the conventonal dsks whch means that when these devces are ntegrated as part of a system, desgners do not need to worry about costly dle tme predcton algorthms to conserve power Prelmnary studes have also shown that stand-alone MEMS based storage devces reduce I/O stall tmes by 4 to 74 tmes over dsks and mproves the overall applcaton run tmes by 9X to 44X [8] When used as on-board caches for dsks, MEMS based storage mproves I/O response tme by up to 35X MEMS-based storage has qute dfferent characterstcs from dsk In partcular, they are two dmensonal whle dsks have been approached always as one dmensonal storage devces by dvdng them nto cylnders, sectors and tracks Even though exstng technques developed for dsks, such as dsk schedulng algorthms and data placement scheme, can be adapted to MEMS-based storage devces, some characterstcs of MEMS-based storage devces have not been consdered adequately In ths paper, we frst show that optmal schedulng for MEMS-based storage s NP-complete and then propose off-lne and on-lne schedulng algorthms that explot the two dmensonal characterstcs of these devces We then show that these algorthms are guaranteed to perform wthn twce the optmal performance tme The remander of the paper s organzed as follows Secton presents the MEMS-based storage model and a bref revew of exstng schedulng algorthms In Secton 3, we show that optmal MEMS-based

storage schedulng s NP-complete and explot some propertes of mnmum spannng trees n the nfnty dstance space In Secton 4, off-lne algorthm and on-lne algorthm are developed In Secton 5, we analyze the proposed algorthms by developng an upper bound on ther performance and provdng some prelmnary experment results Secton 6 concludes the paper Background In ths secton, the archtecture of MEMS-based storage devces s frst descrbed Our development s based on the CMU CHIP project [9] and the IBM Mllpede project [7] Then we revew some exstng schedulng algorthms for ths new storage devce Fgure : A desgn of MEMS-based storage devces Fgure : The meda sled s dvded nto rectangular regons Archtecture for MEMS-based storage A MEMS-based storage devce s composed of recordng meda heads and a recordng meda surface The recordng heads, usually called tps, are embedded n a semconductor wafer arranged n a rectangular fashon The recordng meda s another rectangular slcon wafer referred to as the meda sled There are dfferent approaches for recordng data For example, IBM s Mllpede [7] uses pts n the polymers made by tp heatng, CMU CHIPS [] adopts the same technques as data recordng on dsks In ths system, because t s very hard to rotate the unt on a mcroscopc scale, the meda sled s suspended by sprngs above the wafer wth probe tps Data s accessed by movng the meda sled n X or Y drectons over the statonary probe tps The movement n the Z drecton s used to actuate the dstance between the probe tps and the meda sled Ths desgn s shown n the Fgure It s derved from the CMU desgn [8]) The X and Y actuators provde the force for movng the meda sled n the X and Y drectons whle the sprng supples the restorng moton These two actuators work ndependently The meda sled s dvded nto rectangular regons as shown n Fgure Each of these rectangular regons contans an array of M N bts and s servced by one probe tp The relaton between the regons and tps s a one-to-one mappng, e, the number of regons s the same as the number of probe tps In theory, all the probe tps can be actvated smultaneously For the CMU CHIP devce, the system has 6400 tps, arranged n an array of 80 x 80 tps per rectangular regon wth each regon havng 500 x 500 M x N) bts Due to power and heat constrants, only 80 tps can be actvated smultaneously Based on the above desgn consderatons, some basc observatons and assumpton can be made: ) Because the relaton between the probe tps and regons s a one-to-one mappng, t can be assumed that the max dstance the meda sled can move n the X Y) drecton s the edge length of regons n the X Y) drecton ) The nfnty dstance L between two ponts, x, y ) and x, y ), s the larger value of x x and y y Because the movement n the X and Y drectons are ndependent, the dstance between two ponts n one regon s L

3) The tme T for the sled to move from one pont to another s an ncreasng functon of the dstance n the x and y drectons Based on observaton ), tme T s the larger of these two values tme spent on the X called T ) and Y called T ) drecton movement) For example, x gven ponts v and w, the tme spent s Tv, w), where T v, w) s a functon of the between v and w Note that the tme s symmetrc, e Tv, w) = Tw, v) Exstng schedulng algorthms for MEMS-based storage y L dstance Many dfferent schedulng algorthms have been developed for conventonal dsks[6], such as FCFS frst-come frst-servce), CLOOK cyclcal look), SSTF shortest seek tme frst), SSTF_LBN shortest seek tme based on the Logcal Block Number of the request), and SPTF shortest poston tme frst) The CMU group has adapted many of these dsk schedulng algorthms n the context of MEMS-based storage by mappng these storage devces nto a dsk-lke nterface [] The CMU expermental results show that SPTF performs best n terms of average response tme 3 Theoretcal Development Ths secton descrbes the motvaton to desgn a new schedulng algorthm for MEMS devces that s not adapted from dsk-lke devces We frst argue that fndng an optmal schedulng algorthm for MEMSbased storage s NP-complete Then we develop some propertes of mnmum spannng trees n the nfnty dstance doman As descrbed earler, the schedulng performance n MEMS-based storage devces s a functon of the nfnty dstance Our schedulng algorthms are based on a mnmum spannng tree n ths doman 3 Motvaton MEMS-based storage characterstcs are dfferent from dsks Instead of plates rotatng wth a head movng back and forth, n MEM-based storage, the meda sled can move n the X, Y and Z dmenson The seek tme s dependent on the dsplacement n the X and Y dmenson Gven these dfferent parameters, MEMS-based storage devces requre dfferent request schedulng algorthms to ft n ths envronment However fndng the optmal soluton s NP-complete In MEMS-based storage devces, for smplcty, a request can be denoted by vector x, y), where x, y determne the poston of the request n the actve tp regon Because the tp s number s not related to the seek tme, and schedulng algorthms fnd the shortest seek tme to serve all requests, we can smply gnore the actve tp s number Requests for a MEMS-based storage can be vewed as ponts dstrbuted n one rectangular area whch s the same as one regon When the devce serves requests, the meda sled moves to the request s poston determned by the x and y, and the correspondng tps are actvated, then the devce accesses reads or wrtes) data by the actvated tps The tme spent movng the meda sled from ts current poston to the next poston s called seek tme T, whch s determned by the L dstance between these two postons After mappng requests nto x, y) locatons n a two-dmensonal surface, a graph can be constructed Requests can be denoted as vertces, edges are the tme spent travelng from one vertex to another The goal s to fnd a shortest path that vsts each vertex exactly once n the graph It s a Symmetrc Travelng Salesman Problem, so fndng the optmal path s NP-complete [3] The symmetry arses from the fact that the travelng tme from vertex v to vertex w s the same as the tme travelng from w to v In the exstng dsk-based algorthms, SPTF performs best [] However, t s easy to show that t does not perform well n all settngs For example, consder the case where all requests have dfferent x values, but the same y value, as shown n Fgure 3 Assume request R3 s the current request beng served, because R s nearer to R3 than R4, then R s the next request to be served Applyng the same reasonng, the order of requests to be served s R3 R R4 R R5 The problem s that ths algorthm s greedy, and fnds the next request to serve based on the shortest seek tme and does not consder the whole dstrbuton of requests In ths example, f all requests are consdered, the mnmal order n terms of seek tme would be R3 R R R4 R5 3

MST Even though t s not practcal to desgn an optmal algorthm, we develop an algorthm wth guaranteed upper bound for any workload We frst ntroduce some basc concepts A spannng tree of a graph s a cycle-free sub-graph that spans all the vertces The cost of a spannng tree s the sum of the costs of edges n t A mnmum spannng tree MST) s the smallest cost spannng tree of a graph, the cost for MST s referred to as T A double walk of a spannng tree means traversng all the vertces n preorder, hence the cost of a double walk s equal to two tmes the cost of ths spannng tree, as shown n Fgure 4 The double walk s composed of all the arrow lnes R R R3 R4 R5 Fgure 3: A settng that SPTF does not perform well Fgure 4: The double walk of a MST We propose a new schedulng algorthm based on servng requests n the order of the double walk of a mnmum spannng tree Because ths algorthm s constructed on the mnmum spannng tree MST), before ntroducng the algorthms, we frst present some propertes of mnmum spannng trees n the nfnty dstance space 3 Propertes of mnmum spannng trees n nfnty dstance space We start by defnng regon to regon4 wth respect to a vertex n the nfnty dstance space Then we establsh that the degree of any vertex n a MST s at most eght and can be reduced to four It s nterestng to note that n the Eucldan dstance space, the bound on the degree s sx and can be reduced to fve [5] In the followng sectons, wthout any specfcaton, everythng s n nfnty dstance space Consder a vertex s v wth coordnates x, y), we defne the followng four regons wth respect to v x, y) as follows: regon s the subspace wth any vertex, ) satsfyng, y regon s the subspace wth any vertex x, ) y satsfyng x x, y > y regon3 s the subspace wth any vertex x, 3) satsfyng x x y y 3 y 3 <, 3 4 x, y4 regon4 s the subspace wth any vertex x, ) 4 y4 satsfyng x < y All regons mentoned n the followng refer to regon to regon4 We now establsh several lemmas based on these regons Lemma 0: In any regon of a vertex, there are at most two neghbors n the mnmum spannng tree Proof: We frst prove that a vertex v x, y) n any regon could have two neghbors Then we prove that n each regon, t s mpossble for vertex v to have more than two neghbors Consder some regon, say regon, and two neghbors v x, y ) and v x, ) y A smlar argument holds for any of the four regons) There are four cases to consder dependng on how v and v relate to a 45 lne passng through v Case : Both v and v are on the 45 lne, as shown n Fgure 5 We have x = y and x = y Wthout loss of generalty, assume x < x Then dv, v)<dv, v); dv, v)<dv, v) Edge v, v) has to be replaced by v, v) n the mnmum spannng tree, so two neghbors of vertex v cannot be on the 45 lne at the same tme 4

45 v 45 v 45 v v v v v v v Fgure 5 Fgure 5 Fgure 53 Case : Both v and v are ether to the left or to the rght of the 45 lne Wthout loss of generalty, we analyze the case where v and v are on the rght sde of the 45 lne, as shown n Fgure 5 In ths case, y y, y y, x > y, x > y Thus dv, v) = x x ; dv, v) = x x Assume that x < x < x the other case s symmetrc) Snce dv, v) = max x x, y y ), there are four cases to consder If dv, v)= y y, snce y y, then y y y y However, snce dv, v) = x x, t mples that y y < x x Thus dv, v) < dv, v) If dv, v)= y y, then snce y y, we have y y y y However, snce dv, v) = x x, t mples that y y < x x Furthermore we know that x x < x x, snce dv, v)<dv, v) Hence dv, v) < dv, v) If dv, v) = x x, then snce x < x, we get x x < x x = dv, v) Hence dv, v) < dv, v) If dv, v)= x x, t s mpossble snce x < x Thus swappng edge v, v) wth v, v) wll reduce the cost of the spannng tree, e, both v and v connect to v, the spannng tree s not a MST Case 3: v and v are on dfferent sdes of the 45 lne, as shown n Fgure 53 In ths case, we have x > y, x < y, x < x, x < x, y y, y < y Thus dv, v) = x x ; dv, v) = y y If dv, v)= y y, because y y, then dv, v)= y y y y =dv, v) The equalty holds when y = y So n ths condton, both v and v can connect to v n a MST If dv, v)= y y, because y y, then dv, v)= y y y y < x x =dv, v) If dv, v)= x x, because x < x, then dv, v)= x x < x x < y y =dv, v) If dv, v)= x x, because x < x, then dv, v)= x x < x x =dv, v) So n ths case, v and v can connect to vertex v when y = y and dv, v)= y y Case 4: One of vertex v s neghbors s on the 45 lne If one of them s on the 45 lne and the other s on the rght sde of the 45 lne We have x < x, > y, x = y, x < x, x y y, y < y Based on a proof smlar to Case 3, we can show that v and v can connect to v f dv, v) = dv, v) If one of them s on the 45 lne and the other s on the left sde of the 45 lne We have x x, = y, x < y, x < x, x < y < y, y < y Thus dv, v) = y y ; dv, v) = y y = x x If dv, v)= y y, because y < y, then dv, v)= y y < y y =dv, v) If dv, v)= y y, because y < y, then dv, v)= y y < y y =dv, v) If dv, v)= x x, because x < x, then dv, v)= x x < x x =dv, v) If dv, v)= x x, because x < x, then dv, v)= x x < x x < y y =dv, v) So v and v cannot connect to v n a MST n ths case 5

We can conclude that vertex v n regon can have two neghbors v x, ) and v x ) y, where v s y on the X axs, v s on the 45 lne or on ts left sde, and dv, v) = dv, v) Wthout loss of generalty, assume neghbor v3x3, y3) s the furthest vertex among v, v, v3 to vertex v n regon Based on the proof above, we have two cases Case : If vertex v s on the X axs and v s on the left sde of the 45 lne It s mpossble for vertex v3 to be on any sde of the 45 lne, the same reason as Case If vertex v3 s on the 45 lne, v and v3 cannot both connect to v based on Case 4 So t s mpossble to add more neghbors Case : If one of v s on the X axs and v s on 45 lne If v3 s on the rght sde, t s the same stuaton as Case; f v3 s on the 45 lne, Case can be appled; f v3 s on the left sde of the 45 lne, Case 4 can be appled So under any condton, t s mpossble for vertex v to have more than two neghbors n regon Lemma 0 proves that n a mnmum spannng tree, any vertex n any regon can have at most two neghbors We can easly derve Lemma whch state that the degree of any vertex s at most eght Lemma : The degree of any vertex n the MST s at most eght We now establsh a stronger result, namely that n the L model and a set of vertces, there exsts some MST where the degree of every vertex s at most four Lemma : There exsts some MST, n whch the degree of any vertex s at most four Proof: We clam that any MST wth some vertces of degree larger than four can be transformed to a MST where no vertex has degree larger than four From Lemma 0, we know that n any of the four regons, at most two vertces may connect to a vertex n a MST Wthout loss of generalty, for a vertex v x, y), ts two neghbors n regon are v x, y ) and v x, ) y From the proof of Lemma0, n all the possble postons of v and v, dv, v) = dv, v) By swappng edgev, v) wth edgev, v) would not ncrease the cost of MST, but the degree of vertex v s reduced to one n regon The smlar arguments can be acheved n regon to regon4 By repeatng ths procedure n each vertex wth more than four neghbors, we obtan a MST n whch the degree of any vertex s at most four We now explore ways to reduce the cost of traversng a MST Lemma 3: When traversng the MST, the cost of movng from one vertex to ts sblng drectly s no larger than the cost of passng through ther parent vertex Proof: Because L satsfes the trangle nequalty, vertex v, ts sblngs s and ther parent p form a trangle, then the cost of movng from vertex v to s drectly s no larger than the cost of movng from v to s by vstng p Lemma 3 can be generalzed as follows The edge cost from one vertex to another vertex s less than or equal to the cost of the path between these two vertces n the MST In the followng secton, we develop schedulng algorthms based on these propertes of MST n the nfnty dstance space 4 Schedulng Algorthms Our algorthm s based on buldng a mnmum spannng tree of all requests and servng the requests n the tree order An undrected graph called cost graph) needs to be constructed n order to buld a mnmum spannng tree In the cost graph, requests are treated as vertces, the edge cost from one request to another request R s the seek tme T For MEMS-based storage, the followng nformaton s R j, j known: Requests and ther postons x, y), 6

The equaton to compute the seek tme between two requests R x, y ) and R x, y ) : T = f max x x, y y )), whch s the dstance between the two requests j j L j j j Snce n a MEMS-based storage devce, t s possble to traverse from a request x y ) to any other request x, y ), the number of edges n the cost graph wll be n n ) /, where n s the number of j j vertces It s very neffcent to construct a MST based on a graph wth n n ) / edges, because the tme complexty of constructng MST s dependent on the number of edges and vertces Both Prm s and Kruskal s algorthms for constructng MST have tme complexty O m log n ), where m s the number of edges However, the number of edges n the cost graph can be reduced to at most 8n From Lemma, the degree of each vertex n a MST could have one nearest neghbor n each regon If these four nearest neghbors for each vertex are n a cost graph G, the MST can be bult based on graph G Thus the cost graph only needs to nclude all edges that are formed by connectng each vertex to ts nearest neghbors n each regon 4 The cost graph Based on Lemma, to buld the cost graph for a gven set of requests, we need to fnd at most four connectng vertces of every vertex whch are dstrbuted n regon to regon4 respectvely We now descrbe the method for fndng the four connectng vertces for a gven vertex R x, y ) Assume they are n vertces or requests): R x, y ), R x y ), R x, y ),, R x, y ), 3 3 3 n n n Two vectors are constructed: X-VECTOR and Y-VECTOR X-VECTOR contans the X dmenson values n ncreasng order Y-VECTOR contans the Y dmenson values n ncreasng order Wth respect to R x, y ), the nfnty dstance space s dvded nto regon to regon4 From another pont of vew, X-VECTOR s dvded nto two sub-vectors, X+ and X-, by x, Y-VECTOR s dvded nto two sub-vectors, Y+ and Y-, by y The next task s to fnd the vertex nearest to R x, y ) n each regon We descrbe the procedure for fndng the nearest vertex n the regon, whch s equvalent to searchng the X+ and Y+ sets Assume the vertex nearest to R x, y ) s R x, y ) j j j, Step : There are two ponters, X_Ponter and Y_Ponter, pontng to the current postons of X+ and Y+ Intally, they pont to the frst element n the X+ and Y+ x s the value of the element ponted to by X_Ponter; y s the value of the element ponted to by Y_Ponter Step : If R x, y ) s a vertex par n R x, y ), R x y ), R x, y ),, R x, y ), then t s the vertex we are searchng for Connect x y ) wth R x, y) R, 3 3 3 n n n, Step 3: If x x y y, move Y_Ponter to the next element n Y+, y = the value of element ponted by Y_Ponter, goto Step Step 4: Else x x < y y, move X_Ponter to the next element n X+, x = the value of element ponted by X_Ponter, gotostep The procedure for fndng the nearest vertces n the regon to regon4 s smlar The cost graph s bult by repeatng ths procedure for all vertces Snce each vertex has four neghbors, n the cost graph, each vertex has between 4 and 8 neghbors The resultng cost graph has all the necessary edges to buld an MST, j 7

4 Off-lne schedulng Algorthm Based on the theoretcal development descrbed above, we now present a schedulng algorthm for the case when all the requests are known a pror In the off-lne algorthm, the cost graph s bult by the method mentoned above, and the MST s bult by Prm s Algorthm The requests are served n a preorder traversal of the MST The algorthm s composed of one man subroutne called Man Method and a functon subroutne called Fnd_next Man Method: Gven n requests: R x, y), R x, y ),, R x, y ),, Rn xn, yn ); Buld the cost graph G for the n vertces or requests); 3 Based on G, buld the Mnmum spannng tree MST for the n requests; 4 number_request_left = n; 5 next_request = root n the MST; Servenext_request); 6 Whle next_request!= null ) do 7 number_request_left = number_request_left ; 8 current_poston = x, y), where x, y are dsplacement of next_request; 9 next_request = fnd_next next_request ); Servenext_request); 0 END Fnd_next current_request ) If number_request_left = 0, return null; If current_request has no chldren then save_parent = parent of current_request; Remove current_request from MST, and 3 return fnd_nextsave_parent); 4 else choose mnmum cost chld of current_request, label t served, 5 return the mnmum cost chld 6 END The varable number_request_left s used to record the number of requests that have yet not been served The subroutne fnd_next current_request) s used to fnd next request to serve It also fnds and returns the next request to serve The man dea of fndng the next request s prmarly based on the tree preorder traversal Even though as the algorthm s fndng the next request, t traverses the tree, but the real dstance moved s the dstance between the current_request and the next_request based on Lemma 3 Ths algorthm starts from the root After t s served, fnd one of ts nearest chldren as the next request and label t as SERVED Otherwse recursvely call fnd_nextparent of current_poston) untl fnd the next_request The overall cost of ths algorthm s domnated by buldng the cost graph, whch s O n ) Because the cost of constructng a mnmum spannng tree s O m log n ) and m s at most 8n, the cost s reduced to O n log n ) 43 On-lne schedulng Algorthm In ths secton, the algorthm for the on-lne schedulng s presented where requests are contnually arrvng as pror requests are beng served The algorthm s dfferent from the off-lne one When new requests arrve durng the servce of exstng requests, the MST has to be updated to nclude the new requests Current dynamc MST algorthms [4] only consder changes n the cost of edges and not the ncluson of new vertces Our on-lne algorthm s composed of two parts One serves exstng requests n the current MST, the other updates the current MST wth new ncomng requests The frst part s the same as the off-lne algorthm, so we prmarly focus on descrbng the algorthm for updatng the current MST In the algorthm for updatng the MST, accordng to the Lemma, the four nearest vertces n the dfferent regons, f they exst, are found The new vertex s connected to the MST by the smallest cost edge to one of these four vertces The remanng three edges are checked to see f the MST cost can be reduced 8

Update the MST wth the new comng request R x, y ) new new new Insert x nto the X-VECTOR, y nto Y-VECTOR; new new Search the requests whch are nearest to the new request n regon to regon4 wth respect to The procedure s the same as computng each vertex s neghbors n buldng up the R new cost graph At most four requests exst, say R, R, R R Connect R to the nearest vertex n, R, R R So that R s ncluded n the MST R 3, 4 new 3, 3 After step, there are at most three edges left, f they are all larger than the max cost edge n the MST, DONE 4 for any edge e of the three edges left wth cost less than the max cost edge n the MST do 5 Insert e nto the MST, t results n a cycle, remove the maxmum cost edge from the cycle 6 end Based on the Lemma, every vertex n MST connects to at most four other vertces, these four vertces are located n the regon,, 3, 4 respectvely Step and bascally locate these four vertces f they exst Because these four vertces are the nearest vertces to vertex v, connect v to the MST by the nearest neghbor n these four neghbors The followng steps are used for updatng the current MST, because nsertng new vertces may reduce the total cost of the MST Step 3 s an optmzaton If the remanng three edges are larger than the maxmum cost edge n the MST, none of them wll be n the MST Step 4 and 5 update the MST There must be a cycle c f an edge s added, accordng to the tree property of MST, remove the largest edge n ths cycle The cost of updatng the MST s domnated by fndng cycles and fndng four nearest vertces, both of them are O n), so the total cost of ths algorthm s O n) 5 Analyss Our approach s based on the propertes of MST In Secton 5, we show that n any workload, our approach can satsfy an upper bound A prelmnary performance s studed n Secton 5 5 Upper bound Wthout the optmzatons made by Lemma 3 & 4, our approach corresponds to a double walk of a mnmum spannng tree The cost of a double walk s equal to two tmes the cost of ths spannng tree, as shown n Fgure 4 The double walk s composed of all the arrow lnes If the spannng tree s a MST, the cost of a doublng walk s equal to *T T s the cost of the MST) The optmal algorthm tres to fnd a path wth the mnmum cost Actually the path s a spannng tree too So the cost of the optmal path T s no less than T If we serve the requests by the route of a double walk, the followng opt MST results can be obtaned T = *,T seek T MST MST T opt Hence T *, where T s the total seek tme for servng all requests seek T opt seek MST MST Our approach made some optmzatons based on Lemma & 3 So we have the followng equaton: T < * seek T opt Hence, our approach s guaranteed has an upper bound of *T rrespectve of the workload opt 5 Prelmnary performance We set up the experments by smulatng 00 00 regon wth unformly dstrbuted workloads We mplemented four schedulng algorthms: FCFS, SSTF, SPTF and Tree-based off-lne algorthm Because the seek tme s a functon of seek dstance, we gve smulaton results based on the average seek dstance nstead of average seek tme The smulaton results are shown n Fgure 6 9 4 new

The data shows that SPTF and Tree-based approaches always perform better than SSTF and FCFS SSTF s better than FCFS As the number of requests ncreases, the average seek dstance of FCFS and SSTF s almost a constant, so these two algorthms are not scalable However the average seek dstance of SPTF and Tree-based approach decrease When the workload s not heavy, the Tree-based approach acheves better average seek dstance than SPTF Under heavy workload, ther performance s comparable 50 40 Average seek dstance 30 0 0 0 SPTF SSTF FCFS Tree-Based 0 0 40 60 80 00 0 The number of requests 6 Concluson Fgure 6: Average seek dstance In ths paper, based on the characterstcs of MEMS-based storage devces, we developed two dmensonal schedulng algorthms whch guarantee the upper bound T OPT on seek tme The cost of servng a request s O n) The cost of updatng the MST s also O n) Based on the algorthm desgned by Chrstofdes [0], we could acheve an upper bound of 5T, but the cost for the onlne case would be more expensve Our future research wll explore tradeoffs among these dfferent approaches References: [] Grffn, J, Schlosser, S, Ganger, G, Nagle, D, Operatng Systems Management of MEMS-based Storage Devces In OSDI 000, October 3-5, 000 [] L Rchard Carley, Gregory R Ganger, and Davd F Nagle, MEMS-Based Integrated-Crcut Mass-Storage Systems n COMMUNICATIONS OF THE ACM November 000, Vol43, No [3] M Andrews, M A Bender, and L Zhang New algorthms for the dsk schedulng problem In Proc 37th IEEE Sympos Found Comp Sc, pp 580 589, Oct 996 [4] Davd Eppsten Offlne algorthms for dynamc mnmum spannng tree problems Journal of Algorthms, 7):37-50, September 994 [5] C Monma and S Sur, "Transtons n Geometrc Mnmum Spannng Trees," Dscrete & Computatonal Geometry, Vol 8, No 3, pp 65--93, 99 [6] Seltzer, M, Chen, P and Ousterhout, J Dsk Schedulng Revsted In Proceedngs USENIX of the Wnter 999 Conference [7] PVettger, MDespont, UDrechsler, UDurg, WHaberle, MI Lutwyche, HERothuzen, RStutz, RWdmer, and GKBnng The Mllpede - More than one thousand tps for future AFM storage IBM Journal of Research and Development, 443):33-340, May 000 [8] Schlosser, S, Grffn, J, Nagle, D, Ganger, G Desgnng Computer Systems wth MEMS-based Storage In ASPLOS 000, November 3-5, 000 [9] CMU CHIP project: http://wwwececmuedu/research/chps [0] N Chrstofdes Worst-case analyss of a new heurstc for the travelng salesman problem Report 388, Grad School of ndustral Admnstraton, CMU, 976 OPT 0