mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-04 23:56:39 +08:00
refactor: isStateless on init
Related-to: NEO-12938 Signed-off-by: Damian Tomczak <damian.tomczak@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
c72ebb263d
commit
e495b2238a
@@ -133,6 +133,8 @@ CommandQueue::CommandQueue(Context *context, ClDevice *device, const cl_queue_pr
|
||||
|
||||
this->heaplessModeEnabled = compilerProductHelper.isHeaplessModeEnabled();
|
||||
this->heaplessStateInitEnabled = compilerProductHelper.isHeaplessStateInitEnabled(this->heaplessModeEnabled);
|
||||
|
||||
this->isForceStateless = compilerProductHelper.isForceToStatelessRequired();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -486,6 +486,7 @@ class CommandQueue : public BaseObject<_cl_command_queue> {
|
||||
bool gpgpuCsrClientRegistered = false;
|
||||
bool heaplessModeEnabled = false;
|
||||
bool heaplessStateInitEnabled = false;
|
||||
bool isForceStateless = false;
|
||||
};
|
||||
|
||||
template <typename PtrType>
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
|
||||
#pragma once
|
||||
#include "shared/source/command_stream/command_stream_receiver.h"
|
||||
#include "shared/source/helpers/compiler_product_helper.h"
|
||||
|
||||
#include "opencl/source/command_queue/command_queue_hw.h"
|
||||
#include "opencl/source/mem_obj/buffer.h"
|
||||
@@ -35,7 +34,7 @@ cl_int CommandQueueHw<GfxFamily>::enqueueCopyBufferRect(
|
||||
CsrSelectionArgs csrSelectionArgs{cmdType, srcBuffer, dstBuffer, device->getRootDeviceIndex(), region};
|
||||
CommandStreamReceiver &csr = selectCsrForBuiltinOperation(csrSelectionArgs);
|
||||
|
||||
bool isStateless = device->getCompilerProductHelper().isForceToStatelessRequired();
|
||||
bool isStateless = isForceStateless;
|
||||
if (std::max(srcBuffer->getSize(), dstBuffer->getSize()) >= 4ull * MemoryConstants::gigaByte) {
|
||||
isStateless = true;
|
||||
}
|
||||
|
||||
@@ -6,8 +6,6 @@
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
#include "shared/source/helpers/compiler_product_helper.h"
|
||||
|
||||
#include "opencl/source/command_queue/command_queue_hw.h"
|
||||
#include "opencl/source/helpers/mipmap.h"
|
||||
#include "opencl/source/mem_obj/buffer.h"
|
||||
@@ -27,7 +25,7 @@ cl_int CommandQueueHw<GfxFamily>::enqueueCopyImageToBuffer(
|
||||
const cl_event *eventWaitList,
|
||||
cl_event *event) {
|
||||
|
||||
bool isStateless = device->getCompilerProductHelper().isForceToStatelessRequired();
|
||||
bool isStateless = isForceStateless;
|
||||
if (dstBuffer->getSize() >= 4ull * MemoryConstants::gigaByte) {
|
||||
isStateless = true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user