30 likes | 180 Views
Disabling Interupt. Fajar A P (1002405) Hafidz Dali (1002345) Muhammad Yuziandhi A (1006514) Riska Apriani (1000787 ). Let’s Start. Perkenalan Tugas Sistem Operasi Dosen Jajang Kusnendar, M.T. Disabling Interrupts. Pengertian
E N D
Disabling Interupt Fajar A P (1002405) Hafidz Dali (1002345) Muhammad Yuziandhi A (1006514) Riska Apriani (1000787) Let’s Start Perkenalan Tugas Sistem Operasi Dosen Jajang Kusnendar, M.T
Disabling Interrupts Pengertian Disabling Interuptsadalahmenghentikaninterupsisehingga proses lain tidakbisamengganggu proses yang sedangberlangsung Pseudo-Code (algorithm) while (true) { /* disable interrupts */; /* critical section */; /* enable interrupts */; /* remainder */; } Pseudo-Code Interrupt Disable/Enable Pattern • class Lock{ int value = FREE; • } • Lock::Acquire(){ Disable interrupts; while (value != FREE){ Enable interrupts; // allow interrupts Disable interrupts; } value = BUSY; Enable interrupts; • } • Lock::Release(){ Disable interrupts; value = FREE; Enable Interrupts; • } 2
Start Tutorial Interrupt disable/enable pattern Tread Mutually Exclusive P1 Resource Critical Section P2 Proses Berlangsung Critical Section Dimanasebuah proses memilikibagiandimanabagianiniakanmelakukanaksesdanmanipulasi data Mutually Exclusive Keadaandimanamemungkinkanterjadinyaakseskeresources yang samadalamwaktu yang sama Interrupt Disable Keadaansaat Interrupt Disable aktifmaka proses yang lain tidakbolehmengganggu P3 P4 On Off P5 Status :