Find Jobs
Hire Freelancers

process scheduler simulator in c++ using threads

$30-100 USD

処理中
投稿日: 21年近く前

$30-100 USD

完了時にお支払い
You will implement a framework for job scheduling in a multiprocessor environment. You will examine three non-preemptive scheduling algorithms: First-Come-First-Served (FCFS), Priority and Shortest Job First (SJF). assume that all jobs arrive to a central scheduler and are placed into a central priority queue that contains the jobs in the order that they should be scheduled. When a multiprocessor finishes its current job, it schedules the next job by removing it from the centralized queue. Your assignment is to implement each of the three scheduling algorithms mentioned above for a multiprocessor system. Your implementation will simulate the execution of jobs. To do this, you will implement a dedicated thread for the central scheduler and a thread for each multiprocessor in the [login to view URL] multiprocessor thread removes a job from the centralized queue and “processes?? the job according to its time [login to view URL] the job has “finished?? execution, the multiprocessor thread removes the job from the system and handles another job. Call your file [login to view URL] The input command line format should be as follows (where sched is the name your executable): sched [-v] -[FCFS|P|SJF] ??"n[num_processors] Where the command-line flag FCFS is first-come-first-served, P is priority and SJF is shortest job first. The -v option indicates a verbose output mode. The ??"n option indicates how many processors are in the system. is the name of the input file whose format is as follows. Input Format: The first line of the file contains N, the number of total jobs in the system. All additional lines in the file (no more than 100) must contain the description of one job per line where each line has the following fields (all fields are integers, separated by the tab character) in the following order: id,arrival time,comptime,priority In the default mode (i.e., without the -v flag), the output consists of (1) the completion time of each job, and (2) the CPU utilization of each processor. In verbose mode, in addition to the above information, your program should display the complete job state transition information as in the following example (assume FCFS scheduling). At time 0 job 0 is scheduled on multiprocessor 0. At time 10 job 0 exits the system. functions: add_queue(job_node, sched) remove_queue() get_number_jobs() get_jobs() schedule_jobs() better description to follow ## Deliverables 1) Complete and fully-functional working program(s) in executable form as well as complete source code of all work done. 1. A README file with a brief description of your program and your synchronization strategy. In addition, the first line of the README should indicate the number of SLIP days used for this project and the number of SLIP days that you have used overall. 2. A Makefile that allows us to compile the code by typing "make all". Your Makefile should compile programs using g++ or gcc with the -Wall flag ("warn all") included. Programs should compile without error or warning with the -Wall flag. 3. Executables sched and [login to view URL] and any additional files that you use. 4. A short report (maximum of 5 pages) that consists of the following parts: a. Describe your testing/validation strategy. Your testing strategy should be designed to check that the simulator is producing the correct results. At a minimum, you are required to describe a simple set of input parameters and your hand-computed set of expected results, and to verify that your simulator is in fact working correctly. Additional systematic testing (as suggested above) is strongly recommended. b. Run the same input on all three schedulers using 1 processor, 2 processors, and 4 processors, respectively. Describe how processor utilizations and job waiting times are affected for each scheduler on the various number of processors. How do different arrival times affect multiprocessor utilization and job waiting times for each scheduler? c. Experiment with your scheduling system under the following conditions. Suppose you have 4 processors. Processor 0 executes a 4 time unit job in 1 time unit. Processor 1 executes a 4 time unit job in 2 time units. Processors 2 and 3 both execute a 4 time unit job in 4 time units. What is the effect of the varied computational requirements on the different schedulers? How do these different system requirements change multiprocessor utilization and job waiting times? Explicitly state any assumptions that you must make. 3) Complete ownership and distribution copyrights to all work purchased. ## Platform needs to compile on a G++ compiler in a Unix enviorment.
プロジェクト ID: 2952084

プロジェクトについて

2個の提案
リモートプロジェクト
アクティブ 21年前

お金を稼ぎたいですか?

Freelancerで入札する利点

予算と期間を設定してください
仕事で報酬を得る
提案をご説明ください
登録して仕事に入札するのは無料です
アワード者:
ユーザーアバター
See private message.
$68 USD 2日以内
4.9 (33 レビュー)
4.6
4.6
この仕事に2人のフリーランサーが、平均$70 USDで入札しています
ユーザーアバター
See private message.
$72.25 USD 2日以内
0.0 (0 レビュー)
0.0
0.0

クライアントについて

UNITED STATESのフラグ
United States
5.0
2
メンバー登録日:7月 11, 2003

クライアント確認

ありがとうございます!無料クレジットを受け取るリンクをメールしました。
メールを送信中に問題が発生しました。もう一度お試しください。
登録ユーザー 投稿された仕事の合計
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
プレビューを読み込み中
位置情報へのアクセスが許可されました。
あなたのログインセッションの有効期限がきれ、ログアウトされました。もう一度ログインしてください。