Operating systems concepts, Operating System

Assignment Help:

The code should be nicely formatted with plenty of comments. It should be easy to read, properly

The summary section should include three parts:

(1) Record the running time in Table 1

(2) Discuss your result in Table 1 (1-2 pages), and cite 1-2 references to support your discussion

(3) What was learned by doing this project

Your results must be presented clearly and be reproducible.

Table 1
File 1 File 2 File 3

1 Process

2 Processes

4 Processes

II. Project Description

Problem Overview

You must use fork and pipe to complete this project.

This project creates processes to add all numbers in a file. The user will enter a number (1, 2, or 4) of parallel processes to create for processing the numbers. The system will then create this many processes, evenly dividing the file contents between the processes. For example, if the file has 1000 numbers and the user wants 4 processes, then each process would process 250 numbers in the file.

III. System Description

The system is illustrated in the diagram shown below. The processes are as follows:

1. Parent process. This process allows user to input the number of processes to create (1, 2, or 4). It determines what portion of the file each process must work on and informs the process via a pipe. It then waits for each child to report its result. Once each result is received, it combines the results prints the overall result.

2. Child process. Receive which part of the file to process. Process the file and send results back to the parent process.


Related Discussions:- Operating systems concepts

Explain the facilities of a debug monitor, Facilities of a Debug Monitor ...

Facilities of a Debug Monitor Facilities of a debug monitor are like this: Setting breakpoints in the program Initiating a debug conversation while control reaches

What is a process control block?, What is a Process Control Block? Ever...

What is a Process Control Block? Every process in the operating system is represented by a process control block as well called a task control block. It contains several pieces

Steps to run a program on a completely dedicated machine, Q. List the four ...

Q. List the four steps that are essential to run a program on a completely dedicated machine. Answer: a) Reserve machine time b) Manually load program into memory c)

Diehard allocator - custom allocators, Allocators can also be used to avoid...

Allocators can also be used to avoid problems with unsafe languages. C and C++ are pervasive, with huge amounts of existing code. They are also memory-unsafe languages, in that the

What is scheduler, What is scheduler? A process migrates among the vari...

What is scheduler? A process migrates among the various scheduling queues throughout its life time. The OS must choose processes from these queues in some fashion. This selecti

What are the system components of an operating system, What are the system ...

What are the system components of an operating system and explain them? a) Process management b) Main-memory management c) I/O management d) File management e) Seco

Structures for a file''s data, Q. Likewise some systems support many types ...

Q. Likewise some systems support many types of structures for a file's data while others simply support a stream of bytes. What are the merits in addition to demerits? Answer:

Management Information Systems, Select any business process within this fir...

Select any business process within this firm, describe it as a set of steps then fill the following table (flow, information, sender and receivern #Minimum 100 words accepted#

Execution without entering a deadlock state, Q. Presume that a system is in...

Q. Presume that a system is in an unsafe state. Illustrate that it is possible for the processes to complete their execution without entering a deadlock state. Answer: An unsaf

Capability lists are typically kept within the address space, Q. Capabilit...

Q. Capability lists are typically kept within the address space of the user. How does the system make sure that the user cannot modify the contents of the list? Answer: An ap

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd