Provide a make file so we can run on energon

Assignment Help Programming Languages
Reference no: EM131299352

Programming Assignment Lab: IO Scheduling

You are to implement different IO-schedulers in C or C++ and submit the source code, which we will compile and run. Please provide a Make file so we can run on energon (and please at least test there as well).

In this lab you will implement/simulate the scheduling of IO operations. Applications submit their IO requests to the IO subsystem, where they are maintained in an IO-queue. The IO-scheduler then selects a request from the IO-queue and submits it to the disk. On completion another request can be taken from the IO-queue and submitted to the disk. The scheduling policies will allow for some optimization as to reduce disk head movement or overall wait time in the system. The schedulers to be implemented are FIFO (i), SSTF (j), SCAN (s), CSCAN (c), and FSCAN (f) (the letters in bracket define which parameter must be given in the -s program flag).

Note: when we say [C|F|]SCAN we actually mean the LOOK variant algorithm version which does not scan the entire width of the of the disk. This is the common usage in the industry of the term SCAN. Also remember that when switching queues in FSCAN you always scan up first from the current position, then down until queue empty.

Invocation is a follows:

./iosched -s<schedalgo> <inputfile>

The input file is structured as follows: Lines starting with '#' are comment lines and should be ignored.

Any other line describes an IO operation where the 1st integer is the time step at which the IO operation is issued and the 2nd integer is the track that is accesses. Since IO operation latencies are largely dictated by seek delay (i.e. moving the head to the correct track), we ignore rotational and transfer delays for simplicity. Move by one track takes one time unit.

We assume that moving the head by one track will cost one time unit. As a result your simulation can/should be done using integers. The disk can only consume/process one IO request at a time. Everything else must be maintained in an IO queue and managed according to the scheduling policy. The initial direction of the SCAN algorithms is from 0-tracks to higher tracks. The head is initially positioned at track=0 at time=0. Note maxtrack is not an issue here (think why).

You can make the following assumptions:

- at most 1000 io operations will be tested, so it's OK to first read all requests from the file before processing.

You don't have to use discrete event simulation. You can write a loop that increments simulation time by one and check whether any action is to be taken, i.e. whether an I/O completed or whether and I/O arrived and whether the track has to be moved by one (i.e. there is an active I/O ongoing).

Attachment:- Lab Assignment.rar

Reference no: EM131299352

Questions Cloud

Liquidity trap and insensitive investment function : The Keynesian Transmission mechanism will eliminate a recessionary gap if there are not Liquidity Trap or Insensitive Investment function. Explain: a) What it is a liquidity trap
Count the number of coins in the bag and record the value : Count the number of coins in the bag and record the value as P in Table II. (Note: an example of how Table II is supposed to look like has been provided to you at the bottom of the document.
Decide whether you should rely on the data : The database might be complete and accurate, or it might not be. To what extent should you rely on these data? What can you do to decide whether you should rely on the data at this site.
What is the rate of returns at each of the stores : Rates versus counts. Customers returned 36 coats to Sears this holiday season, and only 12 to La Boutique Classique next door. Sears sold 1200 coats this season, while La Boutique sold 200.
Provide a make file so we can run on energon : You are to implement different IO-schedulers in C or C++ and submit the source code, which we will compile and run. Please provide a Make file so we can run on energon (and please at least test there as well)
Create the business plan to make business more profitable : Create the Business Plan to make the business more profitable.- The Business Plan is about "Air conditioning and heating".
Are these ratings biased or unreliable : The most popular restaurant. Each year the Zagat Survey lists the most popular restaurants in Los Angeles. In 2005, A.O.C. was ranked 5th but in 2004 it was ranked 31st. The Cheesecake Factory was ranked 7th in 2005 but was 2nd in 2004. Are these ..
Write a program which uses structure having indicated member : Write a program which uses a structure having the indicated member names to store the following data: The program will keep a list of three test scores for one student.
Describe a measurement process that you think is valid : Measuring physical fitness. You want to measure the "physical fitness" of college students. Give an example of a clearly invalid way to measure fitness. Then briefly describe a measurement process that you think is valid.

Reviews

len1299352

12/3/2016 2:44:44 AM

You are to implement different IO-schedulers in C or C++ and submit the source code, which we will compile and run. Please provide a Makefile so we can run on energon (and please at least test there as well). In this lab you will implement/simulate the scheduling of IO operations. Applications submit their IO requests to the IO subsystem, where they are maintained in an IO-queue. The IO-scheduler then selects a request from the IO-queue and submits it to the disk. On completion another request can be taken from the IO-queue and submitted to the disk. The scheduling policies will allow for some optimization as to reduce disk head movement or overall wait time in the system. The schedulers to be implemented are FIFO (i), SSTF (j), SCAN (s), CSCAN (c), and FSCAN (f) (the letters in bracket define which parameter must be given in the –s program flag).

Write a Review

Programming Languages Questions & Answers

  Write a haskell program to calculates a balanced partition

Write a program in Haskell which calculates a balanced partition of N items where each item has a value between 0 and K such that the difference b/w the sum of the values of first partition,

  Create function m-file called mass that requires two vector

Create a function M-file called mass that requires two vector inputs-the number of moles and the molecular weight-and returns the corresponding mass. Because you are providing vector input, it will be necessary to use the meshgrid functio..

  How to use bit vector to represent dynamic set of distinct

Explain how to use a bit vector to represent a Dynamic Set of Distinct Elements with no Satellite Data. Dictionary Operations must Run in O (1) Time.

  Write non-recursive function-compute n-th fibonacci number

Fibonnacci series 0,1,1,2,3,5,8,13,21,... starts with terms 0 and 1 and has property that each succeeding terms is sum of the two preceding terms. Write the non-recursive function which computes the n'th Fibonacci number.

  What programming language is the csci project written in

The CSCI and CINS students enrolled in the senior capstone project course (CSCI/CINS 490) will be presenting posters of projects each student has been working on this semester. You are to learn about three of these projects and do a writeup of ea..

  Create a procedure to populate an array

In many programs you will want to store a number of values, where each of those values is a record - how to declare and work with arrays of records - calculate the total of all of the expenses of a certain kind.

  Use a switch statement to calculate a letter grade

Use a switch statement to calculate a letter grade based on a numeric average up to 100. Allow the numeric score to be entered in a text field. A Grade button will display the corresponding letter grade in a label.

  Write a trigger for total percentage of all appointments

Write a trigger on Works department to ensure the following requirement; the total percentage of all appointments for an employee must be fewer than 100%.

  Print the minimum cost of conversion for each string

Print the minimum cost of conversion for each string to a Super Ascii string - Your task is to convert the string to super ascii with the minimum cost. While converting the string to super ascii, the final string should contain the same characters ..

  Write loop which processes pay for all workers in array

Print program titles and report headings, then call input function described next to fill in data array. Write loop which processes pay for all workers in array.

  Write a code to swap the letter passed through an array

Write a code to swap the letter passed through an array called letters. With int number of letters. Use must use pointers and pointer arithmetic.

  Program to compute percentage and final grade for students

Write a program which will permit teacher to compute percentage and final grade for students in a class.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd