It's UWAweek 9 (1st semester, week 1)


This forum is provided to promote discussion amongst students enrolled in CITS2002 Systems Programming.
Please consider offering answers and suggestions to help other students! And if you fix a problem by following a suggestion here, it would be great if other interested students could see a short "Great, fixed it!"  followup message.
Displaying selected article
Showing 1 of 1168 articles.
Currently 1 other person reading this forum.

 UWA week 37 (2nd semester, week 7) ↓
SVG not supported

Login to reply

3:39am Thu 14th Sep, Christopher M.

> 1. I know we are allowed to print debugging statements, as long as the last line is the measurements line, however, I am a bit worried my program will be overwhelmed (like the sample solution) with large time periods (for example, the 1-second wait in the shortsleep command). In that case should I remove all my debug print statements, or will the time periods not be that extreme?
I'm not sure what you mean by 'my program will be overwhelmed'. All output will be ignored except the last line, so it doesn't matter how much there is.
> 2. I also just wanted to clarify whether the correct order, when the CPU is idle, is to unblock (for example) a single finished sleeping process and then continue, or to unblock all finished sleeping processes and then continue? The clarifications say 'unblock any sleeping processes', while the sample solution simply unblocks one sleeping process and then continues - I'm guessing the sample solution is the correct way?
When the CPU is idle, at time T, is awakens *all* sleeping processes that should wake up at time T (or before); they are appended to the READY queue. That is what the sample does.

The University of Western Australia

Computer Science and Software Engineering

CRICOS Code: 00126G
Written by [email protected]
Powered by history
Feedback always welcome - it makes our software better!
Last modified  5:07AM Sep 06 2023
Privacy policy