mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 06:49:52 +08:00
Add AssignBCSAtEnqueue debug flag
Signed-off-by: Lukasz Jobczyk <lukasz.jobczyk@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
05bf7a4315
commit
3c30e1b02b
@@ -179,8 +179,17 @@ CommandStreamReceiver &CommandQueue::selectCsrForBuiltinOperation(const CsrSelec
|
||||
case TransferDirection::HostToLocal:
|
||||
case TransferDirection::LocalToHost: {
|
||||
preferBcs = true;
|
||||
preferredBcsEngineType = EngineHelpers::getBcsEngineType(device->getHardwareInfo(), device->getDeviceBitfield(),
|
||||
device->getSelectorCopyEngine(), false);
|
||||
|
||||
auto preferredBCSType = true;
|
||||
|
||||
if (DebugManager.flags.AssignBCSAtEnqueue.get() != -1) {
|
||||
preferredBCSType = DebugManager.flags.AssignBCSAtEnqueue.get();
|
||||
}
|
||||
|
||||
if (preferredBCSType) {
|
||||
preferredBcsEngineType = EngineHelpers::getBcsEngineType(device->getHardwareInfo(), device->getDeviceBitfield(),
|
||||
device->getSelectorCopyEngine(), false);
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
@@ -189,7 +198,16 @@ CommandStreamReceiver &CommandQueue::selectCsrForBuiltinOperation(const CsrSelec
|
||||
|
||||
CommandStreamReceiver *selectedCsr = nullptr;
|
||||
if (preferBcs) {
|
||||
selectedCsr = getBcsCommandStreamReceiver(preferredBcsEngineType);
|
||||
auto assignBCS = true;
|
||||
|
||||
if (DebugManager.flags.AssignBCSAtEnqueue.get() != -1) {
|
||||
assignBCS = DebugManager.flags.AssignBCSAtEnqueue.get();
|
||||
}
|
||||
|
||||
if (assignBCS) {
|
||||
selectedCsr = getBcsCommandStreamReceiver(preferredBcsEngineType);
|
||||
}
|
||||
|
||||
if (selectedCsr == nullptr && !bcsEngineTypes.empty()) {
|
||||
selectedCsr = getBcsCommandStreamReceiver(bcsEngineTypes[0]);
|
||||
}
|
||||
|
||||
@@ -1069,6 +1069,7 @@ template <typename GfxFamily>
|
||||
template <uint32_t cmdType>
|
||||
void CommandQueueHw<GfxFamily>::enqueueBlit(const MultiDispatchInfo &multiDispatchInfo, cl_uint numEventsInWaitList, const cl_event *eventWaitList, cl_event *event, bool blocking, CommandStreamReceiver &bcsCsr) {
|
||||
auto commandStreamReceiverOwnership = getGpgpuCommandStreamReceiver().obtainUniqueOwnership();
|
||||
auto bcsCommandStreamReceiverOwnership = bcsCsr.obtainUniqueOwnership();
|
||||
|
||||
EventsRequest eventsRequest(numEventsInWaitList, eventWaitList, event);
|
||||
EventBuilder eventBuilder;
|
||||
@@ -1154,6 +1155,7 @@ void CommandQueueHw<GfxFamily>::enqueueBlit(const MultiDispatchInfo &multiDispat
|
||||
timestampPacketDependencies.moveNodesToNewContainer(*deferredTimestampPackets);
|
||||
|
||||
queueOwnership.unlock();
|
||||
bcsCommandStreamReceiverOwnership.unlock();
|
||||
commandStreamReceiverOwnership.unlock();
|
||||
|
||||
if (blocking) {
|
||||
|
||||
Reference in New Issue
Block a user