Posts

Showing posts from July, 2025

5th week CST 334

     This week's material is mostly about concurrency, most notably threads and locks. Most of the material is new to me except the race condition since I am studying cybersecurity. In threads it is like a process except multiple of them can be stored inside of a process sharing the virtual address space which makes the process be able to perform multiple execution in the program. However, each thread has its own stack and registers and one of its downsides is that if one thread blocks then the entire process blocks. The two main reasons the thread is beneficial are parallelization which speeds up the process that turns single threaded program into a program that performs the tasks like it has multiple CPUs. The other reson is to avoid program progress from getting blocked which is caused by slow I/O. The main idea behind lock or also known as mutex (mutual exclusion) is to prevent race condition where 2 or more threads from reading or writing shared data in the shard re...

4th week CST 334

 This week's material is about paging where it is an alternative to the base and bound in the segmentation. The advantages is that it is simple, flexible and unlike base and bound it avoids fragmenting the process to fit into the memory of the RAM. Some of the down sides to paging is that the translation is not simple and its info will not fit into the MMU (Memory Management Unit) registers. It does not work well in address translation since it requires the addressing to be fast but paging is too slow for it. This is where TLB (Translation Lookaside Buffers)comes in where it is able to store the recent translations of virtual memory addresses to the physical memory addresses. The TLB can be found in the MMU where it is implemented as an associative cache.       When the cache memory has no room for the paging to operate or need to update the information, the swapping policy is utilized or also known as cache replacement policy. The four swapping policies are FIF...

3rd week CST 334

  This week's material is slightly biased towards Address Spaces. I understood the three goals of Address spaces which are Transparency, Efficiency, and Protection and the problems with it and the solution to it currently which is virtual memory. In the second lecture there is dynamically allocated memory which provides memory to some process and when that process is completed, the memory is released. In some languages like Java, memory deallocation is automatically performed by a facility known as garbage collection. In c, memory must be manually deallocated by the programmer using the free( ) facility. Address translation is the foundation of virtual memory systems that convert virtual addresses pr...

2nd week CST 334

This week's material really caught my attention – it was completely new territory for me, but I found myself genuinely engaged with the concepts. The idea of multiprogramming was particularly eye-opening. I hadn't realized before that you could have multiple programs sitting in memory simultaneously, with the CPU cleverly jumping between them to stay busy. It's like having several books open on your desk and reading whichever one keeps you most productive at any given moment. The fork() system call in Unix was another fascinating discovery. I was amazed to learn how it essentially clones a process, creating a parent-child relationship where both continue running their own lives independently. It reminded me of how a cell divides – you start with one, and suddenly you have two that share the same DNA but can develop differently. The fact that they maintain so many shared characteristics while still being able to evolve separately felt almost elegant. The process tree concept...

1st week CST 334

     I am familiar with some of the subjects that are taught in this week's materials. Some of them are Linux and its command line since I used it recently to run tools like Nmap. Most of the materials in Math Addendum and computer architecture were more of a review with the only part new to me was the stack part. I did have some troubles on the Math Addendum part but it was brief and managed to get over the problems. The one part that stood out to me when learning more about C programming was that other well known languages like Go, Java, and Swift were even related to C.