
Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!

Problem 1 : (25 points) Show how you would rewrite sdelete() so that it would refuse to delete a busy semaphore (e.g. a semaphore that has processes currently waiting on it). What would happen to a process waiting on a semaphore that got deleted while it was waiting?
Problem 2 : (25 points) XINU applies the first-fit method from one end of the free list. Show what changes you would make to getmem() to even out the allocation of memory across the free memory area by beginning the current search where the last allocation left off. This is similar to how process id’s are allocated beginning from the last process id assigned.