1. Home
  2. Explore
  3. Computer Science
  4. Process States and Lifecycle

Study methods

Flashcards
Quiz
Fill in the blanks
Written test
Lesson
Notes
Podcast
Content

Process States and Lifecycle

  • 44Unfamiliar
  • 0Learning
  • 0Familiar
  • 0Mastered
Topic: Process Lifecycle
  • spaceFlip card
  • KI knew it
  • DI didn't know it
  • ←Previous card
  • →Next card

Why is the process-state life-cycle model used?

Tap to flipClick to flipspace

To explain the states a process passes through from creation to completion; it is a model for understanding process progression.

Or swipe the card

44 cards

  1. Why is the process-state life-cycle model used?

    To explain the states a process passes through from creation to completion; it is a model for understanding process progression.

  2. What are the five primary process states?

    New, ready, running, waiting (or blocked), and terminated.

  3. What does the new state represent?

    A process has been created but has not yet become ready for CPU execution.

  4. What does the ready state represent?

    A process is in main memory and waiting for CPU time.

  5. What is the ready queue?

    The queue of processes in the ready state that are waiting to be selected for execution.

  6. What does the running state represent?

    The process is currently being executed by the CPU.

  7. What does the waiting or blocked state represent?

    A process is waiting for an event, such as the completion of an I/O operation, rather than using the CPU.

  8. What happens when a process enters the terminated state?

    Its execution is complete, and the operating system deallocates the resources assigned to it.

  9. What is the usual process-state path from creation to completion?

    New → ready → running → terminated. A process may also move from running to waiting and later return to ready.

  10. What is the long-term scheduler's main responsibility?

    To admit processes into the ready state from the pool of processes in secondary storage.

  11. How is the long-term scheduler related to multiprogramming?

    By admitting processes to the ready queue, it controls how many processes are available in memory for execution—a central part of multiprogramming.

  12. Why does the long-term scheduler admit only some processes to the ready state?

    Main memory is limited, so the system cannot keep every process in the ready state at once.

  13. What is the short-term scheduler's main responsibility?

    To select a process from the ready state and dispatch it to the CPU for execution.

  14. What is the medium-term scheduler's main responsibility?

    To swap processes out of main memory and later bring them back when memory or queue capacity allows.

  15. Which scheduler selects a process for the next CPU turn?

    The short-term scheduler selects a ready process and dispatches it to the CPU.

  16. How do the long-term and short-term schedulers differ?

    The long-term scheduler admits processes to the ready state; the short-term scheduler chooses a ready process to run on the CPU.

  17. How many processes can run at the same time on a uniprocessor system, according to the model?

    One process at a time, because the system has one CPU.

  18. What does parallel processing allow a multiprocessor system to do?

    Use multiple processors to execute multiple processes in parallel.

  19. What is preemptive scheduling?

    Scheduling in which a running process can be interrupted and returned to the ready state before it finishes.

  20. What is non-preemptive scheduling?

    Scheduling in which a process keeps the CPU until it completes or otherwise gives it up, rather than being interrupted mid-execution.

  21. What are two reasons a running process might be preempted?

    A higher-priority process becomes ready, or the running process's time quantum expires.

  22. How does round-robin scheduling use a time quantum?

    It lets each process run for a fixed time interval; if the process has not finished when the interval expires, it is returned to the ready queue.

  23. In round-robin scheduling, what happens if a process finishes before its time quantum expires?

    The process terminates and releases its resources instead of returning to the ready queue.

  24. What causes a running process to enter the waiting or blocked state?

    The process requests I/O or another event that it must wait for, such as reading a file or accessing hardware.

  25. Why does a process wait while an I/O request is being handled?

    I/O devices, especially secondary storage, are slower than the CPU, so the process cannot continue until the requested operation completes.

  26. What happens to the CPU when a process blocks for I/O?

    The blocked process waits, allowing the CPU to execute another ready process instead of idling while the I/O operation proceeds.

  27. Where does a blocked process wait in the basic state model?

    In the waiting or blocked state, represented as a wait queue in main memory.

  28. Where does a process go after its I/O operation completes?

    It returns to the ready state or ready queue; it does not immediately resume running.

  29. Give two examples of requests that can make a process block.

    Reading a file from secondary storage and accessing a hardware device such as a monitor.

  30. Why might a process be moved from the waiting queue to a suspended-wait state?

    The waiting queue or available main memory may be full, so the process is swapped out to secondary storage temporarily.

  31. What does swapping out a process mean?

    Moving the process from main memory to secondary storage temporarily to free memory.

  32. What is the suspended-wait state?

    A state for a process that was waiting for an event but has been swapped out of main memory.

  33. After a suspended-wait process finishes its I/O, where can it go?

    It can move to the ready state if space is available; otherwise, it may have to remain suspended until space opens.

  34. Why might a ready process be placed in the suspended-ready state?

    The ready queue or main memory may be full, or space may need to be made for a high-priority process.

  35. What is the suspended-ready state?

    A state for a process that is ready to run but has been moved out of main memory, usually because memory or ready-queue capacity is limited.

  36. Where does a suspended-ready process go when it can return to memory?

    It is resumed into the ready state and waits for the short-term scheduler to select it.

  37. What is the backing store in the process-suspension context?

    Secondary storage used to hold processes that have been swapped out of main memory.

  38. Which scheduler manages swapping processes out of and back into memory?

    The medium-term scheduler.

  39. What factors may a medium-term scheduler use to choose processes for swapping?

    It may use a scheduling policy such as priority or usage-based criteria to select processes and free memory.

  40. Where can you view a list of processes in Windows?

    In the Processes tab of Task Manager.

  41. What kinds of processes can Windows Task Manager help distinguish?

    System processes and user processes.

  42. Which command is commonly used to inspect processes in Unix or Linux?

    The ps command.

  43. What kinds of information can the ps command show about a process?

    It can show information such as the process ID, the command being executed, and CPU-running information.

  44. What are examples of variations of the Unix/Linux ps command?

    ps -e and ps -u are examples of ps command variations.

Card 1 of 44
Card 1 of 44

Ask anything

We've read this whole study set, so questions about it get the best answers.

FlashcardsQuizFill in the blanksWritten testLessonNotesPodcastContent