mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-16 16:37:08 +00:00
Memory manager: buffer uploads (D3D) - Part 1
Manages a single persistently mapped GPU heap which is sub-allocated inside of ring-buffer for uploads. To handle larger buffers without additional unused heaps, ring buffers are created on-demand. BUG=dawn:28 TEST=dawn_unittests Change-Id: Ifc5a1b06baf8633f1e133245ac1ee76275431cc5 Reviewed-on: https://dawn-review.googlesource.com/c/3160 Commit-Queue: Bryan Bernhart <bryan.bernhart@intel.com> Reviewed-by: Kai Ninomiya <kainino@chromium.org>
This commit is contained in:
committed by
Commit Bot service account
parent
79ff8bead9
commit
74e95fff4a
@@ -110,6 +110,7 @@ class SerialStorage {
|
||||
void ClearUpTo(Serial serial);
|
||||
|
||||
Serial FirstSerial() const;
|
||||
Serial LastSerial() const;
|
||||
|
||||
protected:
|
||||
// Returns the first StorageIterator that a serial bigger than serial.
|
||||
@@ -162,6 +163,12 @@ Serial SerialStorage<Derived>::FirstSerial() const {
|
||||
return mStorage.begin()->first;
|
||||
}
|
||||
|
||||
template <typename Derived>
|
||||
Serial SerialStorage<Derived>::LastSerial() const {
|
||||
DAWN_ASSERT(!Empty());
|
||||
return mStorage.back().first;
|
||||
}
|
||||
|
||||
template <typename Derived>
|
||||
typename SerialStorage<Derived>::ConstStorageIterator SerialStorage<Derived>::FindUpTo(
|
||||
Serial serial) const {
|
||||
|
||||
Reference in New Issue
Block a user