What is the purpose of a memory fence? MCQ with Answer and Explanation

What is the purpose of a memory fence?
A. To enforce memory ordering in concurrent programming
B. To increase memory speed
C. To reduce memory usage
D. To separate memory regions for security
Answer: Option A
Solution (By JKSSB Mock Tests)
A memory fence is a barrier instruction that ensures all preceding memory operations are completed before subsequent ones, maintaining consistency in multi-threaded environments.

Discuss this Question (0)

No comments yet. Be the first to start the discussion!

Practice More Memory and Storage Devices Questions

Question #1
What does the term 'double buffering' refer to in memory management?
A. Using two separate memory banks
B. Using two buffers to overlap I/O and processing
C. Storing two copies of data for redundancy
D. Using two levels of cache

Correct Answer: Option B


Explanation:
Double buffering uses two buffers: one is being filled/read while the other is being processed, allowing overlap and reducing wait times.

This question belongs to: Computer Memory and Storage Devices
Question #2
What is the smallest logic allocation unit of data storage on a hard disk drive recognized by an operating system's file system?
A. Cluster
B. Sector
C. Platter
D. Track

Correct Answer: Option A


Explanation:
A cluster (or allocation unit) is a group of sectors combined by the operating system's file system to form the smallest legal space where a file can be stored.

This question belongs to: Computer Memory and Storage Devices
Question #3
What is the maximum storage capacity of a standard dual-layer DVD?
A. 4.7 GB
B. 9.4 GB
C. 8.5 GB
D. 15 GB

Correct Answer: Option C


Explanation:
A dual-layer DVD (DVD-9) holds about 8.5 GB (or 7.95 GiB). Single-layer is 4.7 GB. Some double-sided DVDs have more, but standard dual-layer is 8.5 GB.

This question belongs to: Computer Memory and Storage Devices