Posts

Showing posts from July, 2025

Computer Science BS Journal (CST334) : Week 5

    This week in CST334 our lectures covered: Concurrency and Threads, Threads API, Locks, and Lock-based data structure. In this learning journal I'll write and explanation/what I think to be the most important bits of each subject. We also had our midterm this week and I didn't do as good as I wanted to, I definitely need to focus some more on my studies. Concurrency and Threads Concurrency is the ability of a system to handle multiple tasks at the same time. Threads are the smallest units of execution within a process. Concurrency allows threads to run independently, improving efficiency, especially on multi-core processors. Key Takeaways: Concurrency enables better CPU utilization. Threads share the same memory space within a process. Context switching allows threads to appear to run in parallel. Can lead to race conditions if not properly synchronized. Threads API Threads APIs provide the functions and mechanisms to create, manage, and synchronize threads....

Computer Science BS Journal (CST334) : Week 4

   This week in CST334 our lectures covered: Paging, Translation Lookaside Buffers, Multi-Level Paging, and Swapping. In this learning journal I'll write and explanation/what I think to be the most important bits of each subject. Paging Paging is a memory management scheme that eliminates the need for contiguous memory allocation. It divides physical memory into fixed-size blocks called frames and logical memory (processes) into blocks of the same size called pages . Key Takeaways : Avoids external fragmentation. Simplifies memory allocation. Requires a page table to map virtual pages to physical frames. Introduces a level of indirection, so address translation is needed. Translation Lookaside Buffers (TLBs) A TLB is a small, fast, cache used to store recent translations of virtual addresses to physical addresses. Since page table lookups can be slow, the TLB helps speed up the translation process. Key Takeaways : TLB reduces memory access time by caching...

Computer Science BS Journal (CST334) : Week 3

  This week in CST334 our lectures covered: Address Spaces, C Memory API, Address Translation & Base-and-bounds, Segmentation, Free Space Management. We also started working on our first group project this week. In this learning journal I'll write and explanation/what I think to be the most important bits of each subject. 1. Address Spaces An address space is the range of memory addresses that a process can use. Each process has its own virtual address space, isolated from others, managed by the operating system. Key Takeaways: Provides process isolation . Helps with security and stability . Enables virtual memory and memory protection. 2. C Memory API The C memory API includes functions for dynamic memory allocation and deallocation: malloc() , calloc() , realloc() , and free() . Key Takeaways: malloc(size) allocates a block of memory. calloc(n, size) allocates and zero-initializes memory. realloc(ptr, new_size) resizes previously allocated memory. ...

Computer Science BS Journal (CST334) : Week 2

    This week in CST334 our lectures covered: Processes, C Process API, Limited Direct Execution, CPU Scheduling, and MLFQ. In this learning journal I'll write and explanation/what I think to be the most important bits of each subject. Processes A process is a running instance of a program. It includes: Code (instructions) Data (variables, heap) Execution context (registers, stack, program counter) Operating systems manage processes to provide isolation, resource control, and scheduling. C Process API The C Process API refers to system calls and library functions in C for process management. Key functions include: fork() – Creates a new process by duplicating the current one. exec() – Replaces the current process image with a new one. wait() – Waits for a child process to finish. exit() – Terminates the current process. Limited Direct Execution (LDE) Limited Direct Execution is a technique where the OS allows a user program to run directly ...

Computer Science BS Journal (CST334) : Week 1

 This week in CST334 was loaded with information. Some of it review, some of it learning material. The things we covered in class this week include: An intro to the OS, Computer Architecture Review, Linux and the Shell, Programming in C, Command Line Introduction, and a Math Addendum. Half of this was review to me, and the other half was learning material. I'm not too familiar with the command line and Linux so that was a learning experience with me. I enjoyed basically being able to code in C for our assignments and run the tests on the command line. It was a smooth introduction for what is capable with the command line. Also the Math Addendum was a good refresher. I learned about hex and binary a bit in a previous class but never understood it 100%, only enough to answer some basic questions. I know I'll need to study that a bit more because I feel like it's pretty important to be able to read hex/binary. Another new topic or rather a learning experience was the Computer ...