Question 1
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?
0x400053FF
0x40005400
0x400052FF
0x40004FFF
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?
0x400053FF
0x40005400
0x400052FF
0x40004FFF
Consider the following code snippet:
#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?
Sizes of all the registers are 4-byte.
Sizes of ‘config_reg‘, ‘status_reg‘, and ‘counter_reg‘ are 4-byte, 1-byte, and 2- byte respectively.
Sizes of ‘config_reg‘, ‘status_reg‘, and ‘counter_reg‘ are 2-byte, 1-byte, and 2- byte respectively.
Sizes of ‘config_reg‘, ‘status_reg‘, and ‘counter_reg‘ are 1-byte, 2-byte, and 4- byte respectively.
What does the following ‘xv6‘ code snippet accomplish?
int pid;
pid = fork();if (pid == 0) { execlp("ls", "ls", "-l", NULL); exit(0);} else if (pid > 0) { int status; wait(&status);}Both the parent and child processes execute the ‘ls‘ command concurrently.
The child process executes the ‘ls -l‘ command, and the parent process waits for it to complete.
The parent process executes the ‘ls -l‘ command, and the child process terminates.
None of these
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.
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.
| Feature | Operating Systems Quiz 1 23 Feb 2025 at a glance |
|---|---|
| Term | January 2025 term |
| Subject | Operating Systems |
| Course code | BSCS4022 |
| Questions | 19 |
| Marks | 50 |
| Duration | 120 min |
| MCQ | 17 |
| MSQ | 2 |
| Official paper | IIT M IMPROVEMENT AN EXAM QIM2 23 Feb 2025 |
| Negative marking | No negative marking. |
| Updated |