Commit 62080229 authored by Dan Melnic's avatar Dan Melnic Committed by Facebook Github Bot

Fix broken opt build due to unused var warning

Summary: Fix broken opt build due to unused var warning

Reviewed By: yfeldblum

Differential Revision: D13317777

fbshipit-source-id: 9e4928558e0514bdb5ab21e78b026c5c1a44a380
parent a2abde96
...@@ -334,7 +334,7 @@ struct BufferedAtomic { ...@@ -334,7 +334,7 @@ struct BufferedAtomic {
// Static destructors that outlive DSched instance may load atomics // Static destructors that outlive DSched instance may load atomics
if (!DeterministicSchedule::isActive()) { if (!DeterministicSchedule::isActive()) {
auto prev = prevUnguardedAccess.exchange(std::this_thread::get_id()); auto prev = prevUnguardedAccess.exchange(std::this_thread::get_id());
assert(prev == std::thread::id() || prev == std::this_thread::get_id()); CHECK(prev == std::thread::id() || prev == std::this_thread::get_id());
return getBuf().loadDirect(); return getBuf().loadDirect();
} }
ThreadInfo& threadInfo = DeterministicSchedule::getCurrentThreadInfo(); ThreadInfo& threadInfo = DeterministicSchedule::getCurrentThreadInfo();
...@@ -346,7 +346,7 @@ struct BufferedAtomic { ...@@ -346,7 +346,7 @@ struct BufferedAtomic {
// Static destructors that outlive DSched instance may store to atomics // Static destructors that outlive DSched instance may store to atomics
if (!DeterministicSchedule::isActive()) { if (!DeterministicSchedule::isActive()) {
auto prev = prevUnguardedAccess.exchange(std::this_thread::get_id()); auto prev = prevUnguardedAccess.exchange(std::this_thread::get_id());
assert(prev == std::thread::id() || prev == std::this_thread::get_id()); CHECK(prev == std::thread::id() || prev == std::this_thread::get_id());
getBuf().storeDirect(val); getBuf().storeDirect(val);
return; return;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment