CST334 OS Week 2
A lot of topics covered were covered this week.
- fork() for spawning a new child process from a parent process
- additional functions exec(), wait() to manage the situation after forking
- mechanisms, traps, system calls, user mode and kernel mode
- policies and scheduling processes
- fifo, sjf, stcf, round robin
- multi-level feedback queues
- making sure processes aren't abandoned due to being de-prioritized into oblivion
The fork() concept was interesting to learn about. The C syntax is so plain but so much is happening when using fork(). How fork() related to the behavior of a shell or command line was very fun to learn about; I'm sure there is a lot more going on there and I'd like to take a deeper dive.
I'll admit that after reading about traps - I thought back and barely recalled what I had just read. Even now as I'm writing about it I'm unsure of it. There is a trap table, and this table will be used to call specific types of traps, which will in tern jump to certain parts of kernel code. A trap handler will take the system-call from the user-mode program and relate it to a specific trap type. Due to security, a user-mode process cannot tell the system where to jump to due to security risks.
Scheduling and mapping out round-robin was challenging; I ran through the lab practice quiz several times. I was turned around trying to deal with my errors until I started working with sub-time units (fractions). The supplemental office hours recording helped with this but I had not watched it right off the bat. Looking up about this topic was not helpful because other material included the quantum as having a non-zero value, and so the mapping was not the same as this course.
This week's programming assignment was a horrible experience. The starter code was so hard to understand and almost completely opaque despite the readme provided. I think it was because it is so ... C. Not just "pointers are hard" but pointers to functions, function declarations inside a struct / typedef? Just taking the helper functions in scheduler_support.h was not nearly as intuitive as the previous assignment. When looking to slack and my original group's discussion, I was expecting to hear more concern for lack of understanding, and was surprised that there was none. Perhaps everyone else is more familiar with C and C-style programming structure than I am. I don't feel that this assignment furthered my learning about this weeks topics while at the same time also not furthering my understanding of C.
On the flip side, I enjoyed the policy schedule mapping. Because I took the quiz several times, I did a lot of them and feel that those exercises very much DID further my understanding of scheduling.
Comments
Post a Comment