preview

Difference Between Multiprogramming And Multiprocessing

Satisfactory Essays

1. Problem 1 (20 points): Why is the execution environment of a Java class called a virtual machine? How does this virtual machine compare to a real machine running code written in C? Answer: Java files are executed on Java Virtual Machine which is not a real machine. This is a software application which acts like a real machine and make a complete environment like heap, memory, stack, CPU etc virtually. Basically it is layer of software between the OS and the application program. That's why it is called a Virtual Machine. Virtual Machine will see the resources which administrator sets in settings e.g. if we set 1 GB for virtual machine, code will use only this memory even if real machine have more free memory. When code runs in virtual …show more content…

5. Problem 5. (20 points) What is the difference between multiprogramming and multiprocessing? Multiprogramming and multithreading? Answer: Difference between multiprogramming and multiprocessing: Multiprogramming is the ability of an operating system to run multiple processes on a single processor machine. E.g. we are running MS Word, notepad and media player on a single CPU machine and all the running simultaneously. Multiprocessing is the ability of operating system to run multiple processes on multiple processors (CPUs). Processes are divided and assigned to different CPUs to perform the task. So basic difference is that if OS run multiple processes on single processor, this is multiprogramming and if multiple processes are running on multiple CPUs is called multiprocessing. Difference between multiprogramming and multithreading: Multiprogramming is the ability of an operating system to run multiple processes on a single processor machine. E.g. we are running MS Word, notepad and media player on a single CPU machine and all the running simultaneously. Multithreading is the ability of operating system to run divide and run different parts of a process on a single CPU to obtain the same but fast result. Different parts of the code which run simultaneously are called

Get Access