mirror of
https://github.com/intel/compute-runtime.git
synced 2025-09-10 12:53:42 +08:00
Move ClCoreHelper ownership to RootDeviceEnvironment 1/n
Related-To: NEO-6853 Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com> Use RootDeviceEnvironment getHelper<ClCoreHelper> for - requiresNonAuxMode - requiresAuxResolves
This commit is contained in:

committed by
Compute-Runtime-Automation

parent
05aea7ebc8
commit
1d4240a0c8
@ -9,6 +9,8 @@
|
||||
|
||||
#include "shared/source/built_ins/sip.h"
|
||||
|
||||
#include "opencl/source/helpers/cl_hw_helper.h"
|
||||
|
||||
#include "gtest/gtest.h"
|
||||
|
||||
namespace NEO {
|
||||
@ -42,6 +44,10 @@ MockDevice *ClDeviceFixture::createWithUsDeviceId(unsigned short usDeviceId) {
|
||||
return MockDevice::createWithNewExecutionEnvironment<MockDevice>(&hardwareInfo, rootDeviceIndex);
|
||||
}
|
||||
|
||||
const RootDeviceEnvironment &ClDeviceFixture::getRootDeviceEnvironment() const {
|
||||
return pClDevice->getRootDeviceEnvironment();
|
||||
}
|
||||
|
||||
template <typename HelperType>
|
||||
HelperType &ClDeviceFixture::getHelper() const {
|
||||
auto &helper = pClDevice->getRootDeviceEnvironment().getHelper<HelperType>();
|
||||
@ -50,5 +56,5 @@ HelperType &ClDeviceFixture::getHelper() const {
|
||||
|
||||
template ProductHelper &ClDeviceFixture::getHelper() const;
|
||||
template CoreHelper &ClDeviceFixture::getHelper() const;
|
||||
|
||||
template ClCoreHelper &ClDeviceFixture::getHelper() const;
|
||||
} // namespace NEO
|
||||
|
@ -31,6 +31,8 @@ struct ClDeviceFixture {
|
||||
OsContext *osContext = nullptr;
|
||||
const uint32_t rootDeviceIndex = 0u;
|
||||
MockClExecutionEnvironment *pClExecutionEnvironment = nullptr;
|
||||
|
||||
const RootDeviceEnvironment &getRootDeviceEnvironment() const;
|
||||
};
|
||||
|
||||
} // namespace NEO
|
||||
|
Reference in New Issue
Block a user