Bird
0
0

Why does FreeRTOS preempt a running task immediately when a higher priority task becomes ready?

hard📝 Conceptual Q10 of 15
FreeRTOS - Task Scheduling
Why does FreeRTOS preempt a running task immediately when a higher priority task becomes ready?
ATo prevent lower priority tasks from running at all
BTo allow tasks to run in the order they were created
CTo ensure the highest priority task gets CPU time as soon as possible
DTo reduce context switching overhead
Step-by-Step Solution
Solution:
  1. Step 1: Understand preemption purpose

    Preemption ensures that the highest priority task runs immediately to meet real-time requirements.
  2. Step 2: Evaluate other options

    Lower priority tasks still run when higher priority tasks block; order of creation is not priority-based; preemption may increase context switches.
  3. Final Answer:

    To ensure the highest priority task gets CPU time as soon as possible -> Option C
  4. Quick Check:

    Preemption prioritizes highest priority task immediately [OK]
Quick Trick: Preemption prioritizes highest priority task immediately [OK]
Common Mistakes:
  • Thinking preemption stops lower priority tasks forever
  • Believing tasks run by creation order
  • Assuming preemption reduces context switches

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More FreeRTOS Quizzes