mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-06 18:44:06 +08:00
Add support for device specific extensions.
Change-Id: I3ffd125875067b00bc225556c09fbe2d02f11022 Signed-off-by: Zdunowski, Piotr <piotr.zdunowski@intel.com>
This commit is contained in:
committed by
sys_ocldev
parent
11a1b27399
commit
14824f1dff
@@ -159,6 +159,8 @@ void Device::initializeCaps() {
|
|||||||
simultaneousInterops = {0};
|
simultaneousInterops = {0};
|
||||||
appendOSExtensions(deviceExtensions);
|
appendOSExtensions(deviceExtensions);
|
||||||
|
|
||||||
|
deviceExtensions += hwHelper.getExtensions();
|
||||||
|
|
||||||
deviceInfo.deviceExtensions = deviceExtensions.c_str();
|
deviceInfo.deviceExtensions = deviceExtensions.c_str();
|
||||||
|
|
||||||
exposedBuiltinKernels = builtInKernels;
|
exposedBuiltinKernels = builtInKernels;
|
||||||
|
|||||||
@@ -14,6 +14,7 @@
|
|||||||
#include "CL/cl.h"
|
#include "CL/cl.h"
|
||||||
|
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
|
#include <string>
|
||||||
#include <type_traits>
|
#include <type_traits>
|
||||||
|
|
||||||
namespace OCLRT {
|
namespace OCLRT {
|
||||||
@@ -59,6 +60,7 @@ class HwHelper {
|
|||||||
virtual size_t getScratchSpaceOffsetFor64bit() = 0;
|
virtual size_t getScratchSpaceOffsetFor64bit() = 0;
|
||||||
virtual const std::vector<EngineType> getGpgpuEngineInstances() const = 0;
|
virtual const std::vector<EngineType> getGpgpuEngineInstances() const = 0;
|
||||||
virtual bool getEnableLocalMemory(const HardwareInfo &hwInfo) const = 0;
|
virtual bool getEnableLocalMemory(const HardwareInfo &hwInfo) const = 0;
|
||||||
|
virtual std::string getExtensions() const = 0;
|
||||||
|
|
||||||
static constexpr uint32_t lowPriorityGpgpuEngineIndex = 1;
|
static constexpr uint32_t lowPriorityGpgpuEngineIndex = 1;
|
||||||
|
|
||||||
@@ -146,6 +148,8 @@ class HwHelperHw : public HwHelper {
|
|||||||
|
|
||||||
bool getEnableLocalMemory(const HardwareInfo &hwInfo) const override;
|
bool getEnableLocalMemory(const HardwareInfo &hwInfo) const override;
|
||||||
|
|
||||||
|
std::string getExtensions() const override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
HwHelperHw() = default;
|
HwHelperHw() = default;
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -185,6 +185,11 @@ bool HwHelperHw<Family>::getEnableLocalMemory(const HardwareInfo &hwInfo) const
|
|||||||
return OSInterface::osEnableLocalMemory && isLocalMemoryEnabled(hwInfo);
|
return OSInterface::osEnableLocalMemory && isLocalMemoryEnabled(hwInfo);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template <typename Family>
|
||||||
|
std::string HwHelperHw<Family>::getExtensions() const {
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
|
||||||
template <typename Family>
|
template <typename Family>
|
||||||
typename Family::PIPE_CONTROL *PipeControlHelper<Family>::obtainPipeControlAndProgramPostSyncOperation(LinearStream *commandStream,
|
typename Family::PIPE_CONTROL *PipeControlHelper<Family>::obtainPipeControlAndProgramPostSyncOperation(LinearStream *commandStream,
|
||||||
POST_SYNC_OPERATION operation,
|
POST_SYNC_OPERATION operation,
|
||||||
|
|||||||
Reference in New Issue
Block a user