Find Jobs
Hire Freelancers

Simulation Of Deadlock Detection

$30-250 USD

Closed
Posted over 6 years ago

$30-250 USD

Paid on delivery
For this assignment, you will write a program that simulates the execution of multiple processes with respect to their resource allocation and resource release requests, and detect when (or if) deadlock occurs. If deadlock occurs, your program will then display a list of the processes and resources involved in the deadlock. Write and test a program (in C, C++, Java, or Python) to carry out the simulation of multiple processes executing the sequences of resource requests and computation specified by the input data, checking after each resource allocation request for the existence of deadlock by attempting to find a cycle in the resource graph. If no deadlocks occur during execution, then for each process indicate the total run time and the time when the process completed. If a deadlock does occur, indicate that fact, the time when the deadlock was detected, and the identification of the processes and resources involved in the circular wait. The samples shown below illustrate the desired output format. No extraneous output (e.g. debugging information) should appear in your output, and tracing information should not appear in the output from your solution. The program must read from the standard input and write to the standard output. Let’s look at a complete example. Suppose we have three processes with execution action sequences as follows: Process 1: L1 L2 C2 U1 U2 Process 2: L1 L2 C2 U1 U2 Process 3: L3 C5 U3 C2 Simulation 2 in the sample input and output (below) shows the sequence in which these process actions would occur, and the time (starting at 0) when they would occur. The set of processes in simulation 2 does not deadlock, but obviously other sequences can (see the samples for several such sequences). To detect deadlock, your program must build a resource graph (with nodes for processes and resources, and directed edges indicating resource ownership and pending resource requests), and test the graph for the existence of a cycle after each resource allocation request is made by a process. This test must be performed after each successful or unsuccessful allocation. The Input Data The input data will consist of a sequence of simulation test cases identified by sequential numbers starting with 1. The first line of input for each test case will contain two integers that specify the number of processes (1 ≤ np ≤ 50) and the number of resources (1 ≤ nr ≤ 50). The remaining np lines in the test case specify the actions for each of the np processes, with line i + 1 of the test case input containing the action specifications for process i. Each action specification line contains an integer na (1 ≤ na ≤ 50) that specifies the number of actions for the process and then na action specifications, each consisting of an action type (L, U, or C) followed immediately by an integer. The last test case will be followed by a line containing two integer zeroes. Sample input and output appears below, and illustrates the input format. There is code in C that is 75% code done. Just need to complete the rest. If you are okay with the project, I could send you the code. Or if you don't want to use this code, you could go from scratch.
Project ID: 15687795

About the project

12 proposals
Remote project
Active 6 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
12 freelancers are bidding on average $143 USD for this job
User Avatar
Hello, I'm Smile Song, developer in China. I'm interesting your project very well I'm a Good SQL, C++, c#, Python, .Net, swift, object-c, OpenCV, Math, Java, Algorithm expert. Relevant Skills and Experience I m quite well experienced in these jobs. Let's go ahead with me I want to service for you continously. Proposed Milestones $144 USD - initial milestone
$144 USD in 3 days
4.9 (982 reviews)
9.2
9.2
User Avatar
I am very proficient in c and c++. I have 16 years c++ developing experience now, and have worked for more than 6 years. My work is online game developing, and mainly focus on client side, using c++ under windows environment. I used c++ to make many great projects, for example, I made the tools which can convert java files into c++ scripts, of course garbage collection included, this job is very similar to a compiler, and is very complex. I also made our own mobile game using c++, I can show you the demo of client, if you like. I am very proficient in java also. I have a very good review on Freelancer.com, I never miss a project once I accept the job, you can check my review. Trust me, please let expert help you.
$150 USD in 3 days
4.9 (198 reviews)
7.2
7.2
User Avatar
tough stuff. can do this for you. Relevant Skills and Experience - python - multithreading Proposed Milestones $90 USD - simmulation 1 completed $60 USD - simmulation 2 completed
$150 USD in 2 days
5.0 (81 reviews)
6.4
6.4
User Avatar
Hello We are highly motivated young technocrats from India. We are approachable, you can come to us if you have a struggle, we are happy to help. Team TiponTongue Relevant Skills and Experience Ph.D. in Computer Science and Engineering Proposed Milestones $220 USD - Milestone
$220 USD in 3 days
4.9 (40 reviews)
5.4
5.4
User Avatar
Hi, Please award me for this assignment, I will do by Java. regards, Relevant Skills and Experience Java Proposed Milestones $111 USD - Completed
$111 USD in 3 days
5.0 (15 reviews)
4.5
4.5
User Avatar
I would like to offer myself as a probable candidate for this assignment as I am confident of delivering a quality output. I have excellent expertise in this area. Relevant Skills and Experience I have total 7 years or experience in web development and design using java,multi-threading,algorithm,Simulation,Deadlock,j2ee. already done some assignments like this Proposed Milestones $155 USD - java
$155 USD in 3 days
4.8 (24 reviews)
4.3
4.3
User Avatar
A proposal has not yet been provided
$155 USD in 3 days
5.0 (13 reviews)
4.1
4.1
User Avatar
Experience C/C++ developer in Silicon Valley. Able to write simple code that does the task and easy to understand. Relevant Skills and Experience C/C++, Java using Eclipse IDE, Python. Debugging skills and also translating big problems into simple and easy to understand solutions. Proposed Milestones $20 USD - Understanding the problem in detail and pseudo coding $90 USD - Completion to your satisfaction Additional Services Offered $200 USD - Any other support after project completion Will get the job done in a timely and accurate manner. Just pick me, you will not be disappointed.
$110 USD in 3 days
4.8 (2 reviews)
1.3
1.3
User Avatar
Hey ! I'm SAYAN PROGRAMMER I've reviewed your complete job description, and I fulfill all the qualifications required for this project. I have completed 200 projects with clients 100% satisfaction and I am sure if you will respond me then I will be able to explain my skills as well. I have more than 15 years of experience in this field. I always try to provide good quality work to my clients. My key skills are: C #, C + +, C programming ,JAVA, Software Development, Software Architecture, PHP, Java script and much more. Looking forward to work with you on this project. THANKS Regards SAYAN PROGRAMMER
$100 USD in 3 days
0.0 (0 reviews)
0.0
0.0

About the client

Flag of UNITED STATES
United States
0.0
0
Member since Nov 20, 2017

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.