1
0
mirror of https://github.com/TomHarte/CLK.git synced 2026-04-20 10:17:05 +00:00

Factor out spin lock, get a bit stricter on PointerSets.

This commit is contained in:
Thomas Harte
2026-02-14 11:14:20 -05:00
parent 6d52fdea4d
commit ed061fa9b3
5 changed files with 78 additions and 18 deletions
+2 -3
View File
@@ -32,9 +32,6 @@ BufferingScanTarget::BufferingScanTarget() {
// Ensure proper initialisation of the two atomic pointer sets.
read_pointers_.store(write_pointers_, std::memory_order_relaxed);
submit_pointers_.store(write_pointers_, std::memory_order_relaxed);
// Establish initial state for is_updating_.
is_updating_.clear(std::memory_order_relaxed);
}
// MARK: - Producer; pixel data.
@@ -223,6 +220,8 @@ void BufferingScanTarget::announce(
is_first_in_frame_ = true;
previous_frame_was_complete_ = frame_is_complete_;
frame_is_complete_ = true;
// frames_[frame_pointer_]
}
// Proceed from here only if a change in visibility has occurred.