#ifndef LIBANGLE_RENDERER_VULKAN_SUBALLOCATION_H_
#define LIBANGLE_RENDERER_VULKAN_SUBALLOCATION_H_
#include "common/SimpleMutex.h"
#include "common/debug.h"
#include "libANGLE/angletypes.h"
#include "libANGLE/renderer/serial_utils.h"
#include "libANGLE/renderer/vulkan/vk_cache_utils.h"
#include "libANGLE/renderer/vulkan/vk_resource.h"
#include "libANGLE/renderer/vulkan/vk_utils.h"
#include "libANGLE/renderer/vulkan/vk_wrapper.h"
namespace rx
{
enum class MemoryAllocationType;
namespace vk
{
class Context;
class BufferBlock final : angle::NonCopyable
{ … };
BufferBlockPointer;
BufferBlockPointerVector;
class BufferBlockGarbageList final : angle::NonCopyable
{ … };
class BufferSuballocation final : angle::NonCopyable
{ … };
class BufferSuballocationGarbage
{ … };
ANGLE_INLINE VkMemoryPropertyFlags BufferBlock::getMemoryPropertyFlags() const
{ … }
ANGLE_INLINE VkDeviceSize BufferBlock::getMemorySize() const
{ … }
ANGLE_INLINE VkBool32 BufferBlock::isEmpty()
{ … }
ANGLE_INLINE bool BufferBlock::isHostVisible() const
{ … }
ANGLE_INLINE bool BufferBlock::isCoherent() const
{ … }
ANGLE_INLINE bool BufferBlock::isCached() const
{ … }
ANGLE_INLINE bool BufferBlock::isMapped() const
{ … }
ANGLE_INLINE uint8_t *BufferBlock::getMappedMemory() const
{ … }
ANGLE_INLINE BufferSuballocation::BufferSuballocation()
: … { … }
ANGLE_INLINE BufferSuballocation::BufferSuballocation(BufferSuballocation &&other)
: … { … }
ANGLE_INLINE BufferSuballocation &BufferSuballocation::operator=(BufferSuballocation &&other)
{ … }
ANGLE_INLINE bool BufferSuballocation::valid() const
{ … }
ANGLE_INLINE void BufferSuballocation::destroy(Renderer *renderer)
{ … }
ANGLE_INLINE void BufferSuballocation::init(BufferBlock *block,
VmaVirtualAllocation allocation,
VkDeviceSize offset,
VkDeviceSize size)
{ … }
ANGLE_INLINE void BufferSuballocation::initWithEntireBuffer(
Context *context,
Buffer &buffer,
MemoryAllocationType memoryAllocationType,
uint32_t memoryTypeIndex,
DeviceMemory &deviceMemory,
VkMemoryPropertyFlags memoryPropertyFlags,
VkDeviceSize size,
VkDeviceSize allocatedBufferSize)
{ … }
ANGLE_INLINE const Buffer &BufferSuballocation::getBuffer() const
{ … }
ANGLE_INLINE VkDeviceSize BufferSuballocation::getSize() const
{ … }
ANGLE_INLINE const DeviceMemory &BufferSuballocation::getDeviceMemory() const
{ … }
ANGLE_INLINE VkMemoryMapFlags BufferSuballocation::getMemoryPropertyFlags() const
{ … }
ANGLE_INLINE bool BufferSuballocation::isHostVisible() const
{ … }
ANGLE_INLINE bool BufferSuballocation::isCoherent() const
{ … }
ANGLE_INLINE bool BufferSuballocation::isCached() const
{ … }
ANGLE_INLINE bool BufferSuballocation::isMapped() const
{ … }
ANGLE_INLINE uint8_t *BufferSuballocation::getMappedMemory() const
{ … }
ANGLE_INLINE void BufferSuballocation::flush(const VkDevice &device)
{ … }
ANGLE_INLINE void BufferSuballocation::invalidate(const VkDevice &device)
{ … }
ANGLE_INLINE VkDeviceSize BufferSuballocation::getOffset() const
{ … }
ANGLE_INLINE void BufferSuballocation::setOffsetAndSize(VkDeviceSize offset, VkDeviceSize size)
{ … }
ANGLE_INLINE uint8_t *BufferSuballocation::getBlockMemory() const
{ … }
ANGLE_INLINE VkDeviceSize BufferSuballocation::getBlockMemorySize() const
{ … }
ANGLE_INLINE BufferSerial BufferSuballocation::getBlockSerial() const
{ … }
}
}
#endif