From ed563f5ec9d3b2f2d7e53ec7e5c98ef0eff29d06 Mon Sep 17 00:00:00 2001 From: "Bernhart, Bryan" Date: Fri, 14 Apr 2023 15:12:09 -0700 Subject: [PATCH] Move GetTypename to macro. --- src/gpgmm/common/BuddyBlockAllocator.cpp | 4 ---- src/gpgmm/common/BuddyBlockAllocator.h | 2 +- src/gpgmm/common/BuddyMemoryAllocator.cpp | 4 ---- src/gpgmm/common/BuddyMemoryAllocator.h | 2 +- src/gpgmm/common/ConditionalMemoryAllocator.cpp | 4 ---- src/gpgmm/common/ConditionalMemoryAllocator.h | 2 +- src/gpgmm/common/DedicatedMemoryAllocator.cpp | 4 ---- src/gpgmm/common/DedicatedMemoryAllocator.h | 2 +- src/gpgmm/common/Memory.cpp | 4 ---- src/gpgmm/common/Memory.h | 2 +- src/gpgmm/common/MemoryAllocation.cpp | 4 ---- src/gpgmm/common/MemoryAllocation.h | 2 +- src/gpgmm/common/MemoryAllocator.cpp | 4 ---- src/gpgmm/common/MemoryAllocator.h | 2 +- src/gpgmm/common/Object.h | 5 +++++ src/gpgmm/common/PooledMemoryAllocator.cpp | 4 ---- src/gpgmm/common/PooledMemoryAllocator.h | 2 +- src/gpgmm/common/SegmentedMemoryAllocator.cpp | 4 ---- src/gpgmm/common/SegmentedMemoryAllocator.h | 2 +- src/gpgmm/common/SlabBlockAllocator.cpp | 4 ---- src/gpgmm/common/SlabBlockAllocator.h | 2 +- src/gpgmm/common/SlabMemoryAllocator.cpp | 8 -------- src/gpgmm/common/SlabMemoryAllocator.h | 4 ++-- src/gpgmm/d3d12/DebugResourceAllocatorD3D12.cpp | 4 ---- src/gpgmm/d3d12/DebugResourceAllocatorD3D12.h | 2 +- src/gpgmm/d3d12/HeapD3D12.cpp | 4 ---- src/gpgmm/d3d12/HeapD3D12.h | 2 +- src/gpgmm/d3d12/ResidencyManagerD3D12.cpp | 4 ---- src/gpgmm/d3d12/ResidencyManagerD3D12.h | 2 +- src/gpgmm/d3d12/ResourceAllocationD3D12.cpp | 4 ---- src/gpgmm/d3d12/ResourceAllocationD3D12.h | 2 +- src/gpgmm/d3d12/ResourceAllocatorD3D12.cpp | 4 ---- src/gpgmm/d3d12/ResourceAllocatorD3D12.h | 2 +- src/gpgmm/d3d12/ResourceHeapAllocatorD3D12.cpp | 4 ---- src/gpgmm/d3d12/ResourceHeapAllocatorD3D12.h | 2 +- 35 files changed, 23 insertions(+), 90 deletions(-) diff --git a/src/gpgmm/common/BuddyBlockAllocator.cpp b/src/gpgmm/common/BuddyBlockAllocator.cpp index 429fe0956..14d7dd4de 100644 --- a/src/gpgmm/common/BuddyBlockAllocator.cpp +++ b/src/gpgmm/common/BuddyBlockAllocator.cpp @@ -262,8 +262,4 @@ namespace gpgmm { SafeDelete(block); } - const char* BuddyBlockAllocator::GetTypename() const { - return "BuddyBlockAllocator"; - } - } // namespace gpgmm diff --git a/src/gpgmm/common/BuddyBlockAllocator.h b/src/gpgmm/common/BuddyBlockAllocator.h index 82f98346a..c5a991af1 100644 --- a/src/gpgmm/common/BuddyBlockAllocator.h +++ b/src/gpgmm/common/BuddyBlockAllocator.h @@ -50,7 +50,7 @@ namespace gpgmm { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(BuddyBlockAllocator) uint32_t ComputeLevelFromBlockSize(uint64_t blockSize) const; uint64_t GetNextFreeAlignedBlock(size_t allocationBlockLevel, uint64_t alignment) const; diff --git a/src/gpgmm/common/BuddyMemoryAllocator.cpp b/src/gpgmm/common/BuddyMemoryAllocator.cpp index 307025fba..cafaae3fe 100644 --- a/src/gpgmm/common/BuddyMemoryAllocator.cpp +++ b/src/gpgmm/common/BuddyMemoryAllocator.cpp @@ -146,8 +146,4 @@ namespace gpgmm { return result; } - const char* BuddyMemoryAllocator::GetTypename() const { - return "BuddyMemoryAllocator"; - } - } // namespace gpgmm diff --git a/src/gpgmm/common/BuddyMemoryAllocator.h b/src/gpgmm/common/BuddyMemoryAllocator.h index 62f28ca64..5d21530ad 100644 --- a/src/gpgmm/common/BuddyMemoryAllocator.h +++ b/src/gpgmm/common/BuddyMemoryAllocator.h @@ -53,7 +53,7 @@ namespace gpgmm { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(BuddyMemoryAllocator) uint64_t GetMemoryIndex(uint64_t offset) const; diff --git a/src/gpgmm/common/ConditionalMemoryAllocator.cpp b/src/gpgmm/common/ConditionalMemoryAllocator.cpp index 697c5f130..dab849ebe 100644 --- a/src/gpgmm/common/ConditionalMemoryAllocator.cpp +++ b/src/gpgmm/common/ConditionalMemoryAllocator.cpp @@ -52,10 +52,6 @@ namespace gpgmm { return result; } - const char* ConditionalMemoryAllocator::GetTypename() const { - return "ConditionalMemoryAllocator"; - } - MemoryAllocator* ConditionalMemoryAllocator::GetFirstAllocatorForTesting() const { return mFirstAllocator.get(); } diff --git a/src/gpgmm/common/ConditionalMemoryAllocator.h b/src/gpgmm/common/ConditionalMemoryAllocator.h index 18bbdbdbd..7e5666448 100644 --- a/src/gpgmm/common/ConditionalMemoryAllocator.h +++ b/src/gpgmm/common/ConditionalMemoryAllocator.h @@ -41,7 +41,7 @@ namespace gpgmm { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(ConditionalMemoryAllocator) std::unique_ptr mFirstAllocator; std::unique_ptr mSecondAllocator; diff --git a/src/gpgmm/common/DedicatedMemoryAllocator.cpp b/src/gpgmm/common/DedicatedMemoryAllocator.cpp index 8d157e056..863fb0792 100644 --- a/src/gpgmm/common/DedicatedMemoryAllocator.cpp +++ b/src/gpgmm/common/DedicatedMemoryAllocator.cpp @@ -80,8 +80,4 @@ namespace gpgmm { uint64_t DedicatedMemoryAllocator::GetMemoryAlignment() const { return mMemoryAlignment; } - - const char* DedicatedMemoryAllocator::GetTypename() const { - return "DedicatedMemoryAllocator"; - } } // namespace gpgmm diff --git a/src/gpgmm/common/DedicatedMemoryAllocator.h b/src/gpgmm/common/DedicatedMemoryAllocator.h index 30b100451..c1617cceb 100644 --- a/src/gpgmm/common/DedicatedMemoryAllocator.h +++ b/src/gpgmm/common/DedicatedMemoryAllocator.h @@ -38,7 +38,7 @@ namespace gpgmm { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(DedicatedMemoryAllocator) const uint64_t mMemoryAlignment; }; diff --git a/src/gpgmm/common/Memory.cpp b/src/gpgmm/common/Memory.cpp index 01ffedf5c..574538e7f 100644 --- a/src/gpgmm/common/Memory.cpp +++ b/src/gpgmm/common/Memory.cpp @@ -53,8 +53,4 @@ namespace gpgmm { return mSubAllocationRefs.Unref(); } - const char* MemoryBase::GetTypename() const { - return "Memory"; - } - } // namespace gpgmm diff --git a/src/gpgmm/common/Memory.h b/src/gpgmm/common/Memory.h index d9517d36a..d54c22324 100644 --- a/src/gpgmm/common/Memory.h +++ b/src/gpgmm/common/Memory.h @@ -38,7 +38,7 @@ namespace gpgmm { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(MemoryBase) RefCounted mSubAllocationRefs; diff --git a/src/gpgmm/common/MemoryAllocation.cpp b/src/gpgmm/common/MemoryAllocation.cpp index 4a7c95a30..e8b8dde20 100644 --- a/src/gpgmm/common/MemoryAllocation.cpp +++ b/src/gpgmm/common/MemoryAllocation.cpp @@ -134,8 +134,4 @@ namespace gpgmm { return mBlock; } - const char* MemoryAllocation::GetTypename() const { - return "Allocation"; - } - } // namespace gpgmm diff --git a/src/gpgmm/common/MemoryAllocation.h b/src/gpgmm/common/MemoryAllocation.h index 25b13e2b2..dd66f733c 100644 --- a/src/gpgmm/common/MemoryAllocation.h +++ b/src/gpgmm/common/MemoryAllocation.h @@ -99,7 +99,7 @@ namespace gpgmm { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(MemoryAllocation) MemoryBase* mMemory; uint64_t mOffset; // Offset always local to the memory. diff --git a/src/gpgmm/common/MemoryAllocator.cpp b/src/gpgmm/common/MemoryAllocator.cpp index c38ff08e5..86f94ccb1 100644 --- a/src/gpgmm/common/MemoryAllocator.cpp +++ b/src/gpgmm/common/MemoryAllocator.cpp @@ -156,10 +156,6 @@ namespace gpgmm { return mStats; } - const char* MemoryAllocator::GetTypename() const { - return "MemoryAllocator"; - } - bool MemoryAllocator::ValidateRequest(const MemoryAllocationRequest& request) const { ASSERT(request.SizeInBytes > 0 && request.Alignment > 0); diff --git a/src/gpgmm/common/MemoryAllocator.h b/src/gpgmm/common/MemoryAllocator.h index 96d0d05a2..562f6599f 100644 --- a/src/gpgmm/common/MemoryAllocator.h +++ b/src/gpgmm/common/MemoryAllocator.h @@ -264,7 +264,7 @@ namespace gpgmm { The type is used for profiling and debugging purposes only. */ - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(MemoryAllocator) /** \brief Checks if the request is valid. diff --git a/src/gpgmm/common/Object.h b/src/gpgmm/common/Object.h index fdfb2b394..74886aec3 100644 --- a/src/gpgmm/common/Object.h +++ b/src/gpgmm/common/Object.h @@ -28,6 +28,11 @@ namespace gpgmm { virtual const char* GetTypename() const = 0; }; +// Helper to provide ObjectBase-based object types the type name based on class name. +#define DEFINE_OBJECT_BASE_OVERRIDES(type) \ + inline const char* GetTypename() const override { \ + return #type; \ + } } // namespace gpgmm #endif // GPGMM_COMMON_OBJECT_H_ diff --git a/src/gpgmm/common/PooledMemoryAllocator.cpp b/src/gpgmm/common/PooledMemoryAllocator.cpp index dedfeaaad..2c7b64d6a 100644 --- a/src/gpgmm/common/PooledMemoryAllocator.cpp +++ b/src/gpgmm/common/PooledMemoryAllocator.cpp @@ -97,8 +97,4 @@ namespace gpgmm { return mMemoryAlignment; } - const char* PooledMemoryAllocator::GetTypename() const { - return "PooledMemoryAllocator"; - } - } // namespace gpgmm diff --git a/src/gpgmm/common/PooledMemoryAllocator.h b/src/gpgmm/common/PooledMemoryAllocator.h index ec46cc722..b4dd468e5 100644 --- a/src/gpgmm/common/PooledMemoryAllocator.h +++ b/src/gpgmm/common/PooledMemoryAllocator.h @@ -39,7 +39,7 @@ namespace gpgmm { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(PooledMemoryAllocator) std::unique_ptr mPool; uint64_t mMemoryAlignment; diff --git a/src/gpgmm/common/SegmentedMemoryAllocator.cpp b/src/gpgmm/common/SegmentedMemoryAllocator.cpp index 4a6160e8e..e23e710f1 100644 --- a/src/gpgmm/common/SegmentedMemoryAllocator.cpp +++ b/src/gpgmm/common/SegmentedMemoryAllocator.cpp @@ -207,8 +207,4 @@ namespace gpgmm { return std::distance(mFreeSegments.begin(), mFreeSegments.end()); } - const char* SegmentedMemoryAllocator::GetTypename() const { - return "SegmentedMemoryAllocator"; - } - } // namespace gpgmm diff --git a/src/gpgmm/common/SegmentedMemoryAllocator.h b/src/gpgmm/common/SegmentedMemoryAllocator.h index 6bce3897e..851bd0f45 100644 --- a/src/gpgmm/common/SegmentedMemoryAllocator.h +++ b/src/gpgmm/common/SegmentedMemoryAllocator.h @@ -49,7 +49,7 @@ namespace gpgmm { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(SegmentedMemoryAllocator) MemorySegment* GetOrCreateFreeSegment(uint64_t memorySize); diff --git a/src/gpgmm/common/SlabBlockAllocator.cpp b/src/gpgmm/common/SlabBlockAllocator.cpp index 66f5f207f..ae6454cb5 100644 --- a/src/gpgmm/common/SlabBlockAllocator.cpp +++ b/src/gpgmm/common/SlabBlockAllocator.cpp @@ -109,8 +109,4 @@ namespace gpgmm { return mBlockCount; } - const char* SlabBlockAllocator::GetTypename() const { - return "SlabBlockAllocator"; - } - } // namespace gpgmm diff --git a/src/gpgmm/common/SlabBlockAllocator.h b/src/gpgmm/common/SlabBlockAllocator.h index 70723adcf..6dcfae3c9 100644 --- a/src/gpgmm/common/SlabBlockAllocator.h +++ b/src/gpgmm/common/SlabBlockAllocator.h @@ -54,7 +54,7 @@ namespace gpgmm { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(SlabBlockAllocator) struct BlockList { SlabBlock* pHead = nullptr; // First free block in slab. diff --git a/src/gpgmm/common/SlabMemoryAllocator.cpp b/src/gpgmm/common/SlabMemoryAllocator.cpp index 6bfb87b68..5748ddc02 100644 --- a/src/gpgmm/common/SlabMemoryAllocator.cpp +++ b/src/gpgmm/common/SlabMemoryAllocator.cpp @@ -465,10 +465,6 @@ namespace gpgmm { return result; } - const char* SlabMemoryAllocator::GetTypename() const { - return "SlabMemoryAllocator"; - } - bool SlabMemoryAllocator::IsPrefetchCoverageBelowThreshold() const { if (mStats.PrefetchedMemoryMissesEliminated >= mStats.PrefetchedMemoryMisses) { return true; @@ -595,8 +591,4 @@ namespace gpgmm { return GetNextInChain()->GetMemorySize(); } - const char* SlabCacheAllocator::GetTypename() const { - return "SlabCacheAllocator"; - } - } // namespace gpgmm diff --git a/src/gpgmm/common/SlabMemoryAllocator.h b/src/gpgmm/common/SlabMemoryAllocator.h index e40f6e346..0e0f15751 100644 --- a/src/gpgmm/common/SlabMemoryAllocator.h +++ b/src/gpgmm/common/SlabMemoryAllocator.h @@ -63,7 +63,7 @@ namespace gpgmm { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(SlabMemoryAllocator) uint64_t ComputeSlabSize(uint64_t requestSize, uint64_t baseSlabSize, @@ -132,7 +132,7 @@ namespace gpgmm { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(SlabCacheAllocator) class SlabAllocatorCacheEntry : public NonCopyable { public: diff --git a/src/gpgmm/d3d12/DebugResourceAllocatorD3D12.cpp b/src/gpgmm/d3d12/DebugResourceAllocatorD3D12.cpp index d11219523..d146fa229 100644 --- a/src/gpgmm/d3d12/DebugResourceAllocatorD3D12.cpp +++ b/src/gpgmm/d3d12/DebugResourceAllocatorD3D12.cpp @@ -89,8 +89,4 @@ namespace gpgmm::d3d12 { entry->GetValue().GetAllocator()->DeallocateMemory(std::move(allocation)); } - const char* DebugResourceAllocator::GetTypename() const { - return "DebugResourceAllocator"; - } - } // namespace gpgmm::d3d12 diff --git a/src/gpgmm/d3d12/DebugResourceAllocatorD3D12.h b/src/gpgmm/d3d12/DebugResourceAllocatorD3D12.h index f6a3177c0..547541518 100644 --- a/src/gpgmm/d3d12/DebugResourceAllocatorD3D12.h +++ b/src/gpgmm/d3d12/DebugResourceAllocatorD3D12.h @@ -35,7 +35,7 @@ namespace gpgmm::d3d12 { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(DebugResourceAllocator) void DeallocateMemory(std::unique_ptr allocation) override; diff --git a/src/gpgmm/d3d12/HeapD3D12.cpp b/src/gpgmm/d3d12/HeapD3D12.cpp index b1b0070fd..0e1216eb3 100644 --- a/src/gpgmm/d3d12/HeapD3D12.cpp +++ b/src/gpgmm/d3d12/HeapD3D12.cpp @@ -204,10 +204,6 @@ namespace gpgmm::d3d12 { GPGMM_TRACE_EVENT_OBJECT_DESTROY(this); } - const char* Heap::GetTypename() const { - return "IHeap"; - } - uint64_t Heap::GetLastUsedFenceValue() const { return mLastUsedFenceValue; } diff --git a/src/gpgmm/d3d12/HeapD3D12.h b/src/gpgmm/d3d12/HeapD3D12.h index a79fe3b24..b0093a4e0 100644 --- a/src/gpgmm/d3d12/HeapD3D12.h +++ b/src/gpgmm/d3d12/HeapD3D12.h @@ -59,7 +59,7 @@ namespace gpgmm::d3d12 { bool isResidencyDisabled); // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(IHeap) HRESULT SetDebugNameImpl(LPCWSTR name) override; DXGI_MEMORY_SEGMENT_GROUP GetHeapSegment() const; diff --git a/src/gpgmm/d3d12/ResidencyManagerD3D12.cpp b/src/gpgmm/d3d12/ResidencyManagerD3D12.cpp index 9d6524e3e..2051bc77e 100644 --- a/src/gpgmm/d3d12/ResidencyManagerD3D12.cpp +++ b/src/gpgmm/d3d12/ResidencyManagerD3D12.cpp @@ -309,10 +309,6 @@ namespace gpgmm::d3d12 { } } - const char* ResidencyManager::GetTypename() const { - return "IResidencyManager"; - } - // Increments number of locks on a heap to ensure the heap remains resident. HRESULT ResidencyManager::LockHeap(IHeap* pHeap) { GPGMM_RETURN_IF_NULLPTR(pHeap); diff --git a/src/gpgmm/d3d12/ResidencyManagerD3D12.h b/src/gpgmm/d3d12/ResidencyManagerD3D12.h index 61cf84c3d..b5061f11f 100644 --- a/src/gpgmm/d3d12/ResidencyManagerD3D12.h +++ b/src/gpgmm/d3d12/ResidencyManagerD3D12.h @@ -99,7 +99,7 @@ namespace gpgmm::d3d12 { bool IsUMA() const; // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(IResidencyManager) using LRUCache = LinkedList; diff --git a/src/gpgmm/d3d12/ResourceAllocationD3D12.cpp b/src/gpgmm/d3d12/ResourceAllocationD3D12.cpp index b95c268d9..2d7423494 100644 --- a/src/gpgmm/d3d12/ResourceAllocationD3D12.cpp +++ b/src/gpgmm/d3d12/ResourceAllocationD3D12.cpp @@ -151,10 +151,6 @@ namespace gpgmm::d3d12 { return {GetSize(), GetAlignment(), static_cast(GetMethod())}; } - const char* ResourceAllocation::GetTypename() const { - return "IResourceAllocation"; - } - IHeap* ResourceAllocation::GetMemory() const { return static_cast(MemoryAllocation::GetMemory()); } diff --git a/src/gpgmm/d3d12/ResourceAllocationD3D12.h b/src/gpgmm/d3d12/ResourceAllocationD3D12.h index e4c5b202e..2180d24da 100644 --- a/src/gpgmm/d3d12/ResourceAllocationD3D12.h +++ b/src/gpgmm/d3d12/ResourceAllocationD3D12.h @@ -76,7 +76,7 @@ namespace gpgmm::d3d12 { void DeleteThis() override; // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(IResourceAllocation) ResidencyManager* const mResidencyManager; ComPtr mResource; diff --git a/src/gpgmm/d3d12/ResourceAllocatorD3D12.cpp b/src/gpgmm/d3d12/ResourceAllocatorD3D12.cpp index 8133e0ab3..b7776d498 100644 --- a/src/gpgmm/d3d12/ResourceAllocatorD3D12.cpp +++ b/src/gpgmm/d3d12/ResourceAllocatorD3D12.cpp @@ -834,10 +834,6 @@ namespace gpgmm::d3d12 { } } - const char* ResourceAllocator::GetTypename() const { - return "IResourceAllocator"; - } - HRESULT ResourceAllocator::ReleaseResourceHeaps(uint64_t bytesToRelease, uint64_t* pBytesReleased) { std::lock_guard lock(mMutex); diff --git a/src/gpgmm/d3d12/ResourceAllocatorD3D12.h b/src/gpgmm/d3d12/ResourceAllocatorD3D12.h index 87d447f98..c44bd648c 100644 --- a/src/gpgmm/d3d12/ResourceAllocatorD3D12.h +++ b/src/gpgmm/d3d12/ResourceAllocatorD3D12.h @@ -79,7 +79,7 @@ namespace gpgmm::d3d12 { friend ResourceAllocation; // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(IResourceAllocator) HRESULT CreateResourceInternal(const ALLOCATION_DESC& allocationDescriptor, const D3D12_RESOURCE_DESC& resourceDescriptor, diff --git a/src/gpgmm/d3d12/ResourceHeapAllocatorD3D12.cpp b/src/gpgmm/d3d12/ResourceHeapAllocatorD3D12.cpp index 1375773a2..dc9b2dced 100644 --- a/src/gpgmm/d3d12/ResourceHeapAllocatorD3D12.cpp +++ b/src/gpgmm/d3d12/ResourceHeapAllocatorD3D12.cpp @@ -98,10 +98,6 @@ namespace gpgmm::d3d12 { SafeRelease(allocation); } - const char* ResourceHeapAllocator::GetTypename() const { - return "ResourceHeapAllocator"; - } - CreateResourceHeapCallbackContext::CreateResourceHeapCallbackContext(ID3D12Device* device, D3D12_HEAP_DESC* heapDesc) : mDevice(device), mHeapDesc(heapDesc) { diff --git a/src/gpgmm/d3d12/ResourceHeapAllocatorD3D12.h b/src/gpgmm/d3d12/ResourceHeapAllocatorD3D12.h index ce3fce2ca..cd4c884b6 100644 --- a/src/gpgmm/d3d12/ResourceHeapAllocatorD3D12.h +++ b/src/gpgmm/d3d12/ResourceHeapAllocatorD3D12.h @@ -52,7 +52,7 @@ namespace gpgmm::d3d12 { private: // ObjectBase interface - const char* GetTypename() const override; + DEFINE_OBJECT_BASE_OVERRIDES(ResourceHeapAllocator) ResidencyManager* const mResidencyManager; ID3D12Device* const mDevice;