Question
Let and denote read and write operations on a data element by a transaction , respectively. Consider the schedule with four transactions.
Which one of the following serial schedules is conflict equivalent to ?
Official answer and solution
- Official answer
- A
- From
- Official GATE 2022 answer key
Solution
Construct the conflict serializability precedence graph from conflicting read and write operations.
Given schedule .
We identify conflicting operations (operations by different transactions on the same data item where at least one is a write) in order of appearance:
- Conflicts on :
- occurs before
- occurs before
- Conflicts on :
- occurs before
- occurs before
- occurs before
- occurs before
Summarizing the precedence edges:
This directed acyclic graph has a unique topological sort:
This matches Option (A).
Option (A)
Missing the conflict between and which enforces .
The answer is the one in the official GATE answer key. The solution is this site's own explanation.
Source
- Paper
- GATE 2022 Computer Science and Information Technology (CS)
- Question
- 39 of 65
- Section
- Computer Science and Information Technology
Report an error in this question
GATE questions are the work of the organising institutes. This site is independent and is not affiliated with them.