|
@@ -22,10 +22,10 @@ namespace Vulkan {
|
|
|
class CachedQuery;
|
|
class CachedQuery;
|
|
|
class Device;
|
|
class Device;
|
|
|
class HostCounter;
|
|
class HostCounter;
|
|
|
-class VKQueryCache;
|
|
|
|
|
|
|
+class QueryCache;
|
|
|
class Scheduler;
|
|
class Scheduler;
|
|
|
|
|
|
|
|
-using CounterStream = VideoCommon::CounterStreamBase<VKQueryCache, HostCounter>;
|
|
|
|
|
|
|
+using CounterStream = VideoCommon::CounterStreamBase<QueryCache, HostCounter>;
|
|
|
|
|
|
|
|
class QueryPool final : public ResourcePool {
|
|
class QueryPool final : public ResourcePool {
|
|
|
public:
|
|
public:
|
|
@@ -49,13 +49,13 @@ private:
|
|
|
std::vector<bool> usage;
|
|
std::vector<bool> usage;
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
-class VKQueryCache final
|
|
|
|
|
- : public VideoCommon::QueryCacheBase<VKQueryCache, CachedQuery, CounterStream, HostCounter> {
|
|
|
|
|
|
|
+class QueryCache final
|
|
|
|
|
+ : public VideoCommon::QueryCacheBase<QueryCache, CachedQuery, CounterStream, HostCounter> {
|
|
|
public:
|
|
public:
|
|
|
- explicit VKQueryCache(VideoCore::RasterizerInterface& rasterizer_,
|
|
|
|
|
- Tegra::Engines::Maxwell3D& maxwell3d_, Tegra::MemoryManager& gpu_memory_,
|
|
|
|
|
- const Device& device_, Scheduler& scheduler_);
|
|
|
|
|
- ~VKQueryCache();
|
|
|
|
|
|
|
+ explicit QueryCache(VideoCore::RasterizerInterface& rasterizer_,
|
|
|
|
|
+ Tegra::Engines::Maxwell3D& maxwell3d_, Tegra::MemoryManager& gpu_memory_,
|
|
|
|
|
+ const Device& device_, Scheduler& scheduler_);
|
|
|
|
|
+ ~QueryCache();
|
|
|
|
|
|
|
|
std::pair<VkQueryPool, u32> AllocateQuery(VideoCore::QueryType type);
|
|
std::pair<VkQueryPool, u32> AllocateQuery(VideoCore::QueryType type);
|
|
|
|
|
|
|
@@ -75,9 +75,9 @@ private:
|
|
|
std::array<QueryPool, VideoCore::NumQueryTypes> query_pools;
|
|
std::array<QueryPool, VideoCore::NumQueryTypes> query_pools;
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
-class HostCounter final : public VideoCommon::HostCounterBase<VKQueryCache, HostCounter> {
|
|
|
|
|
|
|
+class HostCounter final : public VideoCommon::HostCounterBase<QueryCache, HostCounter> {
|
|
|
public:
|
|
public:
|
|
|
- explicit HostCounter(VKQueryCache& cache_, std::shared_ptr<HostCounter> dependency_,
|
|
|
|
|
|
|
+ explicit HostCounter(QueryCache& cache_, std::shared_ptr<HostCounter> dependency_,
|
|
|
VideoCore::QueryType type_);
|
|
VideoCore::QueryType type_);
|
|
|
~HostCounter();
|
|
~HostCounter();
|
|
|
|
|
|
|
@@ -86,7 +86,7 @@ public:
|
|
|
private:
|
|
private:
|
|
|
u64 BlockingQuery() const override;
|
|
u64 BlockingQuery() const override;
|
|
|
|
|
|
|
|
- VKQueryCache& cache;
|
|
|
|
|
|
|
+ QueryCache& cache;
|
|
|
const VideoCore::QueryType type;
|
|
const VideoCore::QueryType type;
|
|
|
const std::pair<VkQueryPool, u32> query;
|
|
const std::pair<VkQueryPool, u32> query;
|
|
|
const u64 tick;
|
|
const u64 tick;
|
|
@@ -94,7 +94,7 @@ private:
|
|
|
|
|
|
|
|
class CachedQuery : public VideoCommon::CachedQueryBase<HostCounter> {
|
|
class CachedQuery : public VideoCommon::CachedQueryBase<HostCounter> {
|
|
|
public:
|
|
public:
|
|
|
- explicit CachedQuery(VKQueryCache&, VideoCore::QueryType, VAddr cpu_addr_, u8* host_ptr_)
|
|
|
|
|
|
|
+ explicit CachedQuery(QueryCache&, VideoCore::QueryType, VAddr cpu_addr_, u8* host_ptr_)
|
|
|
: CachedQueryBase{cpu_addr_, host_ptr_} {}
|
|
: CachedQueryBase{cpu_addr_, host_ptr_} {}
|
|
|
};
|
|
};
|
|
|
|
|
|