Link:
https://study.com/academy/lesson/operating-systems…
About this Assignment
In this project, you will use what you have studied in the chapter Memory Management & Operating Systems to emulate how operating systems manage memory paging, allocation, deallocation and replacement. Upon completion of this project you will be able to:Describe how operating systems manage memoryUse simple codes to emulate basic functionalities of operating systems
Prompt
1) Show the memory state for the different scenarios in the tables below and analyze which choice is the best. Discuss the impact that Linux versus Windows might have on the ending memory state.
2) With that information in mind, run the following list of jobs:
- An interval is the number of seconds
- Total Memory size = 20 Kbyte
- Page size = 1 KbyteJob IDStart TimeJob required sizeExecution intervalJob state at the end of the interval1127End2238Sleep3346End4436Sleep5529Sleep6636Sleep7726Sleep3) Run three different scenarios in order to manage memory allocationRun the program for the following scenarios:Best-FitFirst-FitWorst-FitEach should be run for the following jobs: Job IDStart TimeJob required sizeExecution intervalJob state at the end of the interval8834Sleep9955Sleep101028Sleep111146End121265Sleep21336End41334Sleep131353End71323End91744Sleep1019211End61936End520210Sleep421312Sleep1222613End82239End928511End53323Sleep434310End538210EndPrompt TipsHere are a couple tips for getting started with the assignment:You’ll want to write a program that will simulate the process an operating system follows when cycling jobs to make sure they are all completed quickly. C++ is a language that works well, but you can choose the language you prefer.Copy the data in the two tables from the prompt into a text file that you can use as input for a program.Write a program using Java, C++, Python, or the programming language of your choice that can take the input from your text file.In the same program, write a function that will queue up each job along with its start time, job size, execution interval, and state at the end of each interval.Continue building on this program so that you can execute each of these jobs according to their individual interval.Have this program return the state of each job at the end of each interval.Run the program until all jobs are complete.You will need to use what you learned about allocation, deallocation, and replacement to build this program, and you’ll need to consider the total memory size and page size defined in the prompt. When asked to consider different scenarios, it means to consider running these jobs using the best-fit allocation scheme, the first-fit scheme, or others, and then determine which would be best.Grading RubricYour project will be graded based on the following rubric:CategoryUnacceptable (0-1)Needs Improvement (2-3)Good (4)Excellent (5)Total Possible PointsEfficiency of solutions (x2)Solutions require long unnecessary waiting times for the processes and not using the complete memory spaceSolutions either require long unnecessary waiting times for the processes or not using the complete memory spaceSolutions are making acceptable use of memory on both temporal and spatial levelsSolutions lead to an optimal temporal and spatial use of memory10Analysis (x2)Not able to explain choices or resultsBasic understanding of memory management but needs to be improved on the analysis levelAdequate explanation and analysis for memory state scenario choiceClear explanation and clarification of the choices for scenarios and results10Trying different scenarios (x1)No Scenarios testedOnly one scenario is testedTests of only 2 different scenariosTests of 3 different scenarios5Use of functions for each memory management task (x1)No use of any of the three function types (allocation, deallocation and replacement)Use of only one of the three function types (allocation, deallocation and replacement)Use of only two of the three function types (allocation, deallocation and replacement)Use of all function types for allocation, deallocation and replacement5Correct matching between the chosen scenario and functions (x1)Chosen methods do not match the planned scenarioSome of the chosen methods match the planned scenarioMajority of the chosen methods match the planned scenarioAll chosen methods match the planned scenario5Completeness and correctness of the test case (x1)Less than half the timing and memory spatial constraints of the assignment (task starting times, sizes and intervals) where implementedMore than half the timing and memory spatial constraints of the assignment (task starting times, sizes and intervals) where followedMost of the timing and memory spatial constraints of the assignment (task starting times, sizes and intervals) where followedAll the timing and memory spatial constraints of the assignment (task starting times, sizes and intervals) where fully followedIn terms of what to submit, you should submit the code for your program or take a screenshot of it. You should also show the state of each interval after it’s run. Once all the jobs are finished, you should determine which scenario was most ideal and write an explanation as to why it was the best scenario.
In terms of what to submit, you should submit the code for your program or take a screenshot of it. You should also show the state of each interval after it’s run. Once all the jobs are finished, you should determine which scenario was most ideal and write an explanation as to why it was the best scenario.