Updated single
This commit is contained in:
parent
e481c3afac
commit
d9a6abb918
1 changed files with 12 additions and 6 deletions
|
|
@ -10,6 +10,12 @@ static const char* KOMPUTE_LOG_TAG = "KomputeLog";
|
|||
|
||||
#include <vulkan/vulkan.hpp>
|
||||
|
||||
// Typedefs to simplify interaction with core types
|
||||
namespace kp {
|
||||
typedef std::array<uint32_t, 3> Workgroup;
|
||||
typedef std::vector<float> Constants;
|
||||
}
|
||||
|
||||
// Must be after vulkan is included
|
||||
#ifndef KOMPUTE_VK_API_VERSION
|
||||
#ifndef KOMPUTE_VK_API_MAJOR_VERSION
|
||||
|
|
@ -1739,7 +1745,7 @@ class OpAlgoBase : public OpBase
|
|||
std::shared_ptr<vk::Device> device,
|
||||
std::shared_ptr<vk::CommandBuffer> commandBuffer,
|
||||
std::vector<std::shared_ptr<Tensor>>& tensors,
|
||||
const std::array<uint32_t, 3>& komputeWorkgroup = {},
|
||||
const Workgroup& komputeWorkgroup = {},
|
||||
const std::vector<float>& specializationConstants = {});
|
||||
|
||||
/**
|
||||
|
|
@ -1759,7 +1765,7 @@ class OpAlgoBase : public OpBase
|
|||
std::shared_ptr<vk::CommandBuffer> commandBuffer,
|
||||
std::vector<std::shared_ptr<Tensor>>& tensors,
|
||||
std::string shaderFilePath,
|
||||
const std::array<uint32_t, 3>& komputeWorkgroup = {},
|
||||
const Workgroup& komputeWorkgroup = {},
|
||||
const std::vector<float>& specializationConstants = {});
|
||||
|
||||
/**
|
||||
|
|
@ -1778,7 +1784,7 @@ class OpAlgoBase : public OpBase
|
|||
std::shared_ptr<vk::CommandBuffer> commandBuffer,
|
||||
std::vector<std::shared_ptr<Tensor>>& tensors,
|
||||
const std::vector<char>& shaderDataRaw,
|
||||
const std::array<uint32_t, 3>& komputeWorkgroup = {},
|
||||
const Workgroup& komputeWorkgroup = {},
|
||||
const std::vector<float>& specializationConstants = {});
|
||||
|
||||
/**
|
||||
|
|
@ -1826,7 +1832,7 @@ class OpAlgoBase : public OpBase
|
|||
|
||||
// -------------- ALWAYS OWNED RESOURCES
|
||||
|
||||
std::array<uint32_t, 3> mKomputeWorkgroup;
|
||||
Workgroup mKomputeWorkgroup;
|
||||
|
||||
std::string mShaderFilePath; ///< Optional member variable which can be provided for the OpAlgoBase to find the data automatically and load for processing
|
||||
std::vector<char> mShaderDataRaw; ///< Optional member variable which can be provided to contain either the raw shader content or the spirv binary content
|
||||
|
|
@ -1869,7 +1875,7 @@ class OpAlgoLhsRhsOut : public OpAlgoBase
|
|||
std::shared_ptr<vk::Device> device,
|
||||
std::shared_ptr<vk::CommandBuffer> commandBuffer,
|
||||
std::vector<std::shared_ptr<Tensor>> tensors,
|
||||
const std::array<uint32_t, 3>& komputeWorkgroup = {});
|
||||
const Workgroup& komputeWorkgroup = {});
|
||||
|
||||
/**
|
||||
* Default destructor, which is in charge of destroying the algorithm
|
||||
|
|
@ -1948,7 +1954,7 @@ class OpMult : public OpAlgoBase
|
|||
std::shared_ptr<vk::Device> device,
|
||||
std::shared_ptr<vk::CommandBuffer> commandBuffer,
|
||||
std::vector<std::shared_ptr<Tensor>> tensors,
|
||||
const std::array<uint32_t, 3>& komputeWorkgroup = {})
|
||||
const Workgroup& komputeWorkgroup = {})
|
||||
: OpAlgoBase(physicalDevice, device, commandBuffer, tensors, "", komputeWorkgroup)
|
||||
{
|
||||
SPDLOG_DEBUG("Kompute OpMult constructor with params");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue