Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Consider the C program in UNIX/LINUX environment provided below Consider that the system calls do not fail, function Fn() never returns, function Fn() does not

image text in transcribed

Consider the C program in UNIX/LINUX environment provided below Consider that the system calls do not fail, function Fn() never returns, function Fn() does not execute system calls. Each new process inherits exactly the way signals are handled by the parent process, and finally system calls can be interrupted by incoming signals. Since Fn) never returns, the processes created in this program come to a permanent state: the process tree remains stable forever and each process executes a specific function or system call. Answer briefly the following questions: a) Draw the process tree in its final form, i.e., when all processes have reached a steady state. Explain your solution IN DETAIL b) At each tree node please highlight: i) the system call or function in which the Program Counter (PC) of the corresponding process is at, (ii) the arguments with which the process has been called, ii) the line of the program from which the call took place. For the arguments, make any assumptions you need for the numbers you do not know about, eg, PIDs assigned to the new processes by the system. c) Complete the process tree to show the inter-process communication: for each data transfer or signal transfer that has occurred, draw a dotted arrow from the sender process to recipient process. On the arrow type the value that is transferred every time. 1 void handler (int signum) 3 gn(, -3) 6 int main(void) 8 int i, p[2]. writefd[4] 9 pid t pid[4]: 1e 11 signal (SIGUSR1, handler) 12 13 for ( -

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design Application Development And Administration

Authors: Michael V. Mannino

3rd Edition

0071107010, 978-0071107013

More Books

Students also viewed these Databases questions

Question

Evaluate the differences between money and capital markets.

Answered: 1 week ago