1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-01-19 05:52:11 +01:00

[dxvk] Add descriptor pool tracking to command list

This commit is contained in:
Philip Rebohle 2022-06-19 22:58:15 +02:00
parent 9b0b1edf74
commit f4e9b76515
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
2 changed files with 16 additions and 1 deletions

View File

@ -186,6 +186,11 @@ namespace dxvk {
// Less important stuff
m_signalTracker.reset();
m_statCounters.reset();
for (const auto& descriptorPools : m_descriptorPools)
descriptorPools.second->recycleDescriptorPool(descriptorPools.first);
m_descriptorPools.clear();
}

View File

@ -200,7 +200,7 @@ namespace dxvk {
m_resources.notify();
m_signalTracker.notify();
}
/**
* \brief Resets the command list
*
@ -763,6 +763,12 @@ namespace dxvk {
m_vkd->device(), queryPool, queryId, 1);
}
void trackDescriptorPool(
const Rc<DxvkPersistentDescriptorPool>& pool,
const Rc<DxvkDescriptorManager>& manager) {
m_descriptorPools.push_back({ pool, manager });
}
private:
DxvkDevice* m_device;
@ -789,6 +795,10 @@ namespace dxvk {
DxvkBufferTracker m_bufferTracker;
DxvkStatCounters m_statCounters;
std::vector<std::pair<
Rc<DxvkPersistentDescriptorPool>,
Rc<DxvkDescriptorManager>>> m_descriptorPools;
VkCommandBuffer getCmdBuffer(DxvkCmdBuffer cmdBuffer) const {
if (cmdBuffer == DxvkCmdBuffer::ExecBuffer) return m_execBuffer;
if (cmdBuffer == DxvkCmdBuffer::InitBuffer) return m_initBuffer;