1/20
A set of flashcards covering key terms and concepts related to threads, concurrency, CPU scheduling, and synchronization in computing.
Name | Mastery | Learn | Test | Matching | Spaced |
---|
No study sessions yet.
Trap
Software-generated interruption, such as a system call.
Exception
An unexpected error, for example, division by zero.
User-Level Threads
Threads managed in user space, faster and more lightweight (Blocking Affects All).
Kernel-Level Threads
Threads managed by the operating system, providing true parallelism (Blocking Affects One).
Turnaround Time (TT)
The time from arrival to completion, calculated as TT = Completion – Arrival.
Waiting Time (WT)
The time a process waits in the ready queue, calculated as WT = Turnaround – Burst = Start Time – Time executed before start - Arrival.
Dispatch Latency
Time to switch context between processes (scheduling overhead).
Critical Section (CS) Problem
The problem of ensuring that only one process executes in a critical section at any given time.
Mutual Exclusion
Only one process in Critical Section at a time.
Progress
Guarantees only 1 process can enter the critical section if no other processes are in it.
Bounded Waiting
A requirement that limits the time a process can wait to enter the critical section.
Semaphores
Synchronization tools that can be binary (acting like a lock) or counting (controlling access to a resource pool).
Test-and-Set Model
A technique for ensuring mutual exclusion that uses atomic instructions to manage locks (Returns previous value; sets lock to true).
Busy Waiting
A scenario where a process spins in a loop, wasting CPU time while waiting for a condition to be met.
Spinlock
A type of lock that uses busy waiting, efficient for short waits.
Peterson’s Solution
A method to ensure mutual exclusion for 2 threads using shared flags and a turn variable.
First-Come, First-Served (FCFS) Scheduling
A simple scheduling algorithm that can cause convoy effects.
Shortest Job First (SJF) Scheduling
An algorithm that selects the process with the shortest burst time next.
Shortest Remaining Time First (SRTF) Scheduling
A preemptive version of SJF that selects the process with the shortest remaining time.
Round Robin (RR) Scheduling
A fair scheduling algorithm that uses time quantum to allocate CPU.
Priority Scheduling
An algorithm that may cause starvation, which can be mitigated through aging.