Operating systems miscellaneous


Operating systems miscellaneous

  1. A system contains three programs and each requires three tape units for its operation. The minimum number of tape units which the system must have such that deadlocks never arise is _________.









  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: B

    NA


  1. A system has n resources R0, ..... Rn - 1, and k processes P0, .... Pk - 1. The implementation of the resources request logic of each process Pi, is as follows if (i% 2 = = 0) {
        if (i < n) request Ri;
       if (i + 2 < n) request Ri + 2;
    }
    else {
      if (i < n) request Rn - i;
      if (i + 2 < n) request Rn - i - 2;
    }
    In which one of the following situations is a deadlock possible?









  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: B

    NA



  1. Consider the following processes, with the arrival time and the length of the CPU burst given in milliseconds. The scheduling algorithm used is preemptive shortest remainingtime first.

    The average turnaround time of these processes is ________ milliseconds.









  1. View Hint View Answer Discuss in Forum

    Due to SRTF preemption

    ∵ Completion Time = Arrival Time + Process Turn Around Time
    ∴ Process Turn Around Time = Completion Time – Arrival Time

    P1 20
    P2 7
    P3 1
    P4 5

    Average Turn Around Time (TAT) = 33 / 4 = 8.25

    Correct Option: A

    Due to SRTF preemption

    ∵ Completion Time = Arrival Time + Process Turn Around Time
    ∴ Process Turn Around Time = Completion Time – Arrival Time

    P1 20
    P2 7
    P3 1
    P4 5

    Average Turn Around Time (TAT) = 33 / 4 = 8.25


  1. Consider a uni processor system executing three tasks T1, T2 and T3, each o which is composed of an infinite sequence of jobs (or instances) which arrive periodically at intervals of 3, 7 and 20 milliseconds, respectively. The priority of each task is the inverse of its period, and the available tasks are scheduled in order of priority, with the highest priority task scheduled first. Each instance of T1, T2 and T3 requires an execution time of 1, 2 and 4 milliseconds, respectively. Given that all tasks initially arrive at the beginning of the 1st millisecond and task preemptions are allowed, the first instance of T3 completes its execution at the end of ______ milliseconds.









  1. View Hint View Answer Discuss in Forum

    Correct Option: B



  1. For the processes listed in the following table, which of the following scheduling schemes will give the lowest average turnaround time?










  1. View Hint View Answer Discuss in Forum




    Correct Option: C