Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
27 views3 pages

05 Laboratory Exercise 1

Download as docx, pdf, or txt
Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1/ 3

Santos, Matthew Emmuel D.

1. If you are to add a new 10MB process in the memory, where could it possibly be added and
why?
- The memory block's 8MB free processes could merge with the newly created 10MB
process. This is due to the fact that this memory block is the only one big enough to hold
the new process.

2. What could be the size of the free block just before it was partitioned by X?
- The file might have been between 12 and 14 MB in size. This is the result of the 10MB
process being added to the block, which caused the block to be divided to accommodate
the new process.

3. Would you suggest the provisioning of virtual memory in this configuration? Why or why
not?
- In my opinion, optimizing block utilization and minimizing fragmentation would improve
system performance.

4. Is it possible to add a new 7MB process using the first-fit placement algorithm without
swapping out any process? Why or why not?
- No, because the process cannot handle the 10MB block that is the only one available.

5. A new process is requesting a 3MB allocation. Illustrate the possible memory configuration
using a horizontal segmented memory strip (like the diagram above), where a partition will be
created for the new process under the following placement algorithms: best-fit and first-fit.
Label your illustration clearly.

Best-fit placement

4MB 1MB 3MB 8MB 2MB 4MB

First-fit placement

4MB 1MB 4MB 8MB 2MB 3MB


1. Explain the operation and management of the following virtual memory. Search for
relevant studies and literature that would support your answer. Properly cite your
references.
- Linux Virtual Memory

Linux virtual memory increases the amount of memory that is available by extending
RAM in a circle. In order to free up RAM for other purposes, the bit will write the
contents of an unused memory square to the hard drive. The original content is re-
added to memory whenever it becomes necessary. The user is not aware of this at
all; Linux-based apps only perceive the greater amount of RAM that is available; they
are not aware that portions of RAM are periodically stored on the plate. The area of
the hard drive used as virtual memory is called the trade space. Linux can use a
regular disk file or a dedicated area as swap space.

- Windows Virtual Memory

Generally speaking, Windows virtual memory is straightforward but mostly


superfluous. Windows will dynamically modify virtual memory according to your
installed RAM and system requirements. Windows computers have straightforward
memory management that is occasionally unnecessary. By default, depending on
your settings and the amount of RAM installed, Windows may dynamically change
memory. With the help of your RAM, it attempts to adapt to what it thinks you'll need
and will change as your usage increases.

2. Then, answer the following items based on your research.

a. Between the operation and management of Linux and Windows virtual memory,
which do you think is less complex and why?

- While Linux is used more by advanced users and is known as the hacker operating
system, Windows is more popular among novices and casual computer users. Each
of the operating systems has benefits and drawbacks. Because the page
replacement mechanism is a crucial part of any memory management system, I
believe that Windows virtual memory is less complicated than other memory
management systems. Page replacement chooses which memory pages to page out
when a page of memory needs to be allocated. The concept of a working set, which
is determined by the amount of memory allotted to the active process, is used by the
Windows paging system. It consists of pages from main memory, and the working
set's size is changed appropriately.
b. Were you able to find similarities between Linux and Windows virtual memory?

- A good substitute for commercial software like Windows is open source software like
Linux. Unlike Windows, Linux is an operating system that is easy to use and can
alter code to suit its requirements, while Windows cannot. Access to the source code
is a prerequisite for making changes to a Linux kernel's code. Source code access is
possible on both Windows and Linux systems.

c. What are the possible drawbacks of not implementing virtual memory?

- Without virtual memory, there's a chance that the computer's memory will fill up
rapidly due to a shortage of usable memory space. Moreover, once the RAM is full,
the software cannot be downloaded. The system may use virtual memory, which
could degrade the performance of applications. In virtual memory, mapping between
virtual and physical pages requires indirection. Every memory access is handled by
the paging unit. These days, any memory access across a table is regarded as a real
overhead.

d. If you are to design a memory management system, would you incorporate virtual
memory into your design? Why or why not?

- Everything depends on the goal of the system. Virtual memory, however, is


incredibly helpful in general computing. It allows programs to request more memory
than the computer can physically handle. It also offers mechanisms to load
executables and shared libraries only when needed, preventing your 5 GB Chrome
executable from loading into memory all at once. Because unnecessary portions of
code and data are not stored in memory, it frequently results in a reduction in the
overall amount of memory used.

You might also like