1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2024-11-30 13:24:10 +01:00

[dxvk] Minor

This commit is contained in:
Philip Rebohle 2018-03-22 11:01:54 +01:00
parent 5c2144b55d
commit 9215cfdcf2
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
3 changed files with 6 additions and 7 deletions

View File

@ -7,8 +7,8 @@ namespace dxvk {
void DxvkLifetimeTracker::reset() {
for (auto i = m_resources.cbegin(); i != m_resources.cend(); i++)
(*i)->release();
for (const auto& resource : m_resources)
resource->release();
m_resources.clear();
}

View File

@ -30,9 +30,8 @@ namespace dxvk {
});
m_entries.push({ fence, cmdList });
m_condOnAdd.notify_one();
}
m_condOnAdd.notify_one();
}
@ -50,10 +49,10 @@ namespace dxvk {
entry = std::move(m_entries.front());
m_entries.pop();
}
m_condOnTake.notify_one();
}
m_condOnTake.notify_one();
if (entry.fence != nullptr) {
while (!entry.fence->wait(1'000'000'000ull))
continue;

View File

@ -25,7 +25,7 @@ namespace dxvk {
virtual ~DxvkResource();
bool isInUse() const {
return m_useCount != 0;
return m_useCount.load() != 0;
}
void acquire() { m_useCount += 1; }