diff --git a/src/d3d11/d3d11_cmdlist.cpp b/src/d3d11/d3d11_cmdlist.cpp index 883f4986..9a866581 100644 --- a/src/d3d11/d3d11_cmdlist.cpp +++ b/src/d3d11/d3d11_cmdlist.cpp @@ -52,7 +52,7 @@ namespace dxvk { void D3D11CommandList::EmitToCommandList(ID3D11CommandList* pCommandList) { auto cmdList = static_cast(pCommandList); - for (auto chunk : m_chunks) + for (const auto& chunk : m_chunks) cmdList->m_chunks.push_back(chunk); cmdList->m_drawCount += m_drawCount; @@ -60,7 +60,7 @@ namespace dxvk { void D3D11CommandList::EmitToCsThread(DxvkCsThread* CsThread) { - for (auto chunk : m_chunks) + for (const auto& chunk : m_chunks) CsThread->dispatchChunk(Rc(chunk)); } diff --git a/src/d3d11/d3d11_context.cpp b/src/d3d11/d3d11_context.cpp index f0032bb5..9aff8553 100644 --- a/src/d3d11/d3d11_context.cpp +++ b/src/d3d11/d3d11_context.cpp @@ -2604,7 +2604,7 @@ namespace dxvk { } // Create and bind the framebuffer object to the context - EmitCs([cAttachments = std::move(attachments)] (DxvkContext* ctx) { + EmitCs([cAttachments = attachments] (DxvkContext* ctx) { ctx->bindRenderTargets(cAttachments); }); } diff --git a/src/d3d11/d3d11_device.cpp b/src/d3d11/d3d11_device.cpp index aab795bd..f36f5a9d 100644 --- a/src/d3d11/d3d11_device.cpp +++ b/src/d3d11/d3d11_device.cpp @@ -1032,7 +1032,7 @@ namespace dxvk { return S_FALSE; *ppVertexShader = ref(new D3D11VertexShader( - this, std::move(module))); + this, module)); return S_OK; } @@ -1054,7 +1054,7 @@ namespace dxvk { return S_FALSE; *ppGeometryShader = ref(new D3D11GeometryShader( - this, std::move(module))); + this, module)); return S_OK; } @@ -1092,7 +1092,7 @@ namespace dxvk { return S_FALSE; *ppPixelShader = ref(new D3D11PixelShader( - this, std::move(module))); + this, module)); return S_OK; } @@ -1114,7 +1114,7 @@ namespace dxvk { return S_FALSE; *ppHullShader = ref(new D3D11HullShader( - this, std::move(module))); + this, module)); return S_OK; } @@ -1136,7 +1136,7 @@ namespace dxvk { return S_FALSE; *ppDomainShader = ref(new D3D11DomainShader( - this, std::move(module))); + this, module)); return S_OK; } @@ -1158,7 +1158,7 @@ namespace dxvk { return S_FALSE; *ppComputeShader = ref(new D3D11ComputeShader( - this, std::move(module))); + this, module)); return S_OK; } diff --git a/src/d3d11/d3d11_shader.h b/src/d3d11/d3d11_shader.h index 6483b16a..5679fd9a 100644 --- a/src/d3d11/d3d11_shader.h +++ b/src/d3d11/d3d11_shader.h @@ -104,7 +104,7 @@ namespace dxvk { public: D3D11Shader(D3D11Device* device, const D3D11ShaderModule& module) - : m_device(device), m_module(std::move(module)) { } + : m_device(device), m_module(module) { } ~D3D11Shader() { } diff --git a/src/dxvk/hud/dxvk_hud_stats.cpp b/src/dxvk/hud/dxvk_hud_stats.cpp index 7d56badc..cff470ff 100644 --- a/src/dxvk/hud/dxvk_hud_stats.cpp +++ b/src/dxvk/hud/dxvk_hud_stats.cpp @@ -47,7 +47,7 @@ namespace dxvk::hud { const Rc& context, HudRenderer& renderer, HudPos position) { - const uint64_t frameCount = std::max(m_diffCounters.getCtr(DxvkStatCounter::QueuePresentCount), 1ull); + const uint64_t frameCount = std::max(m_diffCounters.getCtr(DxvkStatCounter::QueuePresentCount), 1); const uint64_t gpCalls = m_diffCounters.getCtr(DxvkStatCounter::CmdDrawCalls) / frameCount; const uint64_t cpCalls = m_diffCounters.getCtr(DxvkStatCounter::CmdDispatchCalls) / frameCount; @@ -80,7 +80,7 @@ namespace dxvk::hud { const Rc& context, HudRenderer& renderer, HudPos position) { - const uint64_t frameCount = std::max(m_diffCounters.getCtr(DxvkStatCounter::QueuePresentCount), 1ull); + const uint64_t frameCount = std::max(m_diffCounters.getCtr(DxvkStatCounter::QueuePresentCount), 1); const uint64_t numSubmits = m_diffCounters.getCtr(DxvkStatCounter::QueueSubmitCount) / frameCount; const std::string strSubmissions = str::format("Queue submissions: ", numSubmits); @@ -152,4 +152,4 @@ namespace dxvk::hud { HudElement::StatMemory); } -} \ No newline at end of file +}