I started this week on Sunday as usual with the self-quiz; which gave me an indicator of the content of the week. The week was complementary about Concurrency, where we learned more about the techniques that are used to safely run threads concurrently.
The text mentioned the importance of locking critical sections while some other thread is working on it; we dive more into locks and signals (condition variables).
While I thought that the OS can automatically detect critical sections and apply the necessary locking mechanism; it was a surprise for me that I have to do that manually.
The discussion forum asked me to review an article from the suggested websites; however, none of them has worked for me and some just have irrelevant results.
The written assignment asked to run some Linux commands and report the output, like the top, kill, ps, pstree commands.
Operating systems are hardware dependent but only to some extent. While the OS is working closely with the CPU and, memory, interrupt hardware, timers, and other devices; the OS must be always compatible with all of these devices for the entire computer to be useful.
The OS must be compatible with the hardware type and not the individual commercial hardware since all manufacturers -usually- provide a standard interface for their hardware.
For example, if the OS supports concurrency; the hardware must support the same type of concurrency through a standard interface; which means that the OS does not care about the details of how the hardware does things as long as it behaves the same on the point of connection with the OS.
The OS sends system calls that are translated to ordered moves on the registers of the CPU; if these registers were named, wired, or layout-ed differently than the OS expects, these calls are going to fail.
An example would be that Windows OS works on hardware manufactured by almost any company in the world, but it won’t be compatible with Apple machines since the chips (CPUs) are constructed differently.
I have the latest Mac with an M1 chip (CPU) which made it incompatible with older Operating Systems prior to MacOS 11.0.1; which is the first version that supports the M1 chip. I could not run the virtual machine on my Mac because the virtual machine software was not compatible with the M1 chip. Luckily, I have access to a cloud Linux machine that I can run to follow the course and be able to successfully complete the assignments.
Arpaci-Dusseau, R. H., & Arpaci-Dusseau, A. C. (2018). Operating systems: three easy pieces (1.01 ed.). Arpaci-Dusseau Books. https://pages.cs.wisc.edu/~remzi/OSTEP/