CSCE 5640, Fall 2016

Project #1

Due: 11-9-2016

For this project you may be working in groups of two. Each member of your group must sign up on the corresponding project sheet in order to receive a grade. Your task is to implement a semaphore-based solution to the problem stated below.

Consider a system with N blocks of storage, each of which holds one unit of information (e.g. an integer, character, or employee record). Initially, these blocks are empty and are linked onto a list called freelist. Three threads communicate using shared memory in the following manner:

Shared Variables: freelist, list-1, list-2: block (where block is some data type to hold items)


var b: pointer to type block;

while (1)


b:= unlink(freelist);


link(b, list1);



var x,y: pointer to type block;

while (1)




use_block_x_to_produce info_in_y(x, y);

link(x, freelist);

link(y, list-2);



var c: pointer to type block;





link(c, freelist);


Using the POSIX library, rewrite the code for the threads, using semaphores to implement the necessary mutual exclusion and synchronization. The solution must be deadlock-free and concurrency should not be unnecessarily restricted.

Aptitudini: Programare C

Vezi mai multe: semaphores shared memory, semaphores shared memory mini project, client server semaphores shared memory, com ipc shared memory server, shared memory works xen, communication via shared memory xen, shared memory communication channel, shared memory xen, xen shared memory, sqllite shared memory, shared memory life cycle, sqlite shared memory, shared memory sqlite, visual studio 2005 shared memory wrapper, sqlite shared memory database

Despre angajator:
( 12 recenzii ) hyderabad, United States

ID Proiect: #12010191

Acordat lui:


Hi I am an Computer Engineering Student at Wayne State University. I am an expert on C/C++. SO I can do your project. Please message me with further details. Kind regards.

%selectedBids___i_sum_sub_4%%project_currencyDetails_sign_sub_5% USD în 1 zi
(6 Recenzii)

2 freelanceri licitează în medie 38$ pentru acest proiect


Hello, I'm interested by your project but could you please give more details? Some words about me, I'm an Electronic & Computer Science Engineer who has graduated in 2003. Since I've graduated, I worked for Aerospa Mai multe

%bids___i_sum_sub_35%%project_currencyDetails_sign_sub_36% USD în 5 zile
(12 recenzii)