Quiz Space

Operating Systems Quiz 1: 23 February 2025 (January 2025 term)

Question 1

+3 marksOne correct option

If the memory map for a device starts from the offset 0x40005000 and has a size of 1024 bytes in a 32-bit addressing scheme, what will be the last address in the memory map?

  1. A

    0x400053FF

  2. B

    0x40005400

  3. C

    0x400052FF

  4. D

    0x40004FFF

Question 2

+3 marksOne correct option

Consider the following code snippet:

c
#define TIMER_BASE 0x40010000
void configure_timer(){
uint32_t *config_reg = (uint32_t*)(TIMER_BASE + 0x00);
uint8_t *status_reg = (uint8_t*)(TIMER_BASE + 0x04);
uint16_t *counter_reg = (uint16_t*)(TIMER_BASE + 0x08);
*config_reg = 0x1;
while((*status_reg & 0x1) == 0);
*counter_reg = 0xFFFF;
}

What are the sizes of the config_reg, status_reg, and counter_reg registers, respectively?

  1. A

    Sizes of all the registers are 4-byte.

  2. B

    Sizes of ‘config_reg‘, ‘status_reg‘, and ‘counter_reg‘ are 4-byte, 1-byte, and 2- byte respectively.

  3. C

    Sizes of ‘config_reg‘, ‘status_reg‘, and ‘counter_reg‘ are 2-byte, 1-byte, and 2- byte respectively.

  4. D

    Sizes of ‘config_reg‘, ‘status_reg‘, and ‘counter_reg‘ are 1-byte, 2-byte, and 4- byte respectively.

Question 3

+3 marksOne correct option

What does the following ‘xv6‘ code snippet accomplish?

c
int pid;
pid = fork();
if (pid == 0) {
execlp("ls", "ls", "-l", NULL);
exit(0);
} else if (pid > 0) {
int status;
wait(&status);
}
  1. A

    Both the parent and child processes execute the ‘ls‘ command concurrently.

  2. B

    The child process executes the ‘ls -l‘ command, and the parent process waits for it to complete.

  3. C

    The parent process executes the ‘ls -l‘ command, and the child process terminates.

  4. D

    None of these

16 more questions in this paper

Sign in with Google — it is free — to see every question with its answer and explanation, practise it in learning mode, or take it as a timed mock test.

More on the Operating Systems Quiz 1 23 Feb 2025 paper

The IIT Madras BS Operating Systems (Operating Systems) Quiz 1 paper sat on 23 Feb 2025, in the January 2025 term: 19 questions for 50 marks in 120 minutes. The first 3 questions are below. Sign in with Google — it is free — to see the whole paper with its answers and explanations, in learning mode or as a timed mock test.

FeatureOperating Systems Quiz 1 23 Feb 2025 at a glance
TermJanuary 2025 term
SubjectOperating Systems
Course codeBSCS4022
Questions19
Marks50
Duration120 min
MCQ17
MSQ2
Official paperIIT M IMPROVEMENT AN EXAM QIM2 23 Feb 2025
Negative markingNo negative marking.
Updated

Same Quiz 1, other subjects

More Operating Systems