System Programming UNIX : Chores using Threads

In UNIX system programming


1. To make a simple program by adding threads as a means for cooperation among Mom and the kids.

2. To use shared memory with appropriate synchronization and locking.

* (Attached file can be used to add and extend the threads in UNIX program instructions)

General Instructions about this Coding Program

Implement shared memory that contains the task list, the clock, and a child-counter, initialized to 0.

Create and initialize a mutual-exclusion lock, to be used to protect the shared memory.

The original process, Mom, should initialize the shared memory and create four threads for

the four children.

When each child starts up, it will copy the current value of the child-counter from shared

memory into its own memory and use that as its ID#.

Post-increment the child-counter when copying it.

Use the ID# and a switch in the child-code to select and call one of the four job-preference

functions. That function should look at the jobs in the task array, choose one, then do it.

Continue the loop (select, sleep, add points to local total, post results) until the clock reaches


Then send Mom the points you earned.

Either Mom or each kid should print out the earnings. Mom should print the winner.

Of course, Mom must not terminate until all four kids have nished.

Please submit everything in one zipped file Include source code and output that shows you are

able to complete one work day. Run this program several times and submit all the results, including the list of jobs done by the children, their nalscores, and the winner.

Taidot: C-ohjelmointi, C# -ohjelmointi, C++ -ohjelmointi, tietojenkäsittely, UNIX

Näytä lisää: programming chores, program using threads unix, unix programming, up programming, unix jobs, switch c programming, source code programming, sleep programming, programming process, programming loop, programming kids, programming jobs jobs, programming instructions, programming functions, programming function, programming for kids, programming for children, programming array, print out source, post programming jobs, own programming, out source programming, out source jobs, out source coding, original programming

Tietoa työnantajasta:
( 0 arvostelua ) Dubai, United States

Projektin tunnus: #1705485

Myönnetty käyttäjälle:


Hi sir. I am a qualified programmer. I can do this task. Kindly check pmb. Thank you

$45 USD 1 päivässä
(21 Arvostelua)

5 freelanceria on tarjonnut keskimäärin %project_bid_stats_avg_sub_26% %project_currencyDetails_sign_sub_27% tähän työhön


Hello, Sir. I am Linux expert. I have rich experience in Linux and pthread. Regards.

$60 USD 2 päivässä
(9 arvostelua)

I have good experience in C, Linux and pthreads.

$60 USD 2 päivässä
(2 arvostelua)

Interesting program! Regards!

$60 USD 1 päivässä
(3 arvostelua)

Hello! I have experience in multithreading jobs, as you can see in my freelancer profile. I'm looking forward to work for you.

$55 USD 1 päivässä
(2 arvostelua)

Custom Software Development - <b><i>Removed by Admin</i></b>

$60 USD 1 päivässä
(0 arvostelua)