1 / 3

3. System Mechanisms ■ Trap Dispatching

3. System Mechanisms ■ Trap Dispatching - Trap : A Processor`s mechanism for capturing an executing thread an exception or an interrupt occurs and transferring control to a fixed location in the OS.

anneke
Télécharger la présentation

3. System Mechanisms ■ Trap Dispatching

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. 3. System Mechanisms ■ Trap Dispatching - Trap : A Processor`s mechanism for capturing an executing thread an exception or an interrupt occurs and transferring control to a fixed location in the OS. - Trap handler : A function specific to a particular interrupt or exception. - Interrupt : An asynchronous event (Not effect that processor us executing) - Exception : A synchronous Condition Processor : 현재 상태를 기록했다가 인터럽트 처리 후 재실행

  2. ● H/W Interrupt Processing - external I/O interrupts → interrupt controller → Interrupt # transfer to IRQ → IDT → transfers control to interrupt dispatch routine. 1. x86 Interrupt Controllers - PIC (Programmable Interrupt Controller – i8259A), APIC (Advanced PIC – i82489) ● S/W Interrupt Request Levels (IRQLs) • APC (Asynchronous Procedure Call) • DPC (Deferred Procedure Call) • High Level : System Crash • Power Fail • Inter-processor Interrupt : 다른 프로세서가 특정 Thread를 • 실행하도록 Dispatching, Shutdown, Crash • - Clock : Kernel의 날짜 유지, Thread에 대한 CPU 시간 측정 / 할당 H/W • Dispatch : S/W조절할 수 있는 가장 상위값 • APC : 드라이버 사용 X, S/W • Passive : User모드에서 실행되는 모든 Thread ● IRQL 설정 함수 - KeRaiseIrql() : 현재 값보다 상향으로 조절, 단순히 값만 - KeLowerIrql() : 현재 값보다 낮은쪽으로

  3. ● DPC Interrupt (Dispatch or Deferred Procedure Call) - Multiprocessor 상에서 동기화 : 병렬적인 Processor의 interrupt Routine ● APC Interrupt (Asynchronous Procedure Call) - execute in the context of a particular thread and run at an IRQL less than DPC/dispatch level - DPC 대기열과는 달리 APC 대기열에 스레드에 한정

More Related