Thread: GATE CS Previous Year Questions

Thread · Operating System

11 questions · asked in 8 of 27 years (2000–2026)

MCQ 8 · MSQ 31-mark 10 · 2-mark 1

2000Questions per year2026

Questions 1–5 of 11

Q1GATE 2024 (Session 1)1 markMSQ
Which of the following statements about threads is/are TRUE?

One or more options are correct.

Q2GATE 20231 markMSQ
Which one or more of the following need to be saved on a context switch from one thread (T1) of a process to another thread (T2) of the same process?

One or more options are correct.

Q3GATE 2021 (Session 2)2 marksMSQ
Consider the following multi-threaded code segment (in a mix of C and pseudo-code), invoked by two processes P1 and P2, and each of the processes spawns two threads T1 and T2:
int x = 0;  // global
Lock L1;    // global
main () { 
    create a thread to execute foo( ); // Thread T1
    create a thread to execute foo( ); // Thread T2
    wait for the two threads to finish execution;
    print(x);}
    
    
foo() {
    int y = 0;
    Acquire L1;
    x = x + 1;
    y = y + 1;
    Release L1;
    print (y);} 
Which of the following statement(s) is/are correct?

One or more options are correct.

Q4GATE 2017 (Session 1)1 markMCQ−0.33 if wrong
Threads of a process share

Q5GATE 2017 (Session 2)1 markMCQ−0.33 if wrong
Which of the following is/are shared by all the threads in a process ?
I. Program counter
II. Stack
III. Address space
IV. Registers

Keep practising

Topics in Operating System

All CS topics ›