diff --git a/runtime/api/api.cpp b/runtime/api/api.cpp index a52713d515..2bb1028bb5 100644 --- a/runtime/api/api.cpp +++ b/runtime/api/api.cpp @@ -4865,7 +4865,7 @@ CL_API_ENTRY cl_int CL_API_CALL clEnqueueVerifyMemoryINTEL(cl_command_queue comm return retVal; } - auto &csr = pCommandQueue->getCommandStreamReceiver(); + auto &csr = pCommandQueue->getGpgpuCommandStreamReceiver(); retVal = csr.expectMemory(allocationPtr, expectedData, sizeOfComparison, comparisonMode); return retVal; } diff --git a/runtime/command_queue/command_queue.cpp b/runtime/command_queue/command_queue.cpp index 7b0617643a..8069ba8e06 100644 --- a/runtime/command_queue/command_queue.cpp +++ b/runtime/command_queue/command_queue.cpp @@ -67,8 +67,8 @@ CommandQueue::CommandQueue(Context *context, Device *deviceId, const cl_queue_pr flushStamp.reset(new FlushStampTracker(true)); if (device) { - engine = &device->getDefaultEngine(); - if (getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + gpgpuEngine = &device->getDefaultEngine(); + if (getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { timestampPacketContainer = std::make_unique(); } } @@ -83,7 +83,7 @@ CommandQueue::~CommandQueue() { } if (device) { - auto storageForAllocation = getCommandStreamReceiver().getInternalAllocationStorage(); + auto storageForAllocation = getGpgpuCommandStreamReceiver().getInternalAllocationStorage(); if (commandStream) { storageForAllocation->storeAllocation(std::unique_ptr(commandStream->getGraphicsAllocation()), REUSABLE_ALLOCATION); @@ -103,8 +103,8 @@ CommandQueue::~CommandQueue() { } } -CommandStreamReceiver &CommandQueue::getCommandStreamReceiver() const { - return *engine->commandStreamReceiver; +CommandStreamReceiver &CommandQueue::getGpgpuCommandStreamReceiver() const { + return *gpgpuEngine->commandStreamReceiver; } uint32_t CommandQueue::getHwTag() const { @@ -113,7 +113,7 @@ uint32_t CommandQueue::getHwTag() const { } volatile uint32_t *CommandQueue::getHwTagAddress() const { - return getCommandStreamReceiver().getTagAddress(); + return getGpgpuCommandStreamReceiver().getTagAddress(); } bool CommandQueue::isCompleted(uint32_t taskCount) const { @@ -130,12 +130,13 @@ void CommandQueue::waitUntilComplete(uint32_t taskCountToWait, FlushStamp flushS bool forcePowerSavingMode = this->throttle == QueueThrottle::LOW; - getCommandStreamReceiver().waitForTaskCountWithKmdNotifyFallback(taskCountToWait, flushStampToWait, useQuickKmdSleep, forcePowerSavingMode); + getGpgpuCommandStreamReceiver().waitForTaskCountWithKmdNotifyFallback(taskCountToWait, flushStampToWait, + useQuickKmdSleep, forcePowerSavingMode); DEBUG_BREAK_IF(getHwTag() < taskCountToWait); latestTaskCountWaited = taskCountToWait; - getCommandStreamReceiver().waitForTaskCountAndCleanAllocationList(taskCountToWait, TEMPORARY_ALLOCATION); + getGpgpuCommandStreamReceiver().waitForTaskCountAndCleanAllocationList(taskCountToWait, TEMPORARY_ALLOCATION); WAIT_LEAVE() } @@ -160,7 +161,7 @@ bool CommandQueue::isQueueBlocked() { //at this point we may reset queue TaskCount, since all command previous to this were aborted taskCount = 0; flushStamp->setStamp(0); - taskLevel = getCommandStreamReceiver().peekTaskLevel(); + taskLevel = getGpgpuCommandStreamReceiver().peekTaskLevel(); } DebugManager.log(DebugManager.flags.EventsDebugEnable.get(), "isQueueBlocked taskLevel change from", taskLevel, "to new from virtualEvent", this->virtualEvent, "new tasklevel", this->virtualEvent->taskLevel.load()); @@ -202,7 +203,7 @@ LinearStream &CommandQueue::getCS(size_t minRequiredSize) { minRequiredSize += CSRequirements::minCommandQueueCommandStreamSize; constexpr static auto additionalAllocationSize = CSRequirements::minCommandQueueCommandStreamSize + CSRequirements::csOverfetchSize; - getCommandStreamReceiver().ensureCommandBufferAllocation(*commandStream, minRequiredSize, additionalAllocationSize); + getGpgpuCommandStreamReceiver().ensureCommandBufferAllocation(*commandStream, minRequiredSize, additionalAllocationSize); return *commandStream; } @@ -481,7 +482,7 @@ void CommandQueue::enqueueBlockedMapUnmapOperation(const cl_event *eventWaitList } //store task data in event - auto cmd = std::unique_ptr(new CommandMapUnmap(opType, *memObj, copySize, copyOffset, readOnly, getCommandStreamReceiver(), *this)); + auto cmd = std::unique_ptr(new CommandMapUnmap(opType, *memObj, copySize, copyOffset, readOnly, getGpgpuCommandStreamReceiver(), *this)); eventBuilder->getEvent()->setCommand(std::move(cmd)); //bind output event with input events @@ -496,10 +497,10 @@ void CommandQueue::enqueueBlockedMapUnmapOperation(const cl_event *eventWaitList } bool CommandQueue::setupDebugSurface(Kernel *kernel) { - auto debugSurface = getCommandStreamReceiver().getDebugSurfaceAllocation(); + auto debugSurface = getGpgpuCommandStreamReceiver().getDebugSurfaceAllocation(); if (!debugSurface) { - debugSurface = getCommandStreamReceiver().allocateDebugSurface(SipKernel::maxDbgSurfaceSize); + debugSurface = getGpgpuCommandStreamReceiver().allocateDebugSurface(SipKernel::maxDbgSurfaceSize); } DEBUG_BREAK_IF(!kernel->requiresSshForBuffers()); @@ -513,19 +514,19 @@ bool CommandQueue::setupDebugSurface(Kernel *kernel) { } IndirectHeap &CommandQueue::getIndirectHeap(IndirectHeap::Type heapType, size_t minRequiredSize) { - return getCommandStreamReceiver().getIndirectHeap(heapType, minRequiredSize); + return getGpgpuCommandStreamReceiver().getIndirectHeap(heapType, minRequiredSize); } void CommandQueue::allocateHeapMemory(IndirectHeap::Type heapType, size_t minRequiredSize, IndirectHeap *&indirectHeap) { - getCommandStreamReceiver().allocateHeapMemory(heapType, minRequiredSize, indirectHeap); + getGpgpuCommandStreamReceiver().allocateHeapMemory(heapType, minRequiredSize, indirectHeap); } void CommandQueue::releaseIndirectHeap(IndirectHeap::Type heapType) { - getCommandStreamReceiver().releaseIndirectHeap(heapType); + getGpgpuCommandStreamReceiver().releaseIndirectHeap(heapType); } void CommandQueue::obtainNewTimestampPacketNodes(size_t numberOfNodes, TimestampPacketContainer &previousNodes, bool clearAllDependencies) { - auto allocator = getCommandStreamReceiver().getTimestampPacketAllocator(); + auto allocator = getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(); previousNodes.swapNodes(*timestampPacketContainer); previousNodes.resolveDependencies(clearAllDependencies); diff --git a/runtime/command_queue/command_queue.h b/runtime/command_queue/command_queue.h index e15efc0a24..0a4b84cae0 100644 --- a/runtime/command_queue/command_queue.h +++ b/runtime/command_queue/command_queue.h @@ -334,11 +334,11 @@ class CommandQueue : public BaseObject<_cl_command_queue> { cl_uint numEventsInWaitList, const cl_event *eventWaitList); - CommandStreamReceiver &getCommandStreamReceiver() const; + CommandStreamReceiver &getGpgpuCommandStreamReceiver() const; Device &getDevice() const { return *device; } Context &getContext() const { return *context; } Context *getContextPtr() const { return context; } - EngineControl &getEngine() const { return *engine; } + EngineControl &getGpgpuEngine() const { return *gpgpuEngine; } MOCKABLE_VIRTUAL LinearStream &getCS(size_t minRequiredSize); IndirectHeap &getIndirectHeap(IndirectHeap::Type heapType, @@ -439,7 +439,7 @@ class CommandQueue : public BaseObject<_cl_command_queue> { Context *context = nullptr; Device *device = nullptr; - EngineControl *engine = nullptr; + EngineControl *gpgpuEngine = nullptr; cl_command_queue_properties commandQueueProperties = 0; diff --git a/runtime/command_queue/command_queue_hw.h b/runtime/command_queue/command_queue_hw.h index 63f3e27b04..8800149126 100644 --- a/runtime/command_queue/command_queue_hw.h +++ b/runtime/command_queue/command_queue_hw.h @@ -36,7 +36,7 @@ class CommandQueueHw : public CommandQueue { if (clPriority & static_cast(CL_QUEUE_PRIORITY_LOW_KHR)) { priority = QueuePriority::LOW; - this->engine = &device->getEngine(aub_stream::ENGINE_RCS, true); + this->gpgpuEngine = &device->getEngine(aub_stream::ENGINE_RCS, true); } else if (clPriority & static_cast(CL_QUEUE_PRIORITY_MED_KHR)) { priority = QueuePriority::MEDIUM; } else if (clPriority & static_cast(CL_QUEUE_PRIORITY_HIGH_KHR)) { @@ -54,8 +54,8 @@ class CommandQueueHw : public CommandQueue { } if (getCmdQueueProperties(properties, CL_QUEUE_PROPERTIES) & static_cast(CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE)) { - getCommandStreamReceiver().overrideDispatchPolicy(DispatchMode::BatchedDispatch); - getCommandStreamReceiver().enableNTo1SubmissionModel(); + getGpgpuCommandStreamReceiver().overrideDispatchPolicy(DispatchMode::BatchedDispatch); + getGpgpuCommandStreamReceiver().enableNTo1SubmissionModel(); } } diff --git a/runtime/command_queue/cpu_data_transfer_handler.cpp b/runtime/command_queue/cpu_data_transfer_handler.cpp index a7123b8a3b..d00adbd6d8 100644 --- a/runtime/command_queue/cpu_data_transfer_handler.cpp +++ b/runtime/command_queue/cpu_data_transfer_handler.cpp @@ -51,7 +51,7 @@ void *CommandQueue::cpuDataTransferHandler(TransferProperties &transferPropertie *eventsRequest.outEvent = outEventObj; } - auto commandStreamReceieverOwnership = getCommandStreamReceiver().obtainUniqueOwnership(); + auto commandStreamReceieverOwnership = getGpgpuCommandStreamReceiver().obtainUniqueOwnership(); TakeOwnershipWrapper queueOwnership(*this); auto blockQueue = false; diff --git a/runtime/command_queue/enqueue_common.h b/runtime/command_queue/enqueue_common.h index 7c144a3f1e..4c2e21e9fd 100644 --- a/runtime/command_queue/enqueue_common.h +++ b/runtime/command_queue/enqueue_common.h @@ -143,7 +143,7 @@ void CommandQueueHw::enqueueHandler(Surface **surfacesForResidency, TagNode *hwTimeStamps = nullptr; - auto commandStreamRecieverOwnership = getCommandStreamReceiver().obtainUniqueOwnership(); + auto commandStreamRecieverOwnership = getGpgpuCommandStreamReceiver().obtainUniqueOwnership(); TimeStampData queueTimeStamp; if (isProfilingEnabled() && event) { @@ -186,7 +186,7 @@ void CommandQueueHw::enqueueHandler(Surface **surfacesForResidency, enqueueHandlerHook(commandType, multiDispatchInfo); if (DebugManager.flags.AUBDumpSubCaptureMode.get()) { - auto status = getCommandStreamReceiver().checkAndActivateAubSubCapture(multiDispatchInfo); + auto status = getGpgpuCommandStreamReceiver().checkAndActivateAubSubCapture(multiDispatchInfo); if (!status.isActive) { // make each enqueue blocking when subcapture is not active to split batch buffer blocking = true; @@ -196,10 +196,10 @@ void CommandQueueHw::enqueueHandler(Surface **surfacesForResidency, } } - if (getCommandStreamReceiver().getType() > CommandStreamReceiverType::CSR_HW) { + if (getGpgpuCommandStreamReceiver().getType() > CommandStreamReceiverType::CSR_HW) { for (auto &dispatchInfo : multiDispatchInfo) { auto kernelName = dispatchInfo.getKernel()->getKernelInfo().name; - getCommandStreamReceiver().addAubComment(kernelName.c_str()); + getGpgpuCommandStreamReceiver().addAubComment(kernelName.c_str()); } } @@ -211,8 +211,8 @@ void CommandQueueHw::enqueueHandler(Surface **surfacesForResidency, EventsRequest eventsRequest(numEventsInWaitList, eventWaitList, event); CsrDependencies csrDeps; - if (getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { - csrDeps.fillFromEventsRequestAndMakeResident(eventsRequest, getCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); + if (getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + csrDeps.fillFromEventsRequestAndMakeResident(eventsRequest, getGpgpuCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); size_t nodesCount = 0u; if (blitEnqueue || isCacheFlushCommand(commandType)) { @@ -231,7 +231,7 @@ void CommandQueueHw::enqueueHandler(Surface **surfacesForResidency, blitEnqueue, multiDispatchInfo, surfacesForResidency, numSurfaceForResidency); auto commandStreamStart = commandStream.getUsed(); - if (eventBuilder.getEvent() && getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + if (eventBuilder.getEvent() && getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { eventBuilder.getEvent()->addTimestampPacketNodes(*timestampPacketContainer); } @@ -245,9 +245,9 @@ void CommandQueueHw::enqueueHandler(Surface **surfacesForResidency, previousTimestampPacketNodes, preemption); } else if (isCacheFlushCommand(commandType)) { processDispatchForCacheFlush(surfacesForResidency, numSurfaceForResidency, &commandStream, csrDeps); - } else if (getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + } else if (getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { if (CL_COMMAND_BARRIER == commandType) { - getCommandStreamReceiver().requestStallingPipeControlOnNextFlush(); + getGpgpuCommandStreamReceiver().requestStallingPipeControlOnNextFlush(); } for (size_t i = 0; i < eventsRequest.numEventsInWaitList; i++) { @@ -288,7 +288,7 @@ void CommandQueueHw::enqueueHandler(Surface **surfacesForResidency, printfHandler.get()); if (parentKernel) { - getCommandStreamReceiver().setMediaVFEStateDirty(true); + getGpgpuCommandStreamReceiver().setMediaVFEStateDirty(true); if (devQueueHw->getSchedulerReturnInstance() > 0) { waitUntilComplete(completionStamp.taskCount, completionStamp.flushStamp, false); @@ -448,12 +448,12 @@ void CommandQueueHw::processDispatchForKernels(const MultiDispatchInf if (DebugManager.flags.AddPatchInfoCommentsForAUBDump.get()) { for (auto &dispatchInfo : multiDispatchInfo) { for (auto &patchInfoData : dispatchInfo.getKernel()->getPatchInfoDataList()) { - getCommandStreamReceiver().getFlatBatchBufferHelper().setPatchInfoData(patchInfoData); + getGpgpuCommandStreamReceiver().getFlatBatchBufferHelper().setPatchInfoData(patchInfoData); } } } - getCommandStreamReceiver().setRequiredScratchSizes(multiDispatchInfo.getRequiredScratchSize(), multiDispatchInfo.getRequiredPrivateScratchSize()); + getGpgpuCommandStreamReceiver().setRequiredScratchSizes(multiDispatchInfo.getRequiredScratchSize(), multiDispatchInfo.getRequiredPrivateScratchSize()); } template @@ -494,7 +494,7 @@ void CommandQueueHw::processDispatchForCacheFlush(Surface **surfaces, TimestampPacketHelper::programCsrDependencies(*commandStream, csrDeps); uint64_t postSyncAddress = 0; - if (getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + if (getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { auto timestampPacketNodeForPostSync = timestampPacketContainer->peekNodes().at(0); postSyncAddress = timestampPacketNodeForPostSync->getGpuAddress() + offsetof(TimestampPacketStorage, packets[0].contextEnd); } @@ -511,7 +511,7 @@ void CommandQueueHw::processDeviceEnqueue(Kernel *parentKernel, bool &blocking) { size_t minSizeSSHForEM = HardwareCommandsHelper::template getSizeRequiredForExecutionModel(*parentKernel); - uint32_t taskCount = getCommandStreamReceiver().peekTaskCount() + 1; + uint32_t taskCount = getGpgpuCommandStreamReceiver().peekTaskCount() + 1; devQueueHw->setupExecutionModelDispatch(getIndirectHeap(IndirectHeap::SURFACE_STATE, minSizeSSHForEM), *devQueueHw->getIndirectHeap(IndirectHeap::DYNAMIC_STATE), parentKernel, @@ -540,9 +540,9 @@ void CommandQueueHw::processDeviceEnqueue(Kernel *parentKernel, &getIndirectHeap(IndirectHeap::SURFACE_STATE, 0u), devQueueHw->getIndirectHeap(IndirectHeap::DYNAMIC_STATE)); - scheduler.makeResident(getCommandStreamReceiver()); + scheduler.makeResident(getGpgpuCommandStreamReceiver()); - parentKernel->getProgram()->getBlockKernelManager()->makeInternalAllocationsResident(getCommandStreamReceiver()); + parentKernel->getProgram()->getBlockKernelManager()->makeInternalAllocationsResident(getGpgpuCommandStreamReceiver()); if (parentKernel->isAuxTranslationRequired()) { blocking = true; @@ -614,16 +614,16 @@ CompletionStamp CommandQueueHw::enqueueNonBlocked( if (printfHandler) { blocking = true; - printfHandler->makeResident(getCommandStreamReceiver()); + printfHandler->makeResident(getGpgpuCommandStreamReceiver()); } if (timestampPacketContainer) { - timestampPacketContainer->makeResident(getCommandStreamReceiver()); - previousTimestampPacketNodes->makeResident(getCommandStreamReceiver()); + timestampPacketContainer->makeResident(getGpgpuCommandStreamReceiver()); + previousTimestampPacketNodes->makeResident(getGpgpuCommandStreamReceiver()); } auto requiresCoherency = false; for (auto surface : CreateRange(surfaces, surfaceCount)) { - surface->makeResident(getCommandStreamReceiver()); + surface->makeResident(getGpgpuCommandStreamReceiver()); requiresCoherency |= surface->IsCoherent; } @@ -638,7 +638,7 @@ CompletionStamp CommandQueueHw::enqueueNonBlocked( } else { continue; } - kernel->makeResident(getCommandStreamReceiver()); + kernel->makeResident(getGpgpuCommandStreamReceiver()); requiresCoherency |= kernel->requiresCoherency(); mediaSamplerRequired |= kernel->isVmeKernel(); auto numGrfRequiredByKernel = kernel->getKernelInfo().patchInfo.executionEnvironment->NumGRFRequired; @@ -657,9 +657,9 @@ CompletionStamp CommandQueueHw::enqueueNonBlocked( if (isProfilingEnabled() && eventBuilder.getEvent()) { this->getDevice().getOSTime()->getCpuGpuTime(&submitTimeStamp); eventBuilder.getEvent()->setSubmitTimeStamp(&submitTimeStamp); - getCommandStreamReceiver().makeResident(*eventBuilder.getEvent()->getHwTimeStampNode()->getBaseGraphicsAllocation()); + getGpgpuCommandStreamReceiver().makeResident(*eventBuilder.getEvent()->getHwTimeStampNode()->getBaseGraphicsAllocation()); if (isPerfCountersEnabled()) { - getCommandStreamReceiver().makeResident(*eventBuilder.getEvent()->getHwPerfCounterNode()->getBaseGraphicsAllocation()); + getGpgpuCommandStreamReceiver().makeResident(*eventBuilder.getEvent()->getHwPerfCounterNode()->getBaseGraphicsAllocation()); } } @@ -678,17 +678,17 @@ CompletionStamp CommandQueueHw::enqueueNonBlocked( ioh = &getIndirectHeap(IndirectHeap::INDIRECT_OBJECT, 0u); } - getCommandStreamReceiver().requestThreadArbitrationPolicy(multiDispatchInfo.peekMainKernel()->getThreadArbitrationPolicy()); + getGpgpuCommandStreamReceiver().requestThreadArbitrationPolicy(multiDispatchInfo.peekMainKernel()->getThreadArbitrationPolicy()); auto allocNeedsFlushDC = false; if (!device->isFullRangeSvm()) { - if (std::any_of(getCommandStreamReceiver().getResidencyAllocations().begin(), getCommandStreamReceiver().getResidencyAllocations().end(), [](const auto allocation) { return allocation->isFlushL3Required(); })) { + if (std::any_of(getGpgpuCommandStreamReceiver().getResidencyAllocations().begin(), getGpgpuCommandStreamReceiver().getResidencyAllocations().end(), [](const auto allocation) { return allocation->isFlushL3Required(); })) { allocNeedsFlushDC = true; } } if (anyUncacheableArgs) { - getCommandStreamReceiver().setDisableL3Cache(true); + getGpgpuCommandStreamReceiver().setDisableL3Cache(true); } DispatchFlags dispatchFlags; @@ -704,9 +704,9 @@ CompletionStamp CommandQueueHw::enqueueNonBlocked( dispatchFlags.implicitFlush = implicitFlush; dispatchFlags.flushStampReference = this->flushStamp->getStampReference(); dispatchFlags.preemptionMode = PreemptionHelper::taskPreemptionMode(*device, multiDispatchInfo); - dispatchFlags.outOfOrderExecutionAllowed = !eventBuilder.getEvent() || getCommandStreamReceiver().isNTo1SubmissionModelEnabled(); - if (getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { - dispatchFlags.csrDependencies.fillFromEventsRequestAndMakeResident(eventsRequest, getCommandStreamReceiver(), CsrDependencies::DependenciesType::OutOfCsr); + dispatchFlags.outOfOrderExecutionAllowed = !eventBuilder.getEvent() || getGpgpuCommandStreamReceiver().isNTo1SubmissionModelEnabled(); + if (getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + dispatchFlags.csrDependencies.fillFromEventsRequestAndMakeResident(eventsRequest, getGpgpuCommandStreamReceiver(), CsrDependencies::DependenciesType::OutOfCsr); } dispatchFlags.numGrfRequired = numGrfRequired; dispatchFlags.specialPipelineSelectMode = specialPipelineSelectMode; @@ -718,7 +718,7 @@ CompletionStamp CommandQueueHw::enqueueNonBlocked( } printDebugString(DebugManager.flags.PrintDebugMessages.get(), stdout, "preemption = %d.\n", static_cast(dispatchFlags.preemptionMode)); - CompletionStamp completionStamp = getCommandStreamReceiver().flushTask( + CompletionStamp completionStamp = getGpgpuCommandStreamReceiver().flushTask( commandStream, commandStreamStart, *dsh, @@ -777,7 +777,7 @@ void CommandQueueHw::enqueueBlocked( *this, nullptr)); - auto cmd = std::make_unique(*this, getCommandStreamReceiver(), commandType, cmdSize); + auto cmd = std::make_unique(*this, getGpgpuCommandStreamReceiver(), commandType, cmdSize); eventBuilder->getEvent()->setCommand(std::move(cmd)); } else { @@ -844,13 +844,13 @@ CompletionStamp CommandQueueHw::enqueueCommandWithoutKernel( uint32_t taskLevel) { if (timestampPacketContainer) { - timestampPacketContainer->makeResident(getCommandStreamReceiver()); - previousTimestampPacketNodes->makeResident(getCommandStreamReceiver()); + timestampPacketContainer->makeResident(getGpgpuCommandStreamReceiver()); + previousTimestampPacketNodes->makeResident(getGpgpuCommandStreamReceiver()); } auto requiresCoherency = false; for (auto surface : CreateRange(surfaces, surfaceCount)) { - surface->makeResident(getCommandStreamReceiver()); + surface->makeResident(getGpgpuCommandStreamReceiver()); requiresCoherency |= surface->IsCoherent; } @@ -858,10 +858,10 @@ CompletionStamp CommandQueueHw::enqueueCommandWithoutKernel( dispatchFlags.blocking = blocking; dispatchFlags.multiEngineQueue = multiEngineQueue; dispatchFlags.preemptionMode = device->getPreemptionMode(); - if (getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { - dispatchFlags.csrDependencies.fillFromEventsRequestAndMakeResident(eventsRequest, getCommandStreamReceiver(), CsrDependencies::DependenciesType::OutOfCsr); + if (getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + dispatchFlags.csrDependencies.fillFromEventsRequestAndMakeResident(eventsRequest, getGpgpuCommandStreamReceiver(), CsrDependencies::DependenciesType::OutOfCsr); } - CompletionStamp completionStamp = getCommandStreamReceiver().flushTask( + CompletionStamp completionStamp = getGpgpuCommandStreamReceiver().flushTask( commandStream, commandStreamStart, getIndirectHeap(IndirectHeap::DYNAMIC_STATE, 0u), diff --git a/runtime/command_queue/enqueue_fill_buffer.h b/runtime/command_queue/enqueue_fill_buffer.h index dfea500adf..49b1d283ab 100644 --- a/runtime/command_queue/enqueue_fill_buffer.h +++ b/runtime/command_queue/enqueue_fill_buffer.h @@ -74,7 +74,7 @@ cl_int CommandQueueHw::enqueueFillBuffer( eventWaitList, event); - auto storageForAllocation = getCommandStreamReceiver().getInternalAllocationStorage(); + auto storageForAllocation = getGpgpuCommandStreamReceiver().getInternalAllocationStorage(); storageForAllocation->storeAllocationWithTaskCount(std::unique_ptr(patternAllocation), TEMPORARY_ALLOCATION, taskCount); return CL_SUCCESS; diff --git a/runtime/command_queue/enqueue_read_buffer.h b/runtime/command_queue/enqueue_read_buffer.h index 3274a5c875..47771127ef 100644 --- a/runtime/command_queue/enqueue_read_buffer.h +++ b/runtime/command_queue/enqueue_read_buffer.h @@ -76,7 +76,7 @@ cl_int CommandQueueHw::enqueueReadBuffer( } else { surfaces[1] = &hostPtrSurf; if (size != 0) { - bool status = getCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, true); + bool status = getGpgpuCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, true); if (!status) { return CL_OUT_OF_RESOURCES; } diff --git a/runtime/command_queue/enqueue_read_buffer_rect.h b/runtime/command_queue/enqueue_read_buffer_rect.h index e9fd7c266e..6374a932c9 100644 --- a/runtime/command_queue/enqueue_read_buffer_rect.h +++ b/runtime/command_queue/enqueue_read_buffer_rect.h @@ -60,7 +60,7 @@ cl_int CommandQueueHw::enqueueReadBufferRect( if (region[0] != 0 && region[1] != 0 && region[2] != 0) { - bool status = getCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, true); + bool status = getGpgpuCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, true); if (!status) { return CL_OUT_OF_RESOURCES; } diff --git a/runtime/command_queue/enqueue_read_image.h b/runtime/command_queue/enqueue_read_image.h index c4db6250e4..af30da00bf 100644 --- a/runtime/command_queue/enqueue_read_image.h +++ b/runtime/command_queue/enqueue_read_image.h @@ -81,7 +81,7 @@ cl_int CommandQueueHw::enqueueReadImage( if (region[0] != 0 && region[1] != 0 && region[2] != 0) { - bool status = getCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, true); + bool status = getGpgpuCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, true); if (!status) { return CL_OUT_OF_RESOURCES; } diff --git a/runtime/command_queue/enqueue_svm.h b/runtime/command_queue/enqueue_svm.h index 20884ac8ba..d3953200e6 100644 --- a/runtime/command_queue/enqueue_svm.h +++ b/runtime/command_queue/enqueue_svm.h @@ -317,7 +317,7 @@ cl_int CommandQueueHw::enqueueSVMMemcpy(cl_bool blockingCopy, GeneralSurface srcSvmSurf(srcSvmData->gpuAllocation); HostPtrSurface dstHostPtrSurf(dstPtr, size); if (size != 0) { - bool status = getCommandStreamReceiver().createAllocationForHostSurface(dstHostPtrSurf, true); + bool status = getGpgpuCommandStreamReceiver().createAllocationForHostSurface(dstHostPtrSurf, true); if (!status) { return CL_OUT_OF_RESOURCES; } @@ -341,7 +341,7 @@ cl_int CommandQueueHw::enqueueSVMMemcpy(cl_bool blockingCopy, HostPtrSurface srcHostPtrSurf(const_cast(srcPtr), size); GeneralSurface dstSvmSurf(dstSvmData->gpuAllocation); if (size != 0) { - bool status = getCommandStreamReceiver().createAllocationForHostSurface(srcHostPtrSurf, false); + bool status = getGpgpuCommandStreamReceiver().createAllocationForHostSurface(srcHostPtrSurf, false); if (!status) { return CL_OUT_OF_RESOURCES; } @@ -399,8 +399,8 @@ cl_int CommandQueueHw::enqueueSVMMemFill(void *svmPtr, auto memoryManager = getDevice().getMemoryManager(); DEBUG_BREAK_IF(nullptr == memoryManager); - auto commandStreamReceieverOwnership = getCommandStreamReceiver().obtainUniqueOwnership(); - auto storageWithAllocations = getCommandStreamReceiver().getInternalAllocationStorage(); + auto commandStreamReceieverOwnership = getGpgpuCommandStreamReceiver().obtainUniqueOwnership(); + auto storageWithAllocations = getGpgpuCommandStreamReceiver().getInternalAllocationStorage(); auto allocationType = GraphicsAllocation::AllocationType::FILL_PATTERN; auto patternAllocation = storageWithAllocations->obtainReusableAllocation(patternSize, allocationType).release(); commandStreamReceieverOwnership.unlock(); diff --git a/runtime/command_queue/enqueue_write_buffer.h b/runtime/command_queue/enqueue_write_buffer.h index d4b09d5774..7cf57d6ba3 100644 --- a/runtime/command_queue/enqueue_write_buffer.h +++ b/runtime/command_queue/enqueue_write_buffer.h @@ -72,7 +72,7 @@ cl_int CommandQueueHw::enqueueWriteBuffer( } else { surfaces[1] = &hostPtrSurf; if (size != 0) { - bool status = getCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, false); + bool status = getGpgpuCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, false); if (!status) { return CL_OUT_OF_RESOURCES; } diff --git a/runtime/command_queue/enqueue_write_buffer_rect.h b/runtime/command_queue/enqueue_write_buffer_rect.h index b9ecfa7cde..5cbdedfc48 100644 --- a/runtime/command_queue/enqueue_write_buffer_rect.h +++ b/runtime/command_queue/enqueue_write_buffer_rect.h @@ -59,7 +59,7 @@ cl_int CommandQueueHw::enqueueWriteBufferRect( if (region[0] != 0 && region[1] != 0 && region[2] != 0) { - bool status = getCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, false); + bool status = getGpgpuCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, false); if (!status) { return CL_OUT_OF_RESOURCES; } diff --git a/runtime/command_queue/enqueue_write_image.h b/runtime/command_queue/enqueue_write_image.h index e79a005a7d..9f1634dd42 100644 --- a/runtime/command_queue/enqueue_write_image.h +++ b/runtime/command_queue/enqueue_write_image.h @@ -72,7 +72,7 @@ cl_int CommandQueueHw::enqueueWriteImage( if (region[0] != 0 && region[1] != 0 && region[2] != 0) { - bool status = getCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, false); + bool status = getGpgpuCommandStreamReceiver().createAllocationForHostSurface(hostPtrSurf, false); if (!status) { return CL_OUT_OF_RESOURCES; } diff --git a/runtime/command_queue/finish.h b/runtime/command_queue/finish.h index 6a618500ad..df9f4cf8d4 100644 --- a/runtime/command_queue/finish.h +++ b/runtime/command_queue/finish.h @@ -16,7 +16,7 @@ namespace NEO { template cl_int CommandQueueHw::finish(bool dcFlush) { - getCommandStreamReceiver().flushBatchedSubmissions(); + getGpgpuCommandStreamReceiver().flushBatchedSubmissions(); //as long as queue is blocked we need to stall. while (isQueueBlocked()) diff --git a/runtime/command_queue/flush.h b/runtime/command_queue/flush.h index b869eeb602..80bd0ff100 100644 --- a/runtime/command_queue/flush.h +++ b/runtime/command_queue/flush.h @@ -10,7 +10,7 @@ namespace NEO { template cl_int CommandQueueHw::flush() { - getCommandStreamReceiver().flushBatchedSubmissions(); + getGpgpuCommandStreamReceiver().flushBatchedSubmissions(); return CL_SUCCESS; } } // namespace NEO diff --git a/runtime/command_queue/gpgpu_walker_base.inl b/runtime/command_queue/gpgpu_walker_base.inl index 407a80fb3e..0640e7f063 100644 --- a/runtime/command_queue/gpgpu_walker_base.inl +++ b/runtime/command_queue/gpgpu_walker_base.inl @@ -205,7 +205,7 @@ size_t EnqueueOperation::getTotalSizeRequiredCS(uint32_t eventType, c SchedulerKernel &scheduler = commandQueue.getDevice().getExecutionEnvironment()->getBuiltIns()->getSchedulerKernel(parentKernel->getContext()); expectedSizeCS += EnqueueOperation::getSizeRequiredCS(eventType, reserveProfilingCmdsSpace, reservePerfCounters, commandQueue, &scheduler); } - if (commandQueue.getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + if (commandQueue.getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { expectedSizeCS += TimestampPacketHelper::getRequiredCmdStreamSize(csrDeps); expectedSizeCS += EnqueueOperation::getSizeRequiredForTimestampPacketWrite(); } diff --git a/runtime/command_queue/hardware_interface_base.inl b/runtime/command_queue/hardware_interface_base.inl index 2fc03cdebc..044216ae01 100644 --- a/runtime/command_queue/hardware_interface_base.inl +++ b/runtime/command_queue/hardware_interface_base.inl @@ -55,7 +55,7 @@ void HardwareInterface::dispatchWalker( constexpr static auto additionalAllocationSize = CSRequirements::csOverfetchSize; constexpr static auto allocationSize = MemoryConstants::pageSize64k - additionalAllocationSize; commandStream = new LinearStream(); - commandQueue.getCommandStreamReceiver().ensureCommandBufferAllocation(*commandStream, allocationSize, additionalAllocationSize); + commandQueue.getGpgpuCommandStreamReceiver().ensureCommandBufferAllocation(*commandStream, allocationSize, additionalAllocationSize); if (parentKernel) { uint32_t colorCalcSize = commandQueue.getContext().getDefaultDeviceQueue()->colorCalcStateSize; @@ -80,7 +80,7 @@ void HardwareInterface::dispatchWalker( using UniqueIH = std::unique_ptr; *blockedCommandsData = new KernelOperation(std::unique_ptr(commandStream), UniqueIH(dsh), UniqueIH(ioh), - UniqueIH(ssh), *commandQueue.getCommandStreamReceiver().getInternalAllocationStorage()); + UniqueIH(ssh), *commandQueue.getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); if (parentKernel) { (*blockedCommandsData)->doNotFreeISH = true; } @@ -186,7 +186,7 @@ void HardwareInterface::dispatchWalker( dispatchWorkarounds(commandStream, commandQueue, kernel, true); - if (commandQueue.getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + if (commandQueue.getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { auto timestampPacketNode = currentTimestampPacketNodes->peekNodes().at(currentDispatchIndex); GpgpuWalkerHelper::setupTimestampPacket(commandStream, nullptr, timestampPacketNode, TimestampPacketStorage::WriteOperationType::BeforeWalker); } @@ -202,7 +202,7 @@ void HardwareInterface::dispatchWalker( } if (mainKernel->requiresCacheFlushCommand(commandQueue)) { uint64_t postSyncAddress = 0; - if (commandQueue.getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + if (commandQueue.getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { auto timestampPacketNodeForPostSync = currentTimestampPacketNodes->peekNodes().at(currentDispatchIndex); postSyncAddress = timestampPacketNodeForPostSync->getGpuAddress() + offsetof(TimestampPacketStorage, packets[0].contextEnd); } diff --git a/runtime/command_queue/hardware_interface_bdw_plus.inl b/runtime/command_queue/hardware_interface_bdw_plus.inl index 375d809f25..75c1ce3b4d 100644 --- a/runtime/command_queue/hardware_interface_bdw_plus.inl +++ b/runtime/command_queue/hardware_interface_bdw_plus.inl @@ -107,7 +107,7 @@ inline void HardwareInterface::programWalker( size_t startWorkGroups[3] = {startOfWorkgroups.x, startOfWorkgroups.y, startOfWorkgroups.z}; size_t numWorkGroups[3] = {numberOfWorkgroups.x, numberOfWorkgroups.y, numberOfWorkgroups.z}; - if (currentTimestampPacketNodes && commandQueue.getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + if (currentTimestampPacketNodes && commandQueue.getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { auto timestampPacketNode = currentTimestampPacketNodes->peekNodes().at(currentDispatchIndex); GpgpuWalkerHelper::setupTimestampPacket(&commandStream, walkerCmd, timestampPacketNode, TimestampPacketStorage::WriteOperationType::AfterWalker); } diff --git a/runtime/event/event.cpp b/runtime/event/event.cpp index c516a48667..734d3604d4 100644 --- a/runtime/event/event.cpp +++ b/runtime/event/event.cpp @@ -66,7 +66,7 @@ Event::Event( if ((this->ctx == nullptr) && (cmdQueue != nullptr)) { this->ctx = &cmdQueue->getContext(); - if (cmdQueue->getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + if (cmdQueue->getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { timestampPacketContainer = std::make_unique(); } } @@ -334,7 +334,7 @@ inline bool Event::wait(bool blocking, bool useQuickKmdSleep) { DEBUG_BREAK_IF(this->taskLevel == Event::eventNotReady && this->executionStatus >= 0); - auto *allocationStorage = cmdQueue->getCommandStreamReceiver().getInternalAllocationStorage(); + auto *allocationStorage = cmdQueue->getGpgpuCommandStreamReceiver().getInternalAllocationStorage(); allocationStorage->cleanAllocationList(this->taskCount, TEMPORARY_ALLOCATION); return true; @@ -370,7 +370,7 @@ void Event::updateExecutionStatus() { transitionExecutionStatus(CL_COMPLETE); executeCallbacks(CL_COMPLETE); unblockEventsBlockedByThis(CL_COMPLETE); - auto *allocationStorage = cmdQueue->getCommandStreamReceiver().getInternalAllocationStorage(); + auto *allocationStorage = cmdQueue->getGpgpuCommandStreamReceiver().getInternalAllocationStorage(); allocationStorage->cleanAllocationList(this->taskCount, TEMPORARY_ALLOCATION); return; } @@ -471,11 +471,11 @@ void Event::submitCommand(bool abortTasks) { if (cmdToProcess.get() != nullptr) { std::unique_lock lockCSR; if (this->cmdQueue) { - lockCSR = this->getCommandQueue()->getCommandStreamReceiver().obtainUniqueOwnership(); + lockCSR = this->getCommandQueue()->getGpgpuCommandStreamReceiver().obtainUniqueOwnership(); } if ((this->isProfilingEnabled()) && (this->cmdQueue != nullptr)) { if (timeStampNode) { - this->cmdQueue->getCommandStreamReceiver().makeResident(*timeStampNode->getBaseGraphicsAllocation()); + this->cmdQueue->getGpgpuCommandStreamReceiver().makeResident(*timeStampNode->getBaseGraphicsAllocation()); cmdToProcess->timestamp = timeStampNode; } if (profilingCpuPath) { @@ -485,7 +485,7 @@ void Event::submitCommand(bool abortTasks) { this->cmdQueue->getDevice().getOSTime()->getCpuGpuTime(&submitTimeStamp); } if (perfCountersEnabled && perfCounterNode) { - this->cmdQueue->getCommandStreamReceiver().makeResident(*perfCounterNode->getBaseGraphicsAllocation()); + this->cmdQueue->getGpgpuCommandStreamReceiver().makeResident(*perfCounterNode->getBaseGraphicsAllocation()); } } auto &complStamp = cmdToProcess->submit(taskLevel, abortTasks); @@ -501,8 +501,8 @@ void Event::submitCommand(bool abortTasks) { if (this->taskCount == Event::eventNotReady) { if (!this->isUserEvent() && this->eventWithoutCommand) { if (this->cmdQueue) { - auto lockCSR = this->getCommandQueue()->getCommandStreamReceiver().obtainUniqueOwnership(); - updateTaskCount(this->cmdQueue->getCommandStreamReceiver().peekTaskCount()); + auto lockCSR = this->getCommandQueue()->getGpgpuCommandStreamReceiver().obtainUniqueOwnership(); + updateTaskCount(this->cmdQueue->getGpgpuCommandStreamReceiver().peekTaskCount()); } } //make sure that task count is synchronized for events with kernels @@ -573,7 +573,7 @@ inline void Event::unblockEventBy(Event &event, uint32_t taskLevel, int32_t tran DBG_LOG(EventsDebugEnable, "Event", this, "is unblocked by", &event); if (this->taskLevel == Event::eventNotReady) { - this->taskLevel = std::max(cmdQueue->getCommandStreamReceiver().peekTaskLevel(), taskLevel); + this->taskLevel = std::max(cmdQueue->getGpgpuCommandStreamReceiver().peekTaskLevel(), taskLevel); } else { this->taskLevel = std::max(this->taskLevel.load(), taskLevel); } @@ -664,7 +664,7 @@ void Event::tryFlushEvent() { if (cmdQueue && updateStatusAndCheckCompletion() == false) { //flush the command queue only if it is not blocked event if (taskLevel != Event::eventNotReady) { - cmdQueue->getCommandStreamReceiver().flushBatchedSubmissions(); + cmdQueue->getGpgpuCommandStreamReceiver().flushBatchedSubmissions(); } } } @@ -696,7 +696,7 @@ void Event::setEndTimeStamp() { TagNode *Event::getHwTimeStampNode() { if (!timeStampNode) { - timeStampNode = cmdQueue->getCommandStreamReceiver().getEventTsAllocator()->getTag(); + timeStampNode = cmdQueue->getGpgpuCommandStreamReceiver().getEventTsAllocator()->getTag(); } return timeStampNode; } @@ -705,7 +705,7 @@ TagNode *Event::getHwPerfCounterNode() { if (!perfCounterNode && cmdQueue->getPerfCounters()) { const uint32_t gpuReportSize = cmdQueue->getPerfCounters()->getGpuReportSize(); - perfCounterNode = cmdQueue->getCommandStreamReceiver().getEventPerfCountAllocator(gpuReportSize)->getTag(); + perfCounterNode = cmdQueue->getGpgpuCommandStreamReceiver().getEventPerfCountAllocator(gpuReportSize)->getTag(); } return perfCounterNode; } diff --git a/runtime/event/user_event.cpp b/runtime/event/user_event.cpp index fee093729f..66a0a8c6aa 100644 --- a/runtime/event/user_event.cpp +++ b/runtime/event/user_event.cpp @@ -67,7 +67,7 @@ bool VirtualEvent::wait(bool blocking, bool useQuickKmdSleep) { uint32_t VirtualEvent::getTaskLevel() { uint32_t taskLevel = 0; if (cmdQueue != nullptr) { - auto &csr = cmdQueue->getCommandStreamReceiver(); + auto &csr = cmdQueue->getGpgpuCommandStreamReceiver(); taskLevel = csr.peekTaskLevel(); } return taskLevel; diff --git a/runtime/helpers/csr_deps.cpp b/runtime/helpers/csr_deps.cpp index 350f27fd35..5731cb054e 100644 --- a/runtime/helpers/csr_deps.cpp +++ b/runtime/helpers/csr_deps.cpp @@ -28,7 +28,7 @@ void CsrDependencies::fillFromEventsRequestAndMakeResident(const EventsRequest & } timestampPacketContainer->makeResident(currentCsr); - auto sameCsr = (&event->getCommandQueue()->getCommandStreamReceiver() == ¤tCsr); + auto sameCsr = (&event->getCommandQueue()->getGpgpuCommandStreamReceiver() == ¤tCsr); bool pushDependency = (DependenciesType::OnCsr == depsType && sameCsr) || (DependenciesType::OutOfCsr == depsType && !sameCsr) || (DependenciesType::All == depsType); diff --git a/runtime/helpers/task_information.cpp b/runtime/helpers/task_information.cpp index 3b81c82542..d65c123eef 100644 --- a/runtime/helpers/task_information.cpp +++ b/runtime/helpers/task_information.cpp @@ -114,7 +114,7 @@ CommandComputeKernel::~CommandComputeKernel() { } kernel->decRefInternal(); - auto &commandStreamReceiver = commandQueue.getCommandStreamReceiver(); + auto &commandStreamReceiver = commandQueue.getGpgpuCommandStreamReceiver(); if (commandStreamReceiver.peekTimestampPacketWriteEnabled()) { for (cl_event eventFromWaitList : eventsWaitlist) { auto event = castToObjectOrAbort(eventFromWaitList); @@ -127,7 +127,7 @@ CompletionStamp &CommandComputeKernel::submit(uint32_t taskLevel, bool terminate if (terminated) { return completionStamp; } - auto &commandStreamReceiver = commandQueue.getCommandStreamReceiver(); + auto &commandStreamReceiver = commandQueue.getGpgpuCommandStreamReceiver(); bool executionModelKernel = kernel->isParentKernel; auto devQueue = commandQueue.getContext().getDefaultDeviceQueue(); diff --git a/runtime/sharings/gl/gl_arb_sync_event.cpp b/runtime/sharings/gl/gl_arb_sync_event.cpp index e777898c85..0016ce1bdc 100644 --- a/runtime/sharings/gl/gl_arb_sync_event.cpp +++ b/runtime/sharings/gl/gl_arb_sync_event.cpp @@ -29,7 +29,7 @@ bool GlArbSyncEvent::setBaseEvent(Event &ev) { UNRECOVERABLE_IF(ev.getContext() == nullptr); UNRECOVERABLE_IF(ev.getCommandQueue() == nullptr); auto cmdQueue = ev.getCommandQueue(); - auto osInterface = cmdQueue->getCommandStreamReceiver().getOSInterface(); + auto osInterface = cmdQueue->getGpgpuCommandStreamReceiver().getOSInterface(); UNRECOVERABLE_IF(osInterface == nullptr); if (false == ctx->getSharing()->glArbSyncObjectSetup(*osInterface, *glSyncInfo)) { return false; @@ -70,7 +70,7 @@ void GlArbSyncEvent::unblockEventBy(Event &event, uint32_t taskLevel, int32_t tr return; } - ctx->getSharing()->glArbSyncObjectSignal(event.getCommandQueue()->getCommandStreamReceiver().getOsContext(), *glSyncInfo); + ctx->getSharing()->glArbSyncObjectSignal(event.getCommandQueue()->getGpgpuCommandStreamReceiver().getOsContext(), *glSyncInfo); ctx->getSharing()->glArbSyncObjectWaitServer(*osInterface, *glSyncInfo); } } // namespace NEO diff --git a/unit_tests/api/cl_create_command_queue_with_properties_tests.cpp b/unit_tests/api/cl_create_command_queue_with_properties_tests.cpp index 4f156aff50..48ebc3271e 100644 --- a/unit_tests/api/cl_create_command_queue_with_properties_tests.cpp +++ b/unit_tests/api/cl_create_command_queue_with_properties_tests.cpp @@ -360,7 +360,7 @@ TEST_F(clCreateCommandQueueWithPropertiesApi, GivenLowPriorityWhenCreatingComman auto cmdQ = clCreateCommandQueueWithProperties(pContext, devices[0], properties, nullptr); auto commandQueueObj = castToObject(cmdQ); - auto &osContext = commandQueueObj->getCommandStreamReceiver().getOsContext(); + auto &osContext = commandQueueObj->getGpgpuCommandStreamReceiver().getOsContext(); EXPECT_EQ(aub_stream::ENGINE_RCS, osContext.getEngineType()); EXPECT_TRUE(osContext.isLowPriority()); diff --git a/unit_tests/api/cl_mem_locally_uncached_resource_tests.cpp b/unit_tests/api/cl_mem_locally_uncached_resource_tests.cpp index d0f946d0a9..6db042b174 100644 --- a/unit_tests/api/cl_mem_locally_uncached_resource_tests.cpp +++ b/unit_tests/api/cl_mem_locally_uncached_resource_tests.cpp @@ -36,7 +36,7 @@ template uint32_t cmdQueueMocs(CommandQueue *pCmdQ) { using STATE_BASE_ADDRESS = typename FamilyType::STATE_BASE_ADDRESS; auto pCmdQHw = reinterpret_cast *>(pCmdQ); - auto &csr = pCmdQHw->getCommandStreamReceiver(); + auto &csr = pCmdQHw->getGpgpuCommandStreamReceiver(); HardwareParse hwParse; hwParse.parseCommands(csr.getCS(0), 0); auto itorCmd = reverse_find(hwParse.cmdList.rbegin(), hwParse.cmdList.rend()); diff --git a/unit_tests/aub_tests/command_queue/enqueue_kernel_aub_tests.cpp b/unit_tests/aub_tests/command_queue/enqueue_kernel_aub_tests.cpp index c9247dede2..ff1a0fcd5c 100644 --- a/unit_tests/aub_tests/command_queue/enqueue_kernel_aub_tests.cpp +++ b/unit_tests/aub_tests/command_queue/enqueue_kernel_aub_tests.cpp @@ -277,7 +277,7 @@ HWTEST_F(AUBSimpleArg, givenAubCommandStreamerReceiverWhenBatchBufferFlateningIs DebugManagerStateRestore dbgRestore; DebugManager.flags.FlattenBatchBufferForAUBDump.set(true); - pCmdQ->getCommandStreamReceiver().overrideDispatchPolicy(DispatchMode::ImmediateDispatch); + pCmdQ->getGpgpuCommandStreamReceiver().overrideDispatchPolicy(DispatchMode::ImmediateDispatch); auto retVal = pCmdQ->enqueueKernel( pKernel, diff --git a/unit_tests/aub_tests/command_stream/aub_command_stream_fixture.cpp b/unit_tests/aub_tests/command_stream/aub_command_stream_fixture.cpp index 99c73eae5b..09429a7eb2 100644 --- a/unit_tests/aub_tests/command_stream/aub_command_stream_fixture.cpp +++ b/unit_tests/aub_tests/command_stream/aub_command_stream_fixture.cpp @@ -30,7 +30,7 @@ void AUBCommandStreamFixture::SetUp(CommandQueue *pCmdQ) { const ::testing::TestInfo *const testInfo = ::testing::UnitTest::GetInstance()->current_test_info(); std::stringstream strfilename; - auto engineType = pCmdQ->getCommandStreamReceiver().getOsContext().getEngineType(); + auto engineType = pCmdQ->getGpgpuCommandStreamReceiver().getOsContext().getEngineType(); strfilename << testInfo->test_case_name() << "_" << testInfo->name() << "_" << hwHelper.getCsTraits(engineType).name; if (testMode == TestMode::AubTestsWithTbx) { diff --git a/unit_tests/aub_tests/command_stream/aub_command_stream_tests.cpp b/unit_tests/aub_tests/command_stream/aub_command_stream_tests.cpp index 572d9b9362..f877ff98d3 100644 --- a/unit_tests/aub_tests/command_stream/aub_command_stream_tests.cpp +++ b/unit_tests/aub_tests/command_stream/aub_command_stream_tests.cpp @@ -102,7 +102,7 @@ HWTEST_F(AUBcommandstreamTests, testNoopIdVecs) { TEST_F(AUBcommandstreamTests, makeResident) { uint8_t buffer[0x10000]; size_t size = sizeof(buffer); - auto &commandStreamReceiver = pDevice->getCommandStreamReceiver(); + auto &commandStreamReceiver = pDevice->getGpgpuCommandStreamReceiver(); auto graphicsAllocation = createResidentAllocationAndStoreItInCsr(buffer, size); ResidencyContainer allocationsForResidency = {graphicsAllocation}; commandStreamReceiver.processResidency(allocationsForResidency); diff --git a/unit_tests/aub_tests/gen9/skl/command_queue/run_kernel_aub_tests_skl.cpp b/unit_tests/aub_tests/gen9/skl/command_queue/run_kernel_aub_tests_skl.cpp index d71e177eff..0bfd24b1c4 100644 --- a/unit_tests/aub_tests/gen9/skl/command_queue/run_kernel_aub_tests_skl.cpp +++ b/unit_tests/aub_tests/gen9/skl/command_queue/run_kernel_aub_tests_skl.cpp @@ -174,7 +174,7 @@ SKLTEST_F(AUBRunKernelIntegrateTest, ooqExecution) { pCmdQ2 = createCommandQueue(pDevice, CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE); ASSERT_NE(nullptr, pCmdQ2); - auto &csr = pCmdQ2->getCommandStreamReceiver(); + auto &csr = pCmdQ2->getGpgpuCommandStreamReceiver(); csr.overrideDispatchPolicy(DispatchMode::ImmediateDispatch); retVal = pCmdQ2->enqueueKernel( diff --git a/unit_tests/command_queue/command_queue_hw_tests.cpp b/unit_tests/command_queue/command_queue_hw_tests.cpp index 0cbb1d754f..b2e30b132f 100644 --- a/unit_tests/command_queue/command_queue_hw_tests.cpp +++ b/unit_tests/command_queue/command_queue_hw_tests.cpp @@ -682,7 +682,7 @@ HWTEST_F(CommandQueueHwTest, GivenEventThatIsNotCompletedWhenFinishIsCalledAndIt auto ev = new Event(this->pCmdQ, CL_COMMAND_COPY_BUFFER, 3, Event::eventNotReady + 1); clSetEventCallback(ev, CL_COMPLETE, ClbFuncTempStruct::ClbFuncT, &Value); - auto &csr = this->pCmdQ->getCommandStreamReceiver(); + auto &csr = this->pCmdQ->getGpgpuCommandStreamReceiver(); EXPECT_GT(3u, csr.peekTaskCount()); *csr.getTagAddress() = Event::eventNotReady + 1; ret = clFinish(this->pCmdQ); diff --git a/unit_tests/command_queue/command_queue_tests.cpp b/unit_tests/command_queue/command_queue_tests.cpp index 43d5ebb4a6..fca4ad85d1 100644 --- a/unit_tests/command_queue/command_queue_tests.cpp +++ b/unit_tests/command_queue/command_queue_tests.cpp @@ -204,7 +204,7 @@ TEST(CommandQueue, givenDeviceWhenCreatingCommandQueueThenPickCsrFromDefaultEngi CommandQueue cmdQ(nullptr, mockDevice.get(), 0); auto defaultCsr = mockDevice->getDefaultEngine().commandStreamReceiver; - EXPECT_EQ(defaultCsr, &cmdQ.getCommandStreamReceiver()); + EXPECT_EQ(defaultCsr, &cmdQ.getGpgpuCommandStreamReceiver()); } TEST(CommandQueue, givenCmdQueueBlockedByReadyVirtualEventWhenUnblockingThenUpdateFlushTaskFromEvent) { @@ -334,7 +334,7 @@ TEST_F(CommandQueueCommandStreamTest, givenCommandStreamReceiverWithReusableAllo auto memoryManager = pDevice->getMemoryManager(); size_t requiredSize = alignUp(100 + CSRequirements::minCommandQueueCommandStreamSize + CSRequirements::csOverfetchSize, MemoryConstants::pageSize64k); auto allocation = memoryManager->allocateGraphicsMemoryWithProperties({requiredSize, GraphicsAllocation::AllocationType::COMMAND_BUFFER}); - auto &commandStreamReceiver = cmdQ.getCommandStreamReceiver(); + auto &commandStreamReceiver = cmdQ.getGpgpuCommandStreamReceiver(); commandStreamReceiver.getInternalAllocationStorage()->storeAllocation(std::unique_ptr(allocation), REUSABLE_ALLOCATION); EXPECT_FALSE(commandStreamReceiver.getAllocationsForReuse().peekIsEmpty()); @@ -463,7 +463,7 @@ HWTEST_P(CommandQueueIndirectHeapTest, IndirectHeapContainsAtLeast64KB) { auto &indirectHeap = cmdQ.getIndirectHeap(this->GetParam(), sizeof(uint32_t)); if (this->GetParam() == IndirectHeap::SURFACE_STATE) { - size_t expectedSshUse = cmdQ.getCommandStreamReceiver().defaultSshSize - MemoryConstants::pageSize - UnitTestHelper::getDefaultSshUsage(); + size_t expectedSshUse = cmdQ.getGpgpuCommandStreamReceiver().defaultSshSize - MemoryConstants::pageSize - UnitTestHelper::getDefaultSshUsage(); EXPECT_EQ(expectedSshUse, indirectHeap.getAvailableSpace()); } else { EXPECT_EQ(64 * KB, indirectHeap.getAvailableSpace()); @@ -491,7 +491,7 @@ TEST_P(CommandQueueIndirectHeapTest, getIndirectHeapCanRecycle) { ASSERT_NE(nullptr, &indirectHeap); if (this->GetParam() == IndirectHeap::SURFACE_STATE) { //no matter what SSH is always capped - EXPECT_EQ(cmdQ.getCommandStreamReceiver().defaultSshSize - MemoryConstants::pageSize, + EXPECT_EQ(cmdQ.getGpgpuCommandStreamReceiver().defaultSshSize - MemoryConstants::pageSize, indirectHeap.getMaxAvailableSpace()); } else { EXPECT_LE(requiredSize, indirectHeap.getMaxAvailableSpace()); @@ -525,7 +525,7 @@ TEST_P(CommandQueueIndirectHeapTest, givenCommandStreamReceiverWithReusableAlloc GraphicsAllocation *allocation = nullptr; - auto &commandStreamReceiver = cmdQ.getCommandStreamReceiver(); + auto &commandStreamReceiver = cmdQ.getGpgpuCommandStreamReceiver(); auto allocationType = GraphicsAllocation::AllocationType::LINEAR_STREAM; if (this->GetParam() == IndirectHeap::INDIRECT_OBJECT) { allocationType = GraphicsAllocation::AllocationType::INTERNAL_HEAP; @@ -968,7 +968,7 @@ HWTEST_F(CommandQueueCommandStreamTest, givenDebugKernelWhenSetupDebugSurfaceIsC kernel->setSshLocal(nullptr, sizeof(RENDER_SURFACE_STATE) + kernel->getAllocatedKernelInfo()->patchInfo.pAllocateSystemThreadSurface->Offset); kernel->getAllocatedKernelInfo()->usesSsh = true; - auto &commandStreamReceiver = cmdQ.getCommandStreamReceiver(); + auto &commandStreamReceiver = cmdQ.getGpgpuCommandStreamReceiver(); cmdQ.setupDebugSurface(kernel.get()); @@ -987,7 +987,7 @@ HWTEST_F(CommandQueueCommandStreamTest, givenCsrWithDebugSurfaceAllocatedWhenSet kernel->setSshLocal(nullptr, sizeof(RENDER_SURFACE_STATE) + kernel->getAllocatedKernelInfo()->patchInfo.pAllocateSystemThreadSurface->Offset); kernel->getAllocatedKernelInfo()->usesSsh = true; - auto &commandStreamReceiver = cmdQ.getCommandStreamReceiver(); + auto &commandStreamReceiver = cmdQ.getGpgpuCommandStreamReceiver(); commandStreamReceiver.allocateDebugSurface(SipKernel::maxDbgSurfaceSize); auto debugSurface = commandStreamReceiver.getDebugSurfaceAllocation(); ASSERT_NE(nullptr, debugSurface); @@ -1029,8 +1029,8 @@ TEST(CommandQueuePropertiesTests, whenDefaultCommandQueueIsCreatedThenItIsNotMul TEST(CommandQueuePropertiesTests, whenGetEngineIsCalledThenQueueEngineIsReturned) { MockCommandQueue queue; EngineControl engineControl; - queue.engine = &engineControl; - EXPECT_EQ(queue.engine, &queue.getEngine()); + queue.gpgpuEngine = &engineControl; + EXPECT_EQ(queue.gpgpuEngine, &queue.getGpgpuEngine()); } TEST(CommandQueue, GivenCommandQueueWhenEnqueueResourceBarrierCalledThenSuccessReturned) { MockContext context; @@ -1049,4 +1049,4 @@ TEST(CommandQueue, GivenCommandQueueWhenCheckingIfIsCacheFlushCommandCalledThenF bool isCommandCacheFlush = cmdQ.isCacheFlushCommand(0u); EXPECT_FALSE(isCommandCacheFlush); -} \ No newline at end of file +} diff --git a/unit_tests/command_queue/dispatch_walker_tests.cpp b/unit_tests/command_queue/dispatch_walker_tests.cpp index 7a5f4d927d..5e62583b1c 100644 --- a/unit_tests/command_queue/dispatch_walker_tests.cpp +++ b/unit_tests/command_queue/dispatch_walker_tests.cpp @@ -806,7 +806,7 @@ HWTEST_F(DispatchWalkerTest, givenThereAreAllocationsForReuseWhenDispatchWalkerI ASSERT_EQ(CL_SUCCESS, kernel.initialize()); MockMultiDispatchInfo multiDispatchInfo(&kernel); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto allocation = csr.getMemoryManager()->allocateGraphicsMemoryWithProperties({MemoryConstants::pageSize64k + CSRequirements::csOverfetchSize, GraphicsAllocation::AllocationType::COMMAND_BUFFER}); csr.getInternalAllocationStorage()->storeAllocation(std::unique_ptr{allocation}, REUSABLE_ALLOCATION); diff --git a/unit_tests/command_queue/enqueue_api_tests_mt_with_asyncGPU.cpp b/unit_tests/command_queue/enqueue_api_tests_mt_with_asyncGPU.cpp index 031de66003..9f2a2eeba9 100644 --- a/unit_tests/command_queue/enqueue_api_tests_mt_with_asyncGPU.cpp +++ b/unit_tests/command_queue/enqueue_api_tests_mt_with_asyncGPU.cpp @@ -61,7 +61,7 @@ HWTEST_F(AsyncGPUoperations, MapBufferAfterWriteBuffer) { } t.join(); - srcBuffer->getGraphicsAllocation()->updateTaskCount(0u, pCmdQ->getCommandStreamReceiver().getOsContext().getContextId()); + srcBuffer->getGraphicsAllocation()->updateTaskCount(0u, pCmdQ->getGpgpuCommandStreamReceiver().getOsContext().getContextId()); alignedFree(ptrMemory); } diff --git a/unit_tests/command_queue/enqueue_barrier_tests.cpp b/unit_tests/command_queue/enqueue_barrier_tests.cpp index 0371551906..69f96b3afc 100644 --- a/unit_tests/command_queue/enqueue_barrier_tests.cpp +++ b/unit_tests/command_queue/enqueue_barrier_tests.cpp @@ -187,7 +187,7 @@ HWTEST_F(BarrierTest, eventWithWaitDependenciesShouldSync) { ASSERT_EQ(CL_SUCCESS, retVal); ASSERT_NE(nullptr, event); auto pEvent = castToObject(event); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); // in this case only cmdQ raises the taskLevel why csr stay intact EXPECT_EQ(8u, pCmdQ->taskLevel); @@ -220,7 +220,7 @@ HWTEST_F(BarrierTest, givenNotBlockedCommandQueueAndEnqueueBarrierWithWaitlistRe eventWaitList, &event); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); EXPECT_EQ(CL_SUCCESS, retVal); EXPECT_EQ(latestTaskCountWaitedBeforeEnqueue, this->pCmdQ->latestTaskCountWaited); diff --git a/unit_tests/command_queue/enqueue_command_without_kernel_tests.cpp b/unit_tests/command_queue/enqueue_command_without_kernel_tests.cpp index 3f2ddd80a9..b5cf126599 100644 --- a/unit_tests/command_queue/enqueue_command_without_kernel_tests.cpp +++ b/unit_tests/command_queue/enqueue_command_without_kernel_tests.cpp @@ -43,17 +43,17 @@ HWTEST_F(EnqueueHandlerTest, GivenCommandStreamWithoutKernelWhenCommandEnqueuedT auto blocking = true; TimestampPacketContainer previousTimestampPacketNodes; mockCmdQ->enqueueCommandWithoutKernel(surfaces, 1, mockCmdQ->getCS(0), 0, blocking, &previousTimestampPacketNodes, eventsRequest, eventBuilder, 0); - EXPECT_EQ(allocation->getTaskCount(mockCmdQ->getCommandStreamReceiver().getOsContext().getContextId()), 1u); + EXPECT_EQ(allocation->getTaskCount(mockCmdQ->getGpgpuCommandStreamReceiver().getOsContext().getContextId()), 1u); } HWTEST_F(EnqueueHandlerTest, whenEnqueueCommandWithoutKernelThenPassCorrectDispatchFlags) { auto executionEnvironment = pDevice->getExecutionEnvironment(); auto mockCsr = std::make_unique>(*executionEnvironment); auto mockCmdQ = std::make_unique>(context, pDevice, nullptr); - mockCsr->setupContext(*mockCmdQ->engine->osContext); + mockCsr->setupContext(*mockCmdQ->gpgpuEngine->osContext); mockCsr->initializeTagAllocation(); - auto oldCsr = mockCmdQ->engine->commandStreamReceiver; - mockCmdQ->engine->commandStreamReceiver = mockCsr.get(); + auto oldCsr = mockCmdQ->gpgpuEngine->commandStreamReceiver; + mockCmdQ->gpgpuEngine->commandStreamReceiver = mockCsr.get(); mockCsr->createPreemptionAllocation(); auto blocking = true; @@ -65,7 +65,7 @@ HWTEST_F(EnqueueHandlerTest, whenEnqueueCommandWithoutKernelThenPassCorrectDispa EXPECT_EQ(blocking, mockCsr->passedDispatchFlags.blocking); EXPECT_EQ(mockCmdQ->isMultiEngineQueue(), mockCsr->passedDispatchFlags.multiEngineQueue); EXPECT_EQ(pDevice->getPreemptionMode(), mockCsr->passedDispatchFlags.preemptionMode); - mockCmdQ->engine->commandStreamReceiver = oldCsr; + mockCmdQ->gpgpuEngine->commandStreamReceiver = oldCsr; } HWTEST_F(EnqueueHandlerTest, GivenCommandStreamWithoutKernelAndZeroSurfacesWhenEnqueuedHandlerThenUsedSizeEqualZero) { diff --git a/unit_tests/command_queue/enqueue_copy_buffer_rect_tests.cpp b/unit_tests/command_queue/enqueue_copy_buffer_rect_tests.cpp index a3358f891d..97590565bb 100644 --- a/unit_tests/command_queue/enqueue_copy_buffer_rect_tests.cpp +++ b/unit_tests/command_queue/enqueue_copy_buffer_rect_tests.cpp @@ -191,7 +191,7 @@ HWTEST_F(EnqueueCopyBufferRectTest, 2D_LoadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueCopyBufferRectTest, When2DEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueCopyBufferRect2D(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } @@ -313,7 +313,7 @@ HWTEST_F(EnqueueCopyBufferRectTest, 3D_LoadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueCopyBufferRectTest, When3DEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueCopyBufferRect3D(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } diff --git a/unit_tests/command_queue/enqueue_copy_buffer_tests.cpp b/unit_tests/command_queue/enqueue_copy_buffer_tests.cpp index f43f53be51..175b2b3270 100644 --- a/unit_tests/command_queue/enqueue_copy_buffer_tests.cpp +++ b/unit_tests/command_queue/enqueue_copy_buffer_tests.cpp @@ -161,7 +161,7 @@ HWTEST_F(EnqueueCopyBufferTest, LoadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueCopyBufferTest, WhenEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueCopyBufferAndParse(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } diff --git a/unit_tests/command_queue/enqueue_copy_buffer_to_image_tests.cpp b/unit_tests/command_queue/enqueue_copy_buffer_to_image_tests.cpp index 7f1240850a..f7d3c57bb4 100644 --- a/unit_tests/command_queue/enqueue_copy_buffer_to_image_tests.cpp +++ b/unit_tests/command_queue/enqueue_copy_buffer_to_image_tests.cpp @@ -92,7 +92,7 @@ HWTEST_F(EnqueueCopyBufferToImageTest, loadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueCopyBufferToImageTest, WhenEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueCopyBufferToImage(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } diff --git a/unit_tests/command_queue/enqueue_copy_image_tests.cpp b/unit_tests/command_queue/enqueue_copy_image_tests.cpp index a2f719b20c..912f108150 100644 --- a/unit_tests/command_queue/enqueue_copy_image_tests.cpp +++ b/unit_tests/command_queue/enqueue_copy_image_tests.cpp @@ -95,7 +95,7 @@ HWTEST_F(EnqueueCopyImageTest, loadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueCopyImageTest, WhenEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueCopyImage(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } diff --git a/unit_tests/command_queue/enqueue_copy_image_to_buffer_tests.cpp b/unit_tests/command_queue/enqueue_copy_image_to_buffer_tests.cpp index 9f676ba6b2..fa06e40991 100644 --- a/unit_tests/command_queue/enqueue_copy_image_to_buffer_tests.cpp +++ b/unit_tests/command_queue/enqueue_copy_image_to_buffer_tests.cpp @@ -93,7 +93,7 @@ HWTEST_F(EnqueueCopyImageToBufferTest, loadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueCopyImageToBufferTest, WhenEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueCopyImageToBuffer(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } diff --git a/unit_tests/command_queue/enqueue_debug_kernel_tests.cpp b/unit_tests/command_queue/enqueue_debug_kernel_tests.cpp index 5c73a0cb3c..d2d10017d6 100644 --- a/unit_tests/command_queue/enqueue_debug_kernel_tests.cpp +++ b/unit_tests/command_queue/enqueue_debug_kernel_tests.cpp @@ -104,7 +104,7 @@ HWTEST_F(EnqueueDebugKernelTest, givenDebugKernelWhenEnqueuedThenSSHAndBtiAreCor auto debugSurfaceState = reinterpret_cast(ptrOffset(ssh.getCpuBase(), surfaceStateOffset)); - auto &commandStreamReceiver = mockCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = mockCmdQ->getGpgpuCommandStreamReceiver(); auto debugSurface = commandStreamReceiver.getDebugSurfaceAllocation(); EXPECT_EQ(1u, debugSurface->getTaskCount(commandStreamReceiver.getOsContext().getContextId())); diff --git a/unit_tests/command_queue/enqueue_fill_buffer_tests.cpp b/unit_tests/command_queue/enqueue_fill_buffer_tests.cpp index e0f4506e97..a563d0ea64 100644 --- a/unit_tests/command_queue/enqueue_fill_buffer_tests.cpp +++ b/unit_tests/command_queue/enqueue_fill_buffer_tests.cpp @@ -208,7 +208,7 @@ HWTEST_F(EnqueueFillBufferCmdTests, LoadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueFillBufferCmdTests, WhenEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueFillBuffer(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } @@ -368,7 +368,7 @@ HWTEST_F(EnqueueFillBufferCmdTests, argumentTwoShouldMatchPatternPtr) { } HWTEST_F(EnqueueFillBufferCmdTests, patternShouldBeCopied) { - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); ASSERT_TRUE(csr.getTemporaryAllocations().peekIsEmpty()); EnqueueFillBufferHelper<>::enqueueFillBuffer(pCmdQ, buffer); ASSERT_FALSE(csr.getTemporaryAllocations().peekIsEmpty()); @@ -389,7 +389,7 @@ HWTEST_F(EnqueueFillBufferCmdTests, patternShouldBeCopied) { } HWTEST_F(EnqueueFillBufferCmdTests, patternShouldBeAligned) { - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); ASSERT_TRUE(csr.getTemporaryAllocations().peekIsEmpty()); EnqueueFillBufferHelper<>::enqueueFillBuffer(pCmdQ, buffer); ASSERT_FALSE(csr.getTemporaryAllocations().peekIsEmpty()); @@ -411,7 +411,7 @@ HWTEST_F(EnqueueFillBufferCmdTests, patternShouldBeAligned) { } HWTEST_F(EnqueueFillBufferCmdTests, patternOfSizeOneByteShouldGetPreparedForMiddleKernel) { - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); ASSERT_TRUE(csr.getAllocationsForReuse().peekIsEmpty()); ASSERT_TRUE(csr.getTemporaryAllocations().peekIsEmpty()); @@ -444,7 +444,7 @@ HWTEST_F(EnqueueFillBufferCmdTests, patternOfSizeOneByteShouldGetPreparedForMidd } HWTEST_F(EnqueueFillBufferCmdTests, patternOfSizeTwoBytesShouldGetPreparedForMiddleKernel) { - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); ASSERT_TRUE(csr.getAllocationsForReuse().peekIsEmpty()); ASSERT_TRUE(csr.getTemporaryAllocations().peekIsEmpty()); @@ -477,7 +477,7 @@ HWTEST_F(EnqueueFillBufferCmdTests, patternOfSizeTwoBytesShouldGetPreparedForMid } HWTEST_F(EnqueueFillBufferCmdTests, givenEnqueueFillBufferWhenPatternAllocationIsObtainedThenItsTypeShouldBeSetToFillPattern) { - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); ASSERT_TRUE(csr.getTemporaryAllocations().peekIsEmpty()); auto dstBuffer = std::unique_ptr(BufferHelper<>::create()); diff --git a/unit_tests/command_queue/enqueue_fill_image_tests.cpp b/unit_tests/command_queue/enqueue_fill_image_tests.cpp index a524b8d646..e60f6a92dc 100644 --- a/unit_tests/command_queue/enqueue_fill_image_tests.cpp +++ b/unit_tests/command_queue/enqueue_fill_image_tests.cpp @@ -103,7 +103,7 @@ HWTEST_F(EnqueueFillImageTest, loadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueFillImageTest, WhenEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueFillImage(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } diff --git a/unit_tests/command_queue/enqueue_handler_tests.cpp b/unit_tests/command_queue/enqueue_handler_tests.cpp index 71ceb509ac..3e0aafcf82 100644 --- a/unit_tests/command_queue/enqueue_handler_tests.cpp +++ b/unit_tests/command_queue/enqueue_handler_tests.cpp @@ -500,7 +500,7 @@ struct EnqueueHandlerTestBasic : public ::testing::Test { auto mockCmdQ = std::make_unique>(context.get(), device.get(), nullptr); - auto &ultCsr = static_cast &>(mockCmdQ->getCommandStreamReceiver()); + auto &ultCsr = static_cast &>(mockCmdQ->getGpgpuCommandStreamReceiver()); ultCsr.taskCount = initialTaskCount; mockInternalAllocationStorage = new MockInternalAllocationStorage(ultCsr); diff --git a/unit_tests/command_queue/enqueue_kernel_1_tests.cpp b/unit_tests/command_queue/enqueue_kernel_1_tests.cpp index e61a5d4db9..40df2851e3 100644 --- a/unit_tests/command_queue/enqueue_kernel_1_tests.cpp +++ b/unit_tests/command_queue/enqueue_kernel_1_tests.cpp @@ -294,7 +294,7 @@ TEST_F(EnqueueKernelTest, GivenKernelWithBuiltinDispatchInfoBuilderWhenBeingDisp HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueKernelTest, givenSecondEnqueueWithTheSameScratchRequirementWhenPreemptionIsEnabledThenDontProgramMVSAgain) { typedef typename FamilyType::MEDIA_VFE_STATE MEDIA_VFE_STATE; pDevice->setPreemptionMode(PreemptionMode::ThreadGroup); - auto &csr = pDevice->getCommandStreamReceiver(); + auto &csr = pDevice->getGpgpuCommandStreamReceiver(); csr.getMemoryManager()->setForce32BitAllocations(false); HardwareParse hwParser; size_t off[3] = {0, 0, 0}; diff --git a/unit_tests/command_queue/enqueue_kernel_2_tests.cpp b/unit_tests/command_queue/enqueue_kernel_2_tests.cpp index 4f270ff311..e18996b255 100644 --- a/unit_tests/command_queue/enqueue_kernel_2_tests.cpp +++ b/unit_tests/command_queue/enqueue_kernel_2_tests.cpp @@ -182,7 +182,7 @@ HWCMDTEST_P(IGFX_GEN8_CORE, EnqueueWorkItemTestsWithLimitedParamSet, LoadRegiste HWCMDTEST_P(IGFX_GEN8_CORE, EnqueueWorkItemTestsWithLimitedParamSet, WhenEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueKernel(); - validateStateBaseAddress(this->pDevice->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pDevice->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, context->getMemoryManager()->peekForce32BitAllocations() ? context->getMemoryManager()->getExternalHeapBaseAddress() : 0llu); } @@ -458,7 +458,7 @@ HWCMDTEST_P(IGFX_GEN8_CORE, EnqueueKernelWithScratch, givenDeviceForcing32bitAll typedef typename PARSE::STATE_BASE_ADDRESS STATE_BASE_ADDRESS; if (is64bit) { - CommandStreamReceiver *csr = &pDevice->getCommandStreamReceiver(); + CommandStreamReceiver *csr = &pDevice->getGpgpuCommandStreamReceiver(); auto memoryManager = csr->getMemoryManager(); memoryManager->setForce32BitAllocations(true); @@ -541,7 +541,7 @@ HWTEST_P(EnqueueKernelPrintfTest, GivenKernelWithPrintfWhenBeingDispatchedThenL3 MockKernelWithInternals mockKernel(*pDevice); mockKernel.crossThreadData[64] = 0; mockKernel.kernelInfo.patchInfo.pAllocateStatelessPrintfSurface = &patchData; - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto latestSentTaskCount = csr.peekTaskCount(); enqueueKernel(mockKernel); auto newLatestSentTaskCount = csr.peekTaskCount(); @@ -561,7 +561,7 @@ HWCMDTEST_P(IGFX_GEN8_CORE, EnqueueKernelPrintfTest, GivenKernelWithPrintfBlocke MockKernelWithInternals mockKernel(*pDevice); mockKernel.crossThreadData[64] = 0; mockKernel.kernelInfo.patchInfo.pAllocateStatelessPrintfSurface = &patchData; - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto latestSentDcFlushTaskCount = csr.peekTaskCount(); cl_uint workDim = 1; diff --git a/unit_tests/command_queue/enqueue_kernel_event_tests.cpp b/unit_tests/command_queue/enqueue_kernel_event_tests.cpp index 1e811395e6..91f60989f0 100644 --- a/unit_tests/command_queue/enqueue_kernel_event_tests.cpp +++ b/unit_tests/command_queue/enqueue_kernel_event_tests.cpp @@ -70,7 +70,7 @@ TEST_F(EventTests, eventWaitShouldntSendPC) { cl_event *eventWaitList = nullptr; cl_event event = nullptr; - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto retVal = callOneWorkItemNDRKernel(eventWaitList, numEventsInWaitList, &event); @@ -109,7 +109,7 @@ TEST_F(EventTests, waitForArray) { cl_event *eventWaitList = nullptr; cl_event event[2] = {}; - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto retVal = callOneWorkItemNDRKernel(eventWaitList, numEventsInWaitList, &event[0]); @@ -153,7 +153,7 @@ TEST_F(EventTests, event_NDR_Wait_NDR_Finish) { cl_event *eventWaitList = nullptr; cl_event event = nullptr; - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto retVal = callOneWorkItemNDRKernel(eventWaitList, numEventsInWaitList, &event); @@ -192,7 +192,7 @@ TEST_F(EventTests, eventPassedToEnqueueMarkerHasTheSameLevelAsPreviousCommand) { cl_uint numEventsInWaitList = 0; cl_event *eventWaitList = nullptr; cl_event event = nullptr; - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto retVal = callOneWorkItemNDRKernel(eventWaitList, numEventsInWaitList, &event); diff --git a/unit_tests/command_queue/enqueue_map_buffer_tests.cpp b/unit_tests/command_queue/enqueue_map_buffer_tests.cpp index a17742cdc5..0869cc83ad 100644 --- a/unit_tests/command_queue/enqueue_map_buffer_tests.cpp +++ b/unit_tests/command_queue/enqueue_map_buffer_tests.cpp @@ -285,7 +285,7 @@ TEST_F(EnqueueMapBufferTest, givenNonBlockingReadOnlyMapBufferOnZeroCopyBufferWh EXPECT_EQ(CL_SUCCESS, retVal); EXPECT_NE(nullptr, buffer); - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); uint32_t taskCount = commandStreamReceiver.peekTaskCount(); EXPECT_EQ(0u, taskCount); @@ -375,7 +375,7 @@ TEST_F(EnqueueMapBufferTest, givenNonReadOnlyBufferWhenMappedOnGpuThenSetValidEv EXPECT_EQ(CL_SUCCESS, retVal); EXPECT_NE(nullptr, buffer.get()); - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); EXPECT_EQ(0u, commandStreamReceiver.peekTaskCount()); auto ptrResult = clEnqueueMapBuffer(pCmdQ, buffer.get(), CL_FALSE, CL_MAP_WRITE, 0, 8, 0, @@ -417,7 +417,7 @@ TEST_F(EnqueueMapBufferTest, givenReadOnlyBufferWhenMappedOnGpuThenSetValidEvent EXPECT_EQ(CL_SUCCESS, retVal); EXPECT_NE(nullptr, buffer.get()); - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); EXPECT_EQ(0u, commandStreamReceiver.peekTaskCount()); auto ptrResult = clEnqueueMapBuffer(pCmdQ, buffer.get(), CL_FALSE, CL_MAP_READ, 0, 8, 0, @@ -463,7 +463,7 @@ TEST_F(EnqueueMapBufferTest, givenNonBlockingMapBufferAfterL3IsAlreadyFlushedThe EXPECT_EQ(CL_SUCCESS, retVal); EXPECT_NE(nullptr, buffer); - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); uint32_t taskCount = commandStreamReceiver.peekTaskCount(); EXPECT_EQ(0u, taskCount); @@ -544,7 +544,7 @@ TEST_F(EnqueueMapBufferTest, GivenBufferThatIsNotZeroCopyWhenNonBlockingMapIsCal retVal = clEnqueueNDRangeKernel(pCmdQ, kernel, 1, 0, &GWS, nullptr, 0, nullptr, nullptr); EXPECT_EQ(retVal, CL_SUCCESS); - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); uint32_t taskCount = commandStreamReceiver.peekTaskCount(); EXPECT_EQ(1u, taskCount); @@ -641,7 +641,7 @@ HWTEST_F(EnqueueMapBufferTest, MapBufferEventProperties) { } TEST_F(EnqueueMapBufferTest, GivenZeroCopyBufferWhenMapBufferWithoutEventsThenCommandStreamReceiverUpdatesRequiredDCFlushCount) { - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); auto buffer = clCreateBuffer( BufferDefaults::context, diff --git a/unit_tests/command_queue/enqueue_map_image_tests.cpp b/unit_tests/command_queue/enqueue_map_image_tests.cpp index 8dd795365b..b76a6fe554 100644 --- a/unit_tests/command_queue/enqueue_map_image_tests.cpp +++ b/unit_tests/command_queue/enqueue_map_image_tests.cpp @@ -226,8 +226,8 @@ HWTEST_F(EnqueueMapImageTest, givenTiledImageWhenMapImageIsCalledThenStorageIsSe EXPECT_NE(nullptr, mapAllocation); EXPECT_EQ(apiMapPtr, mapAllocation->getUnderlyingBuffer()); - auto osContextId = pCmdQ->getCommandStreamReceiver().getOsContext().getContextId(); - auto expectedTaskCount = pCmdQ->getCommandStreamReceiver().peekTaskCount(); + auto osContextId = pCmdQ->getGpgpuCommandStreamReceiver().getOsContext().getContextId(); + auto expectedTaskCount = pCmdQ->getGpgpuCommandStreamReceiver().peekTaskCount(); auto actualMapAllocationTaskCount = mapAllocation->getTaskCount(osContextId); EXPECT_EQ(expectedTaskCount, actualMapAllocationTaskCount); @@ -312,7 +312,7 @@ TEST_F(EnqueueMapImageTest, givenNonReadOnlyMapWithOutEventWhenMappedThenSetEven MockKernelWithInternals kernel(*pDevice); *pTagMemory = tagHW; - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); auto tag_address = commandStreamReceiver.getTagAddress(); EXPECT_TRUE(pTagMemory == tag_address); @@ -391,7 +391,7 @@ TEST_F(EnqueueMapImageTest, givenReadOnlyMapWithOutEventWhenMappedThenSetEventAn const size_t region[3] = {1, 1, 1}; *pTagMemory = 5; - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); EXPECT_EQ(1u, commandStreamReceiver.peekTaskCount()); diff --git a/unit_tests/command_queue/enqueue_marker_tests.cpp b/unit_tests/command_queue/enqueue_marker_tests.cpp index c90e9a9258..597976a86b 100644 --- a/unit_tests/command_queue/enqueue_marker_tests.cpp +++ b/unit_tests/command_queue/enqueue_marker_tests.cpp @@ -191,7 +191,7 @@ TEST_F(MarkerTest, givenMultipleEventWhenTheyArePassedToMarkerThenOutputEventHas std::unique_ptr pEvent((Event *)(event)); - if (pCmdQ->getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + if (pCmdQ->getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { EXPECT_EQ(initialTaskCount + 1, pCmdQ->taskCount); EXPECT_EQ(initialTaskCount + 1, pEvent->peekTaskCount()); } else { @@ -225,7 +225,7 @@ TEST_F(MarkerTest, givenMultipleEventsAndCompletedUserEventWhenTheyArePassedToMa std::unique_ptr pEvent((Event *)(event)); - if (pCmdQ->getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + if (pCmdQ->getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { EXPECT_EQ(initialTaskCount + 1, pCmdQ->taskCount); EXPECT_EQ(initialTaskCount + 1, pEvent->peekTaskCount()); } else { diff --git a/unit_tests/command_queue/enqueue_read_buffer_event_tests.cpp b/unit_tests/command_queue/enqueue_read_buffer_event_tests.cpp index 1d1eee4f76..8c7a64e600 100644 --- a/unit_tests/command_queue/enqueue_read_buffer_event_tests.cpp +++ b/unit_tests/command_queue/enqueue_read_buffer_event_tests.cpp @@ -335,7 +335,7 @@ TEST_F(EnqueueReadBuffer, givenOutOfOrderQueueAndDisabledSupportCpuCopiesAndDstP ASSERT_NE(nullptr, event); auto pEvent = castToObject(event); - if (pCmdOOQ->getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + if (pCmdOOQ->getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { EXPECT_EQ(taskLevelEvent2 + 1, pCmdOOQ->taskLevel); EXPECT_EQ(taskLevelEvent2 + 1, pEvent->taskLevel); } else { diff --git a/unit_tests/command_queue/enqueue_read_buffer_rect_tests.cpp b/unit_tests/command_queue/enqueue_read_buffer_rect_tests.cpp index fd79129a33..b959ac3c0b 100644 --- a/unit_tests/command_queue/enqueue_read_buffer_rect_tests.cpp +++ b/unit_tests/command_queue/enqueue_read_buffer_rect_tests.cpp @@ -205,7 +205,7 @@ HWTEST_F(EnqueueReadBufferRectTest, 2D_LoadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueReadBufferRectTest, When2DEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueReadBufferRect2D(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } diff --git a/unit_tests/command_queue/enqueue_read_buffer_tests.cpp b/unit_tests/command_queue/enqueue_read_buffer_tests.cpp index 62ef5f86e3..8b49c1570a 100644 --- a/unit_tests/command_queue/enqueue_read_buffer_tests.cpp +++ b/unit_tests/command_queue/enqueue_read_buffer_tests.cpp @@ -168,7 +168,7 @@ HWTEST_F(EnqueueReadBufferTypeTest, LoadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueReadBufferTypeTest, WhenEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { srcBuffer->forceDisallowCPUCopy = true; enqueueReadBuffer(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } diff --git a/unit_tests/command_queue/enqueue_read_image_tests.cpp b/unit_tests/command_queue/enqueue_read_image_tests.cpp index c609819584..0fb40d41cf 100644 --- a/unit_tests/command_queue/enqueue_read_image_tests.cpp +++ b/unit_tests/command_queue/enqueue_read_image_tests.cpp @@ -105,7 +105,7 @@ HWTEST_F(EnqueueReadImageTest, loadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueReadImageTest, WhenEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueReadImage(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } @@ -228,7 +228,7 @@ HWTEST_F(EnqueueReadImageTest, GivenImage1DarrayWhenReadImageIsCalledThenHostPtr EnqueueReadImageHelper<>::enqueueReadImage(pCmdQ, srcImage, CL_FALSE, origin, region); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto temporaryAllocation = csr.getTemporaryAllocations().peekHead(); ASSERT_NE(nullptr, temporaryAllocation); @@ -287,7 +287,7 @@ HWTEST_F(EnqueueReadImageTest, GivenImage2DarrayWhenReadImageIsCalledThenHostPtr EnqueueReadImageHelper<>::enqueueReadImage(pCmdQ, srcImage, CL_FALSE, origin, region); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto temporaryAllocation = csr.getTemporaryAllocations().peekHead(); ASSERT_NE(nullptr, temporaryAllocation); diff --git a/unit_tests/command_queue/enqueue_svm_tests.cpp b/unit_tests/command_queue/enqueue_svm_tests.cpp index 0229d24d3e..c2431e145d 100644 --- a/unit_tests/command_queue/enqueue_svm_tests.cpp +++ b/unit_tests/command_queue/enqueue_svm_tests.cpp @@ -571,7 +571,7 @@ TEST_F(EnqueueSvmTest, enqueueSVMMemFillDoubleToReuseAllocation_Success) { } TEST_F(EnqueueSvmTest, givenEnqueueSVMMemFillWhenPatternAllocationIsObtainedThenItsTypeShouldBeSetToFillPattern) { - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); ASSERT_TRUE(csr.getAllocationsForReuse().peekIsEmpty()); const float pattern[1] = {1.2345f}; @@ -1086,8 +1086,8 @@ HWTEST_F(EnqueueSvmTest, GivenDstHostPtrWhenHostPtrAllocationCreationFailsThenRe void *pSrcSVM = ptrSVM; MockCommandQueueHw cmdQ(context, pDevice, nullptr); auto failCsr = std::make_unique>(*pDevice->getExecutionEnvironment()); - CommandStreamReceiver *oldCommandStreamReceiver = cmdQ.engine->commandStreamReceiver; - cmdQ.engine->commandStreamReceiver = failCsr.get(); + CommandStreamReceiver *oldCommandStreamReceiver = cmdQ.gpgpuEngine->commandStreamReceiver; + cmdQ.gpgpuEngine->commandStreamReceiver = failCsr.get(); retVal = cmdQ.enqueueSVMMemcpy( false, // cl_bool blocking_copy pDstSVM, // void *dst_ptr @@ -1098,7 +1098,7 @@ HWTEST_F(EnqueueSvmTest, GivenDstHostPtrWhenHostPtrAllocationCreationFailsThenRe nullptr // cL_event *event ); EXPECT_EQ(CL_OUT_OF_RESOURCES, retVal); - cmdQ.engine->commandStreamReceiver = oldCommandStreamReceiver; + cmdQ.gpgpuEngine->commandStreamReceiver = oldCommandStreamReceiver; } HWTEST_F(EnqueueSvmTest, GivenSrcHostPtrAndSizeZeroWhenHostPtrAllocationCreationFailsThenReturnOutOfResource) { @@ -1107,8 +1107,8 @@ HWTEST_F(EnqueueSvmTest, GivenSrcHostPtrAndSizeZeroWhenHostPtrAllocationCreation void *pSrcSVM = srcHostPtr; MockCommandQueueHw cmdQ(context, pDevice, nullptr); auto failCsr = std::make_unique>(*pDevice->getExecutionEnvironment()); - CommandStreamReceiver *oldCommandStreamReceiver = cmdQ.engine->commandStreamReceiver; - cmdQ.engine->commandStreamReceiver = failCsr.get(); + CommandStreamReceiver *oldCommandStreamReceiver = cmdQ.gpgpuEngine->commandStreamReceiver; + cmdQ.gpgpuEngine->commandStreamReceiver = failCsr.get(); retVal = cmdQ.enqueueSVMMemcpy( false, // cl_bool blocking_copy pDstSVM, // void *dst_ptr @@ -1119,5 +1119,5 @@ HWTEST_F(EnqueueSvmTest, GivenSrcHostPtrAndSizeZeroWhenHostPtrAllocationCreation nullptr // cL_event *event ); EXPECT_EQ(CL_OUT_OF_RESOURCES, retVal); - cmdQ.engine->commandStreamReceiver = oldCommandStreamReceiver; + cmdQ.gpgpuEngine->commandStreamReceiver = oldCommandStreamReceiver; } diff --git a/unit_tests/command_queue/enqueue_thread_tests.cpp b/unit_tests/command_queue/enqueue_thread_tests.cpp index ac61368d7a..d5122db90f 100644 --- a/unit_tests/command_queue/enqueue_thread_tests.cpp +++ b/unit_tests/command_queue/enqueue_thread_tests.cpp @@ -420,7 +420,7 @@ HWTEST_F(EnqueueThreading, finish) { // set something to finish pCmdQ->taskCount = 1; pCmdQ->taskLevel = 1; - auto csr = (CommandStreamReceiverMock *)&this->pCmdQ->getCommandStreamReceiver(); + auto csr = (CommandStreamReceiverMock *)&this->pCmdQ->getGpgpuCommandStreamReceiver(); csr->expectedToFreeCount = 0u; pCmdQ->finish(false); diff --git a/unit_tests/command_queue/enqueue_write_buffer_event_tests.cpp b/unit_tests/command_queue/enqueue_write_buffer_event_tests.cpp index 46b085e31d..750d188af2 100644 --- a/unit_tests/command_queue/enqueue_write_buffer_event_tests.cpp +++ b/unit_tests/command_queue/enqueue_write_buffer_event_tests.cpp @@ -334,7 +334,7 @@ TEST_F(EnqueueWriteBufferTypeTest, givenOutOfOrderQueueAndDisabledSupportCpuCopi ASSERT_NE(nullptr, event); auto pEvent = castToObject(event); - if (pCmdOOQ->getCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { + if (pCmdOOQ->getGpgpuCommandStreamReceiver().peekTimestampPacketWriteEnabled()) { EXPECT_EQ(taskLevelEvent2 + 1, pCmdOOQ->taskLevel); EXPECT_EQ(taskLevelEvent2 + 1, pEvent->taskLevel); } else { diff --git a/unit_tests/command_queue/enqueue_write_buffer_rect_tests.cpp b/unit_tests/command_queue/enqueue_write_buffer_rect_tests.cpp index 85fdb9621e..39c72052a8 100644 --- a/unit_tests/command_queue/enqueue_write_buffer_rect_tests.cpp +++ b/unit_tests/command_queue/enqueue_write_buffer_rect_tests.cpp @@ -179,7 +179,7 @@ HWTEST_F(EnqueueWriteBufferRectTest, 2D_LoadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueWriteBufferRectTest, When2DEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueWriteBufferRect2D(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } diff --git a/unit_tests/command_queue/enqueue_write_buffer_tests.cpp b/unit_tests/command_queue/enqueue_write_buffer_tests.cpp index 1d3c430198..f7cf419acf 100644 --- a/unit_tests/command_queue/enqueue_write_buffer_tests.cpp +++ b/unit_tests/command_queue/enqueue_write_buffer_tests.cpp @@ -168,7 +168,7 @@ HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueWriteBufferTypeTest, WhenEnqueueIsDoneThenSta srcBuffer->forceDisallowCPUCopy = true; enqueueWriteBuffer(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } diff --git a/unit_tests/command_queue/enqueue_write_image_tests.cpp b/unit_tests/command_queue/enqueue_write_image_tests.cpp index b8bf6252ae..2af54adde0 100644 --- a/unit_tests/command_queue/enqueue_write_image_tests.cpp +++ b/unit_tests/command_queue/enqueue_write_image_tests.cpp @@ -104,7 +104,7 @@ HWTEST_F(EnqueueWriteImageTest, loadRegisterImmediateL3CNTLREG) { HWCMDTEST_F(IGFX_GEN8_CORE, EnqueueWriteImageTest, WhenEnqueueIsDoneThenStateBaseAddressIsProperlyProgrammed) { enqueueWriteImage(); - validateStateBaseAddress(this->pCmdQ->getCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), + validateStateBaseAddress(this->pCmdQ->getGpgpuCommandStreamReceiver().getMemoryManager()->getInternalHeapBaseAddress(), pDSH, pIOH, pSSH, itorPipelineSelect, itorWalker, cmdList, 0llu); } @@ -201,7 +201,7 @@ HWTEST_F(EnqueueWriteImageTest, GivenImage1DarrayWhenReadWriteImageIsCalledThenH EnqueueWriteImageHelper<>::enqueueWriteImage(pCmdQ, dstImage2, CL_FALSE, origin, region); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto temporaryAllocation1 = csr.getTemporaryAllocations().peekHead(); ASSERT_NE(nullptr, temporaryAllocation1); @@ -267,7 +267,7 @@ HWTEST_F(EnqueueWriteImageTest, GivenImage2DarrayWhenReadWriteImageIsCalledThenH EnqueueWriteImageHelper<>::enqueueWriteImage(pCmdQ, dstImage2, CL_FALSE, origin, region); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto temporaryAllocation1 = csr.getTemporaryAllocations().peekHead(); ASSERT_NE(nullptr, temporaryAllocation1); diff --git a/unit_tests/command_queue/ioq_task_tests.cpp b/unit_tests/command_queue/ioq_task_tests.cpp index 07897afdd8..aa8c728290 100644 --- a/unit_tests/command_queue/ioq_task_tests.cpp +++ b/unit_tests/command_queue/ioq_task_tests.cpp @@ -39,7 +39,7 @@ TEST_F(IOQ, enqueueReadBuffer_increasesTaskLevel) { } TEST_F(IOQ, enqueueKernel_changesTaskCount) { - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); auto previousTaskCount = commandStreamReceiver.peekTaskCount(); EnqueueKernelHelper<>::enqueueKernel(pCmdQ, @@ -49,7 +49,7 @@ TEST_F(IOQ, enqueueKernel_changesTaskCount) { } TEST_F(IOQ, enqueueFillBuffer_changesTaskCount) { - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); auto previousTaskCount = commandStreamReceiver.peekTaskCount(); EnqueueFillBufferHelper<>::enqueue(pCmdQ); @@ -58,7 +58,7 @@ TEST_F(IOQ, enqueueFillBuffer_changesTaskCount) { } TEST_F(IOQ, enqueueReadBuffer_changesTaskCount) { - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); auto previousTaskCount = commandStreamReceiver.peekTaskCount(); auto buffer = std::unique_ptr(BufferHelper<>::create()); diff --git a/unit_tests/command_queue/ooq_task_tests.cpp b/unit_tests/command_queue/ooq_task_tests.cpp index a932547260..09c892ea14 100644 --- a/unit_tests/command_queue/ooq_task_tests.cpp +++ b/unit_tests/command_queue/ooq_task_tests.cpp @@ -33,7 +33,7 @@ bool isBlockingCall(unsigned int cmdType) { } TYPED_TEST_P(OOQTaskTypedTests, givenNonBlockingCallWhenDoneOnOutOfOrderQueueThenTaskLevelDoesntChange) { - auto &commandStreamReceiver = this->pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = this->pCmdQ->getGpgpuCommandStreamReceiver(); auto tagAddress = commandStreamReceiver.getTagAddress(); auto blockingCall = isBlockingCall(TypeParam::Traits::cmdType); @@ -60,7 +60,7 @@ TYPED_TEST_P(OOQTaskTypedTests, givenNonBlockingCallWhenDoneOnOutOfOrderQueueThe } TYPED_TEST_P(OOQTaskTypedTests, givenTaskWhenEnqueuedOnOutOfOrderQueueThenTaskCountIsUpdated) { - auto &commandStreamReceiver = this->pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = this->pCmdQ->getGpgpuCommandStreamReceiver(); auto previousTaskCount = commandStreamReceiver.peekTaskCount(); auto tagAddress = commandStreamReceiver.getTagAddress(); auto blockingCall = isBlockingCall(TypeParam::Traits::cmdType); @@ -104,7 +104,7 @@ INSTANTIATE_TYPED_TEST_CASE_P(OOQ, OOQTaskTypedTests, EnqueueParams); typedef OOQTaskTypedTests> OOQTaskTests; TEST_F(OOQTaskTests, enqueueKernel_changesTaskCount) { - auto &commandStreamReceiver = pCmdQ->getCommandStreamReceiver(); + auto &commandStreamReceiver = pCmdQ->getGpgpuCommandStreamReceiver(); auto previousTaskCount = commandStreamReceiver.peekTaskCount(); EnqueueKernelHelper<>::enqueueKernel(this->pCmdQ, diff --git a/unit_tests/command_stream/command_stream_receiver_flush_task_1_tests.cpp b/unit_tests/command_stream/command_stream_receiver_flush_task_1_tests.cpp index de41a10564..c6905bf544 100644 --- a/unit_tests/command_stream/command_stream_receiver_flush_task_1_tests.cpp +++ b/unit_tests/command_stream/command_stream_receiver_flush_task_1_tests.cpp @@ -820,7 +820,7 @@ HWTEST_F(CommandStreamReceiverFlushTaskTests, flushTaskWithBothCSCallsChainsWith typedef Test CommandStreamReceiverCQFlushTaskTests; HWTEST_F(CommandStreamReceiverCQFlushTaskTests, getCSShouldReturnACSWithEnoughSizeCSRTraffic) { CommandQueueHw commandQueue(nullptr, pDevice, 0); - auto &commandStreamReceiver = commandQueue.getCommandStreamReceiver(); + auto &commandStreamReceiver = commandQueue.getGpgpuCommandStreamReceiver(); // NOTE: This test attempts to reserve the maximum amount // of memory such that if a client gets everything he wants @@ -926,7 +926,7 @@ HWTEST_F(CommandStreamReceiverFlushTaskTests, FlushTaskBlockingHasPipeControlWit CommandQueueHw commandQueue(nullptr, pDevice, 0); configureCSRtoNonDirtyState(); - auto &commandStreamReceiver = commandQueue.getCommandStreamReceiver(); + auto &commandStreamReceiver = commandQueue.getGpgpuCommandStreamReceiver(); size_t pipeControlCount = PipeControlHelper::getSizeForPipeControlWithPostSyncOperation() / sizeof(PIPE_CONTROL); diff --git a/unit_tests/command_stream/command_stream_receiver_flush_task_2_tests.cpp b/unit_tests/command_stream/command_stream_receiver_flush_task_2_tests.cpp index 930b09134e..060967439a 100644 --- a/unit_tests/command_stream/command_stream_receiver_flush_task_2_tests.cpp +++ b/unit_tests/command_stream/command_stream_receiver_flush_task_2_tests.cpp @@ -301,7 +301,7 @@ HWCMDTEST_F(IGFX_GEN8_CORE, CommandStreamReceiverFlushTaskTests, CommandQueueHw commandQueue(&ctx, pDevice, 0); cl_event event = nullptr; - auto &commandStreamReceiver = pDevice->getCommandStreamReceiver(); + auto &commandStreamReceiver = pDevice->getGpgpuCommandStreamReceiver(); auto &commandStreamTask = commandQueue.getCS(1024); size_t tempBuffer[] = {0, 1, 2}; @@ -932,7 +932,7 @@ HWCMDTEST_F(IGFX_GEN8_CORE, CommandStreamReceiverFlushTaskTests, flushTaskWithPC } HWTEST_F(CommandStreamReceiverFlushTaskTests, givenCsrWhenPreambleSentThenRequiredCsrSizeDependsOnL3ConfigChanged) { - UltCommandStreamReceiver &commandStreamReceiver = (UltCommandStreamReceiver &)pDevice->getCommandStreamReceiver(); + UltCommandStreamReceiver &commandStreamReceiver = (UltCommandStreamReceiver &)pDevice->getGpgpuCommandStreamReceiver(); CsrSizeRequestFlags csrSizeRequest = {}; commandStreamReceiver.isPreambleSent = true; @@ -950,7 +950,7 @@ HWTEST_F(CommandStreamReceiverFlushTaskTests, givenCsrWhenPreambleSentThenRequir } HWTEST_F(CommandStreamReceiverFlushTaskTests, givenCsrWhenPreambleNotSentThenRequiredCsrSizeDoesntDependOnL3ConfigChanged) { - UltCommandStreamReceiver &commandStreamReceiver = (UltCommandStreamReceiver &)pDevice->getCommandStreamReceiver(); + UltCommandStreamReceiver &commandStreamReceiver = (UltCommandStreamReceiver &)pDevice->getGpgpuCommandStreamReceiver(); CsrSizeRequestFlags csrSizeRequest = {}; commandStreamReceiver.isPreambleSent = false; @@ -966,7 +966,7 @@ HWTEST_F(CommandStreamReceiverFlushTaskTests, givenCsrWhenPreambleNotSentThenReq } HWTEST_F(CommandStreamReceiverFlushTaskTests, givenCsrWhenPreambleNotSentThenRequiredCsrSizeDoesntDependOnmediaSamplerConfigChanged) { - UltCommandStreamReceiver &commandStreamReceiver = (UltCommandStreamReceiver &)pDevice->getCommandStreamReceiver(); + UltCommandStreamReceiver &commandStreamReceiver = (UltCommandStreamReceiver &)pDevice->getGpgpuCommandStreamReceiver(); CsrSizeRequestFlags csrSizeRequest = {}; DispatchFlags flags; commandStreamReceiver.isPreambleSent = false; @@ -984,7 +984,7 @@ HWTEST_F(CommandStreamReceiverFlushTaskTests, givenCsrWhenPreambleNotSentThenReq HWTEST_F(CommandStreamReceiverFlushTaskTests, givenCsrWhenPreambleSentThenRequiredCsrSizeDependsOnmediaSamplerConfigChanged) { typedef typename FamilyType::PIPELINE_SELECT PIPELINE_SELECT; - UltCommandStreamReceiver &commandStreamReceiver = (UltCommandStreamReceiver &)pDevice->getCommandStreamReceiver(); + UltCommandStreamReceiver &commandStreamReceiver = (UltCommandStreamReceiver &)pDevice->getGpgpuCommandStreamReceiver(); CsrSizeRequestFlags csrSizeRequest = {}; DispatchFlags flags; commandStreamReceiver.isPreambleSent = true; @@ -1004,7 +1004,7 @@ HWTEST_F(CommandStreamReceiverFlushTaskTests, givenCsrWhenPreambleSentThenRequir HWTEST_F(CommandStreamReceiverFlushTaskTests, givenCsrWhenSamplerCacheFlushSentThenRequiredCsrSizeContainsPipecontrolSize) { typedef typename FamilyType::PIPELINE_SELECT PIPELINE_SELECT; - UltCommandStreamReceiver &commandStreamReceiver = (UltCommandStreamReceiver &)pDevice->getCommandStreamReceiver(); + UltCommandStreamReceiver &commandStreamReceiver = (UltCommandStreamReceiver &)pDevice->getGpgpuCommandStreamReceiver(); CsrSizeRequestFlags csrSizeRequest = {}; DispatchFlags flags; commandStreamReceiver.isPreambleSent = true; diff --git a/unit_tests/command_stream/command_stream_receiver_flush_task_3_tests.cpp b/unit_tests/command_stream/command_stream_receiver_flush_task_3_tests.cpp index c6f302caf8..37fc4c7647 100644 --- a/unit_tests/command_stream/command_stream_receiver_flush_task_3_tests.cpp +++ b/unit_tests/command_stream/command_stream_receiver_flush_task_3_tests.cpp @@ -509,7 +509,7 @@ HWTEST_F(CommandStreamReceiverFlushTaskTests, givenCsrInDefaultModeWhenFlushTask DispatchFlags dispatchFlags; dispatchFlags.guardCommandBufferWithPipeControl = true; dispatchFlags.preemptionMode = PreemptionHelper::getDefaultPreemptionMode(pDevice->getHardwareInfo()); - auto &csr = commandQueue.getCommandStreamReceiver(); + auto &csr = commandQueue.getGpgpuCommandStreamReceiver(); csr.flushTask(commandStream, 0, @@ -1452,7 +1452,7 @@ HWTEST_F(CommandStreamReceiverFlushTaskTests, GivenBlockedKernelWhenItIsUnblocke using UniqueIH = std::unique_ptr; auto blockedCommandsData = new KernelOperation(std::unique_ptr(cmdStream), UniqueIH(dsh), - UniqueIH(ioh), UniqueIH(ssh), *pCmdQ->getCommandStreamReceiver().getInternalAllocationStorage()); + UniqueIH(ioh), UniqueIH(ssh), *pCmdQ->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); std::vector surfaces; event->setCommand(std::make_unique(*pCmdQ, std::unique_ptr(blockedCommandsData), surfaces, false, false, false, nullptr, pDevice->getPreemptionMode(), pKernel.get(), 1)); diff --git a/unit_tests/command_stream/command_stream_receiver_hw_tests.cpp b/unit_tests/command_stream/command_stream_receiver_hw_tests.cpp index 84c1e61555..017c96cc87 100644 --- a/unit_tests/command_stream/command_stream_receiver_hw_tests.cpp +++ b/unit_tests/command_stream/command_stream_receiver_hw_tests.cpp @@ -226,7 +226,7 @@ HWTEST_F(CommandStreamReceiverHwTest, givenCsrHwWhenTypeIsCheckedThenCsrHwIsRetu } HWCMDTEST_F(IGFX_GEN8_CORE, CommandStreamReceiverHwTest, WhenCommandStreamReceiverHwIsCreatedThenDefaultSshSizeIs64KB) { - auto &commandStreamReceiver = pDevice->getCommandStreamReceiver(); + auto &commandStreamReceiver = pDevice->getGpgpuCommandStreamReceiver(); EXPECT_EQ(64 * KB, commandStreamReceiver.defaultSshSize); } @@ -271,7 +271,7 @@ struct BcsTests : public CommandStreamReceiverHwTest { void SetUp() override { CommandStreamReceiverHwTest::SetUp(); - auto &csr = pDevice->getCommandStreamReceiver(); + auto &csr = pDevice->getGpgpuCommandStreamReceiver(); auto engine = csr.getMemoryManager()->getRegisteredEngineForCsr(&csr); auto contextId = engine->osContext->getContextId(); @@ -766,7 +766,7 @@ struct MockScratchSpaceController : ScratchSpaceControllerBase { using ScratchSpaceControllerTest = Test; TEST_F(ScratchSpaceControllerTest, whenScratchSpaceControllerIsDestroyedThenItReleasePrivateScratchSpaceAllocation) { - MockScratchSpaceController scratchSpaceController(*pDevice->getExecutionEnvironment(), *pDevice->getCommandStreamReceiver().getInternalAllocationStorage()); + MockScratchSpaceController scratchSpaceController(*pDevice->getExecutionEnvironment(), *pDevice->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); scratchSpaceController.privateScratchAllocation = pDevice->getExecutionEnvironment()->memoryManager->allocateGraphicsMemoryInPreferredPool(MockAllocationProperties{MemoryConstants::pageSize}, nullptr); EXPECT_NE(nullptr, scratchSpaceController.privateScratchAllocation); //no memory leak is expected diff --git a/unit_tests/command_stream/command_stream_receiver_tests.cpp b/unit_tests/command_stream/command_stream_receiver_tests.cpp index a0cc2e0cb3..8c87db41c7 100644 --- a/unit_tests/command_stream/command_stream_receiver_tests.cpp +++ b/unit_tests/command_stream/command_stream_receiver_tests.cpp @@ -41,7 +41,7 @@ struct CommandStreamReceiverTest : public DeviceFixture, void SetUp() override { DeviceFixture::SetUp(); - commandStreamReceiver = &pDevice->getCommandStreamReceiver(); + commandStreamReceiver = &pDevice->getGpgpuCommandStreamReceiver(); ASSERT_NE(nullptr, commandStreamReceiver); memoryManager = commandStreamReceiver->getMemoryManager(); internalAllocationStorage = commandStreamReceiver->getInternalAllocationStorage(); @@ -460,7 +460,7 @@ struct CreateAllocationForHostSurfaceTest : public ::testing::Test { gmockMemoryManager = new ::testing::NiceMock(*executionEnvironment); executionEnvironment->memoryManager.reset(gmockMemoryManager); device.reset(MockDevice::create(executionEnvironment, 0u)); - commandStreamReceiver = &device->getCommandStreamReceiver(); + commandStreamReceiver = &device->getGpgpuCommandStreamReceiver(); } HardwareInfo hwInfo = *platformDevices[0]; ExecutionEnvironment *executionEnvironment = nullptr; diff --git a/unit_tests/command_stream/experimental_command_buffer_tests.cpp b/unit_tests/command_stream/experimental_command_buffer_tests.cpp index 9e014a48b8..9ee8499c09 100644 --- a/unit_tests/command_stream/experimental_command_buffer_tests.cpp +++ b/unit_tests/command_stream/experimental_command_buffer_tests.cpp @@ -31,8 +31,8 @@ struct ExperimentalCommandBufferTest : public UltCommandStreamReceiverTest { struct MockExperimentalCommandBufferTest : public UltCommandStreamReceiverTest { void SetUp() override { UltCommandStreamReceiverTest::SetUp(); - pDevice->getCommandStreamReceiver().setExperimentalCmdBuffer( - std::unique_ptr(new MockExperimentalCommandBuffer(&pDevice->getCommandStreamReceiver()))); + pDevice->getGpgpuCommandStreamReceiver().setExperimentalCmdBuffer( + std::unique_ptr(new MockExperimentalCommandBuffer(&pDevice->getGpgpuCommandStreamReceiver()))); } }; diff --git a/unit_tests/device/device_tests.cpp b/unit_tests/device/device_tests.cpp index 7d94feed1e..436094fc88 100644 --- a/unit_tests/device/device_tests.cpp +++ b/unit_tests/device/device_tests.cpp @@ -38,7 +38,7 @@ TEST_F(DeviceTest, givenDeviceWhenGetProductAbbrevThenReturnsHardwarePrefix) { } TEST_F(DeviceTest, getCommandStreamReceiver) { - EXPECT_NE(nullptr, &pDevice->getCommandStreamReceiver()); + EXPECT_NE(nullptr, &pDevice->getGpgpuCommandStreamReceiver()); } TEST_F(DeviceTest, getSupportedClVersion) { diff --git a/unit_tests/device_queue/device_queue_hw_tests.cpp b/unit_tests/device_queue/device_queue_hw_tests.cpp index 6dbad5add0..140c049d85 100644 --- a/unit_tests/device_queue/device_queue_hw_tests.cpp +++ b/unit_tests/device_queue/device_queue_hw_tests.cpp @@ -353,7 +353,7 @@ HWCMDTEST_F(IGFX_GEN8_CORE, DeviceQueueSlb, AddEMCleanupSectionWithProfiling) { MockParentKernel *mockParentKernel = MockParentKernel::create(*pContext); uint32_t taskCount = 7; - auto hwTimeStamp = pCommandQueue->getCommandStreamReceiver().getEventTsAllocator()->getTag(); + auto hwTimeStamp = pCommandQueue->getGpgpuCommandStreamReceiver().getEventTsAllocator()->getTag(); mockDeviceQueueHw->buildSlbDummyCommands(); mockDeviceQueueHw->addExecutionModelCleanUpSection(mockParentKernel, hwTimeStamp, taskCount); diff --git a/unit_tests/event/event_tests.cpp b/unit_tests/event/event_tests.cpp index d42eb7e08e..47c53e535c 100644 --- a/unit_tests/event/event_tests.cpp +++ b/unit_tests/event/event_tests.cpp @@ -414,8 +414,8 @@ TEST_F(UpdateEventTest, givenEventContainingCommandQueueWhenItsStatusIsUpdatedTo void *ptr = (void *)0x1000; size_t size = 4096; auto temporary = memoryManager->allocateGraphicsMemoryWithProperties(MockAllocationProperties{false, size}, ptr); - temporary->updateTaskCount(3, commandQueue->getCommandStreamReceiver().getOsContext().getContextId()); - commandQueue->getCommandStreamReceiver().getInternalAllocationStorage()->storeAllocation(std::unique_ptr(temporary), TEMPORARY_ALLOCATION); + temporary->updateTaskCount(3, commandQueue->getGpgpuCommandStreamReceiver().getOsContext().getContextId()); + commandQueue->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()->storeAllocation(std::unique_ptr(temporary), TEMPORARY_ALLOCATION); Event event(commandQueue.get(), CL_COMMAND_NDRANGE_KERNEL, 3, 3); EXPECT_EQ(1u, hostPtrManager->getFragmentCount()); @@ -468,12 +468,12 @@ TEST_F(InternalsEventTest, processBlockedCommandsKernelOperation) { using UniqueIH = std::unique_ptr; auto blockedCommandsData = new KernelOperation(std::unique_ptr(cmdStream), UniqueIH(dsh), UniqueIH(ioh), UniqueIH(ssh), - *cmdQ.getCommandStreamReceiver().getInternalAllocationStorage()); + *cmdQ.getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); MockKernelWithInternals mockKernelWithInternals(*pDevice); auto pKernel = mockKernelWithInternals.mockKernel; - auto &csr = cmdQ.getCommandStreamReceiver(); + auto &csr = cmdQ.getGpgpuCommandStreamReceiver(); std::vector v; SurfaceMock *surface = new SurfaceMock; surface->graphicsAllocation = new MockGraphicsAllocation((void *)0x1234, 100u); @@ -507,12 +507,12 @@ TEST_F(InternalsEventTest, processBlockedCommandsAbortKernelOperation) { using UniqueIH = std::unique_ptr; auto blockedCommandsData = new KernelOperation(std::unique_ptr(cmdStream), UniqueIH(dsh), UniqueIH(ioh), UniqueIH(ssh), - *cmdQ.getCommandStreamReceiver().getInternalAllocationStorage()); + *cmdQ.getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); MockKernelWithInternals mockKernelWithInternals(*pDevice); auto pKernel = mockKernelWithInternals.mockKernel; - auto &csr = cmdQ.getCommandStreamReceiver(); + auto &csr = cmdQ.getGpgpuCommandStreamReceiver(); std::vector v; NullSurface *surface = new NullSurface; v.push_back(surface); @@ -542,7 +542,7 @@ TEST_F(InternalsEventTest, givenBlockedKernelWithPrintfWhenSubmittedThenPrintOut using UniqueIH = std::unique_ptr; auto blockedCommandsData = new KernelOperation(std::unique_ptr(cmdStream), UniqueIH(dsh), UniqueIH(ioh), UniqueIH(ssh), - *cmdQ.getCommandStreamReceiver().getInternalAllocationStorage()); + *cmdQ.getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); SPatchAllocateStatelessPrintfSurface *pPrintfSurface = new SPatchAllocateStatelessPrintfSurface(); pPrintfSurface->DataParamOffset = 0; @@ -587,7 +587,7 @@ TEST_F(InternalsEventTest, processBlockedCommandsMapOperation) { MockEvent event(nullptr, CL_COMMAND_NDRANGE_KERNEL, 0, 0); CommandQueue *pCmdQ = new CommandQueue(mockContext, pDevice, 0); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto buffer = new MockBuffer; MemObjSizeArray size = {{1, 1, 1}}; @@ -609,7 +609,7 @@ TEST_F(InternalsEventTest, processBlockedCommandsMapOperationNonZeroCopyBuffer) MockEvent event(nullptr, CL_COMMAND_NDRANGE_KERNEL, 0, 0); CommandQueue *pCmdQ = new CommandQueue(mockContext, pDevice, 0); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto buffer = new UnalignedBuffer; MemObjSizeArray size = {{1, 1, 1}}; @@ -696,7 +696,7 @@ TEST_F(InternalsEventTest, GIVENProfilingWHENMapOperationTHENTimesSet) { MockEvent *event = new MockEvent(pCmdQ, CL_COMMAND_NDRANGE_KERNEL, 0, 0); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); UnalignedBuffer buffer; MemObjSizeArray size = {{1, 1, 1}}; @@ -722,7 +722,7 @@ TEST_F(InternalsEventTest, processBlockedCommandsUnMapOperation) { const cl_queue_properties props[3] = {CL_QUEUE_PROPERTIES, 0, 0}; CommandQueue *pCmdQ = new CommandQueue(mockContext, pDevice, props); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto buffer = new UnalignedBuffer; MemObjSizeArray size = {{1, 1, 1}}; @@ -745,7 +745,7 @@ TEST_F(InternalsEventTest, givenBlockedMapCommandWhenSubmitIsCalledItReleasesMem const cl_queue_properties props[3] = {CL_QUEUE_PROPERTIES, 0, 0}; auto pCmdQ = std::make_unique(mockContext, pDevice, props); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto buffer = new UnalignedBuffer; auto currentBufferRefInternal = buffer->getRefInternalCount(); @@ -765,7 +765,7 @@ TEST_F(InternalsEventTest, processBlockedCommandsUnMapOperationNonZeroCopyBuffer const cl_queue_properties props[3] = {CL_QUEUE_PROPERTIES, 0, 0}; CommandQueue *pCmdQ = new CommandQueue(mockContext, pDevice, props); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto buffer = new UnalignedBuffer; MemObjSizeArray size = {{1, 1, 1}}; @@ -789,7 +789,7 @@ HWTEST_F(InternalsEventTest, givenCpuProfilingPathWhenEnqueuedMarkerThenDontUseT MockEvent *event = new MockEvent(pCmdQ, CL_COMMAND_MARKER, 0, 0); event->setCPUProfilingPath(true); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); event->setCommand(std::unique_ptr(new CommandMarker(*pCmdQ, csr, CL_COMMAND_MARKER, 4096u))); @@ -834,7 +834,7 @@ HWTEST_F(InternalsEventWithPerfCountersTest, givenCpuProfilingPerfCountersPathWh MockEvent *event = new MockEvent(pCmdQ, CL_COMMAND_MARKER, 0, 0); event->setCPUProfilingPath(true); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); event->setCommand(std::unique_ptr(new CommandMarker(*pCmdQ, csr, CL_COMMAND_MARKER, 4096u))); @@ -862,7 +862,7 @@ HWTEST_F(InternalsEventWithPerfCountersTest, givenCpuProfilingPerfCountersPathWh ASSERT_NE(nullptr, perfCounter); HwTimeStamps *timeStamps = event->getHwTimeStampNode()->tagForCpuAccess; ASSERT_NE(nullptr, timeStamps); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); event->setCommand(std::unique_ptr(new CommandMarker(*pCmdQ, csr, CL_COMMAND_MARKER, 4096u))); @@ -1013,7 +1013,7 @@ HWTEST_F(InternalsEventTest, GivenBufferWithoutZeroCopyOnCommandMapOrUnmapFlushe EXPECT_EQ(1, buffer.dataTransferedStamp); EXPECT_EQ(nullptr, commandUnMap->getCommandStream()); - pCmdQ->getCommandStreamReceiver().setTagAllocation(nullptr); + pCmdQ->getGpgpuCommandStreamReceiver().setTagAllocation(nullptr); delete pCmdQ; } @@ -1205,7 +1205,7 @@ TEST_F(EventTest, GivenCL_SUBMITTEDWhenpeekIsSubmittedThenTrue) { TEST_F(EventTest, GivenCompletedEventWhenQueryingExecutionStatusAfterFlushThenCsrIsNotFlushed) { cl_int ret; Event ev(this->pCmdQ, CL_COMMAND_COPY_BUFFER, 3, 3); - auto &csr = this->pCmdQ->getCommandStreamReceiver(); + auto &csr = this->pCmdQ->getGpgpuCommandStreamReceiver(); *csr.getTagAddress() = 3; auto previousTaskLevel = csr.peekTaskLevel(); EXPECT_GT(3u, previousTaskLevel); @@ -1370,7 +1370,7 @@ HWTEST_F(EventTest, givenEventWithNotReadyTaskLevelWhenUnblockedThenGetTaskLevel Event childEvent0(pCmdQ, CL_COMMAND_NDRANGE_KERNEL, Event::eventNotReady, Event::eventNotReady); Event childEvent1(pCmdQ, CL_COMMAND_NDRANGE_KERNEL, Event::eventNotReady, Event::eventNotReady); - auto &csr = reinterpret_cast &>(pCmdQ->getCommandStreamReceiver()); + auto &csr = reinterpret_cast &>(pCmdQ->getGpgpuCommandStreamReceiver()); csr.taskLevel = initialTaskLevel; parentEventWithGreaterTaskLevel.addChild(childEvent0); @@ -1478,7 +1478,7 @@ HWTEST_F(InternalsEventTest, givenAbortedCommandWhenSubmitCalledThenDontUpdateFl pCmdQ->allocateHeapMemory(IndirectHeap::SURFACE_STATE, 4096u, ssh); using UniqueIH = std::unique_ptr; auto blockedCommandsData = new KernelOperation(std::unique_ptr(cmdStream), UniqueIH(dsh), - UniqueIH(ioh), UniqueIH(ssh), *pCmdQ->getCommandStreamReceiver().getInternalAllocationStorage()); + UniqueIH(ioh), UniqueIH(ssh), *pCmdQ->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); PreemptionMode preemptionMode = pDevice->getPreemptionMode(); std::vector v; auto cmd = new CommandComputeKernel(*pCmdQ, std::unique_ptr(blockedCommandsData), v, false, false, false, nullptr, preemptionMode, pKernel, 1); diff --git a/unit_tests/event/user_events_tests.cpp b/unit_tests/event/user_events_tests.cpp index b5052d2c9d..37e48eec61 100644 --- a/unit_tests/event/user_events_tests.cpp +++ b/unit_tests/event/user_events_tests.cpp @@ -171,7 +171,7 @@ TEST_F(MockEventTests, blockedUserEventPassedToEnqueueNdRangeWithoutReturnEventI cl_event userEvent = uEvent.get(); cl_event *eventWaitList = &userEvent; - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto taskCount = csr.peekTaskCount(); //call NDR @@ -204,7 +204,7 @@ TEST_F(MockEventTests, blockedUserEventPassedToEnqueueNdRangeWithReturnEventIsNo cl_event retEvent = nullptr; cl_event *eventWaitList = &userEvent; - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto taskCount = csr.peekTaskCount(); //call NDR @@ -449,7 +449,7 @@ HWTEST_F(EventTests, userEventObtainsProperTaskLevelAfterSignaling) { TEST_F(MockEventTests, normalEventsBasingOnUserEventHasProperTaskLevel) { uEvent = make_releaseable(context); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto taskLevel = csr.peekTaskLevel(); cl_event retEvent = nullptr; @@ -520,7 +520,7 @@ TEST_F(MockEventTests, enqueueWithAbortedUserEventDoesntFlushToCSR) { int sizeOfWaitList = sizeof(eventWaitList) / sizeof(cl_event); cl_event retEvent = nullptr; - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto taskCount = csr.peekTaskCount(); //call NDR @@ -553,7 +553,7 @@ TEST_F(MockEventTests, childEventDestructorDoesntProcessBlockedCommandsWhenParen int sizeOfWaitList = sizeof(eventWaitList) / sizeof(cl_event); cl_event retEvent = nullptr; - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto taskCount = csr.peekTaskCount(); //call NDR @@ -636,7 +636,7 @@ TEST_F(MockEventTests, waitForEventDependingOnAbortedUserEventReturnsFailureTwoI TEST_F(MockEventTests, finishReturnsSuccessAfterQueueIsAborted) { uEvent = make_releaseable(context); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto taskLevel = csr.peekTaskLevel(); cl_event eventWaitList[] = {uEvent.get()}; @@ -688,7 +688,7 @@ TEST_F(MockEventTests, unblockingEventSendsBlockedPackets) { uEvent = make_releaseable(context); cl_event eventWaitList[] = {uEvent.get()}; - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); int sizeOfWaitList = sizeof(eventWaitList) / sizeof(cl_event); @@ -908,7 +908,7 @@ TEST_F(MockEventTests, enqueueReadImageBlockedOnUserEvent) { } TEST_F(EventTests, waitForEventsDestroysTemporaryAllocations) { - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); auto memoryManager = pCmdQ->getDevice().getMemoryManager(); EXPECT_TRUE(csr.getTemporaryAllocations().peekIsEmpty()); diff --git a/unit_tests/event/user_events_tests_mt.cpp b/unit_tests/event/user_events_tests_mt.cpp index 44f471b851..854d6331f4 100644 --- a/unit_tests/event/user_events_tests_mt.cpp +++ b/unit_tests/event/user_events_tests_mt.cpp @@ -23,7 +23,7 @@ TEST_F(MockEventTests, eventCreatedFromUserEventsThatIsNotSignaledDoesntFlushToC //call NDR auto retVal = callOneWorkItemNDRKernel(eventWaitList, sizeOfWaitList, &retEvent); - auto &csr = pCmdQ->getCommandStreamReceiver(); + auto &csr = pCmdQ->getGpgpuCommandStreamReceiver(); *csr.getTagAddress() = (unsigned int)-1; auto taskLevelBeforeWaitForEvents = csr.peekTaskLevel(); diff --git a/unit_tests/execution_environment/execution_environment_tests.cpp b/unit_tests/execution_environment/execution_environment_tests.cpp index e6958eadfb..4a33efd93a 100644 --- a/unit_tests/execution_environment/execution_environment_tests.cpp +++ b/unit_tests/execution_environment/execution_environment_tests.cpp @@ -250,11 +250,11 @@ TEST(ExecutionEnvironment, givenExecutionEnvironmentWithVariousMembersWhenItIsDe TEST(ExecutionEnvironment, givenMultipleDevicesWhenTheyAreCreatedTheyAllReuseTheSameMemoryManagerAndCommandStreamReceiver) { ExecutionEnvironment *executionEnvironment = platformImpl->peekExecutionEnvironment(); std::unique_ptr device(Device::create(executionEnvironment, 0u)); - auto &commandStreamReceiver = device->getCommandStreamReceiver(); + auto &commandStreamReceiver = device->getGpgpuCommandStreamReceiver(); auto memoryManager = device->getMemoryManager(); std::unique_ptr device2(Device::create(executionEnvironment, 1u)); - EXPECT_NE(&commandStreamReceiver, &device2->getCommandStreamReceiver()); + EXPECT_NE(&commandStreamReceiver, &device2->getGpgpuCommandStreamReceiver()); EXPECT_EQ(memoryManager, device2->getMemoryManager()); } diff --git a/unit_tests/execution_model/submit_blocked_parent_kernel_tests.cpp b/unit_tests/execution_model/submit_blocked_parent_kernel_tests.cpp index 7b54aa23bc..b111ed0fbc 100644 --- a/unit_tests/execution_model/submit_blocked_parent_kernel_tests.cpp +++ b/unit_tests/execution_model/submit_blocked_parent_kernel_tests.cpp @@ -101,7 +101,7 @@ HWTEST_F(ParentKernelCommandQueueFixture, givenLockedEMcritcalSectionWhenParentK std::unique_ptr(dsh), std::unique_ptr(ioh), std::unique_ptr(ssh), - *pCmdQ->getCommandStreamReceiver().getInternalAllocationStorage()); + *pCmdQ->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); blockedCommandData->surfaceStateHeapSizeEM = minSizeSSHForEM; PreemptionMode preemptionMode = device->getPreemptionMode(); @@ -161,7 +161,7 @@ HWTEST_F(ParentKernelCommandQueueFixture, givenParentKernelWhenCommandIsSubmitte std::unique_ptr(dsh), std::unique_ptr(ioh), std::unique_ptr(ssh), - *pCmdQ->getCommandStreamReceiver().getInternalAllocationStorage()); + *pCmdQ->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); size_t minSizeSSHForEM = HardwareCommandsHelper::template getSizeRequiredForExecutionModel(*parentKernel); @@ -204,7 +204,7 @@ HWTEST_F(ParentKernelCommandQueueFixture, givenParentKernelWhenCommandIsSubmitte std::unique_ptr(dsh), std::unique_ptr(ioh), std::unique_ptr(ssh), - *pCmdQ->getCommandStreamReceiver().getInternalAllocationStorage()); + *pCmdQ->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); size_t minSizeSSHForEM = HardwareCommandsHelper::template getSizeRequiredForExecutionModel(*parentKernel); @@ -244,7 +244,7 @@ HWTEST_F(ParentKernelCommandQueueFixture, givenBlockedParentKernelWithProfilingW std::unique_ptr(dsh), std::unique_ptr(ioh), std::unique_ptr(ssh), - *pCmdQ->getCommandStreamReceiver().getInternalAllocationStorage()); + *pCmdQ->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); size_t minSizeSSHForEM = HardwareCommandsHelper::template getSizeRequiredForExecutionModel(*parentKernel); @@ -253,7 +253,7 @@ HWTEST_F(ParentKernelCommandQueueFixture, givenBlockedParentKernelWithProfilingW std::vector surfaces; auto *cmdComputeKernel = new CommandComputeKernel(*pCmdQ, std::unique_ptr(blockedCommandData), surfaces, false, false, false, nullptr, preemptionMode, parentKernel, 1); - auto timestamp = pCmdQ->getCommandStreamReceiver().getEventTsAllocator()->getTag(); + auto timestamp = pCmdQ->getGpgpuCommandStreamReceiver().getEventTsAllocator()->getTag(); cmdComputeKernel->timestamp = timestamp; cmdComputeKernel->submit(0, false); @@ -287,7 +287,7 @@ HWTEST_F(ParentKernelCommandQueueFixture, givenParentKernelWhenCommandIsSubmitte std::unique_ptr(dsh), std::unique_ptr(ioh), std::unique_ptr(ssh), - *pCmdQ->getCommandStreamReceiver().getInternalAllocationStorage()); + *pCmdQ->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); size_t minSizeSSHForEM = HardwareCommandsHelper::template getSizeRequiredForExecutionModel(*parentKernel); @@ -342,7 +342,7 @@ HWCMDTEST_F(IGFX_GEN8_CORE, ParentKernelCommandQueueFixture, givenUsedCommandQue std::unique_ptr(dsh), std::unique_ptr(ioh), std::unique_ptr(ssh), - *pCmdQ->getCommandStreamReceiver().getInternalAllocationStorage()); + *pCmdQ->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); blockedCommandData->surfaceStateHeapSizeEM = minSizeSSHForEM; PreemptionMode preemptionMode = device->getPreemptionMode(); @@ -392,7 +392,7 @@ HWCMDTEST_F(IGFX_GEN8_CORE, ParentKernelCommandQueueFixture, givenNotUsedSSHWhen std::unique_ptr(dsh), std::unique_ptr(ioh), std::unique_ptr(ssh), - *pCmdQ->getCommandStreamReceiver().getInternalAllocationStorage()); + *pCmdQ->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()); blockedCommandData->surfaceStateHeapSizeEM = minSizeSSHForEM; PreemptionMode preemptionMode = device->getPreemptionMode(); diff --git a/unit_tests/fixtures/device_fixture.cpp b/unit_tests/fixtures/device_fixture.cpp index 04e0a2ca24..276a25a4b7 100644 --- a/unit_tests/fixtures/device_fixture.cpp +++ b/unit_tests/fixtures/device_fixture.cpp @@ -19,7 +19,7 @@ void DeviceFixture::SetUpImpl(const NEO::HardwareInfo *hardwareInfo) { pDevice = MockDevice::createWithNewExecutionEnvironment(hardwareInfo); ASSERT_NE(nullptr, pDevice); - auto &commandStreamReceiver = pDevice->getCommandStreamReceiver(); + auto &commandStreamReceiver = pDevice->getGpgpuCommandStreamReceiver(); pTagMemory = commandStreamReceiver.getTagAddress(); ASSERT_NE(nullptr, const_cast(pTagMemory)); } diff --git a/unit_tests/fixtures/ult_command_stream_receiver_fixture.h b/unit_tests/fixtures/ult_command_stream_receiver_fixture.h index 1e47c51152..acacc16702 100644 --- a/unit_tests/fixtures/ult_command_stream_receiver_fixture.h +++ b/unit_tests/fixtures/ult_command_stream_receiver_fixture.h @@ -55,11 +55,11 @@ struct UltCommandStreamReceiverTest graphicsAllocation = new MockGraphicsAllocation(sshBuffer, sizeStream); ssh.replaceGraphicsAllocation(graphicsAllocation); - pDevice->getCommandStreamReceiver().setupContext(*pDevice->getDefaultEngine().osContext); + pDevice->getGpgpuCommandStreamReceiver().setupContext(*pDevice->getDefaultEngine().osContext); } void TearDown() override { - pDevice->getCommandStreamReceiver().flushBatchedSubmissions(); + pDevice->getGpgpuCommandStreamReceiver().flushBatchedSubmissions(); delete dsh.getGraphicsAllocation(); delete ioh.getGraphicsAllocation(); delete ssh.getGraphicsAllocation(); @@ -130,7 +130,7 @@ struct UltCommandStreamReceiverTest template UltCommandStreamReceiver &getUltCommandStreamReceiver() { - return reinterpret_cast &>(pDevice->getCommandStreamReceiver()); + return reinterpret_cast &>(pDevice->getGpgpuCommandStreamReceiver()); } DispatchFlags flushTaskFlags = {}; diff --git a/unit_tests/gen11/enqueue_media_kernel_gen11.cpp b/unit_tests/gen11/enqueue_media_kernel_gen11.cpp index 8d65594289..27b79d27be 100644 --- a/unit_tests/gen11/enqueue_media_kernel_gen11.cpp +++ b/unit_tests/gen11/enqueue_media_kernel_gen11.cpp @@ -155,38 +155,38 @@ GEN11TEST_F(MediaKernelTest, givenGen11CsrWhenEnqueueNonVmeKernelAfterVmeKernelT } ICLLPTEST_F(MediaKernelTest, givenIcllpDefaultLastVmeSubsliceConfigIsFalse) { - auto csr = static_cast *>(&pDevice->getCommandStreamReceiver()); + auto csr = static_cast *>(&pDevice->getGpgpuCommandStreamReceiver()); EXPECT_FALSE(csr->lastVmeSubslicesConfig); } ICLLPTEST_F(MediaKernelTest, givenIcllpCSRWhenEnqueueVmeKernelThenVmeSubslicesConfigChangesToTrue) { - auto csr = static_cast *>(&pDevice->getCommandStreamReceiver()); + auto csr = static_cast *>(&pDevice->getGpgpuCommandStreamReceiver()); enqueueVmeKernel(); EXPECT_TRUE(csr->lastVmeSubslicesConfig); } ICLLPTEST_F(MediaKernelTest, givenIcllpCSRWhenEnqueueRegularKernelAfterVmeKernelThenVmeSubslicesConfigChangesToFalse) { - auto csr = static_cast *>(&pDevice->getCommandStreamReceiver()); + auto csr = static_cast *>(&pDevice->getGpgpuCommandStreamReceiver()); enqueueVmeKernel(); enqueueRegularKernel(); EXPECT_FALSE(csr->lastVmeSubslicesConfig); } ICLLPTEST_F(MediaKernelTest, givenIcllpCSRWhenEnqueueRegularKernelThenVmeSubslicesConfigDoesntChangeToTrue) { - auto csr = static_cast *>(&pDevice->getCommandStreamReceiver()); + auto csr = static_cast *>(&pDevice->getGpgpuCommandStreamReceiver()); enqueueRegularKernel(); EXPECT_FALSE(csr->lastVmeSubslicesConfig); } ICLLPTEST_F(MediaKernelTest, givenIcllpCSRWhenEnqueueRegularKernelAfterRegularKernelThenVmeSubslicesConfigDoesntChangeToTrue) { - auto csr = static_cast *>(&pDevice->getCommandStreamReceiver()); + auto csr = static_cast *>(&pDevice->getGpgpuCommandStreamReceiver()); enqueueRegularKernel(); enqueueRegularKernel(); EXPECT_FALSE(csr->lastVmeSubslicesConfig); } ICLLPTEST_F(MediaKernelTest, givenIcllpCSRWhenEnqueueVmeKernelAfterRegularKernelThenVmeSubslicesConfigChangesToTrue) { - auto csr = static_cast *>(&pDevice->getCommandStreamReceiver()); + auto csr = static_cast *>(&pDevice->getGpgpuCommandStreamReceiver()); enqueueRegularKernel(); enqueueVmeKernel(); EXPECT_TRUE(csr->lastVmeSubslicesConfig); @@ -195,7 +195,7 @@ ICLLPTEST_F(MediaKernelTest, givenIcllpCSRWhenEnqueueVmeKernelAfterRegularKernel ICLLPTEST_F(MediaKernelTest, icllpCmdSizeForVme) { typedef typename FamilyType::MI_LOAD_REGISTER_IMM MI_LOAD_REGISTER_IMM; typedef typename FamilyType::PIPE_CONTROL PIPE_CONTROL; - auto csr = static_cast *>(&pDevice->getCommandStreamReceiver()); + auto csr = static_cast *>(&pDevice->getGpgpuCommandStreamReceiver()); size_t programVmeCmdSize = sizeof(MI_LOAD_REGISTER_IMM) + 2 * sizeof(PIPE_CONTROL); EXPECT_EQ(0u, csr->getCmdSizeForMediaSampler(false)); EXPECT_EQ(programVmeCmdSize, csr->getCmdSizeForMediaSampler(true)); diff --git a/unit_tests/gen8/enqueue_media_kernel_gen8.cpp b/unit_tests/gen8/enqueue_media_kernel_gen8.cpp index e3a2895e5a..7179a88b71 100644 --- a/unit_tests/gen8/enqueue_media_kernel_gen8.cpp +++ b/unit_tests/gen8/enqueue_media_kernel_gen8.cpp @@ -23,21 +23,21 @@ GEN8TEST_F(MediaKernelTest, givenGen8CSRWhenEnqueueVmeKernelThenProgramOnlyPipel } GEN8TEST_F(MediaKernelTest, givenGen8CsrWhenEnqueueVmeKernelThenVmeSubslicesConfigDoesntChangeToFalse) { - auto csr = static_cast *>(&pDevice->getCommandStreamReceiver()); + auto csr = static_cast *>(&pDevice->getGpgpuCommandStreamReceiver()); csr->lastVmeSubslicesConfig = true; enqueueVmeKernel(); EXPECT_TRUE(csr->lastVmeSubslicesConfig); } GEN8TEST_F(MediaKernelTest, givenGen8CsrWhenEnqueueVmeKernelThenVmeSubslicesConfigDoesntChangeToTrue) { - auto csr = static_cast *>(&pDevice->getCommandStreamReceiver()); + auto csr = static_cast *>(&pDevice->getGpgpuCommandStreamReceiver()); csr->lastVmeSubslicesConfig = false; enqueueVmeKernel(); EXPECT_FALSE(csr->lastVmeSubslicesConfig); } GEN8TEST_F(MediaKernelTest, gen8CmdSizeForMediaSampler) { - auto csr = static_cast *>(&pDevice->getCommandStreamReceiver()); + auto csr = static_cast *>(&pDevice->getGpgpuCommandStreamReceiver()); csr->lastVmeSubslicesConfig = false; EXPECT_EQ(0u, csr->getCmdSizeForMediaSampler(false)); diff --git a/unit_tests/gen9/enqueue_media_kernel_gen9.cpp b/unit_tests/gen9/enqueue_media_kernel_gen9.cpp index 29ac70f1c0..b2d459cc98 100644 --- a/unit_tests/gen9/enqueue_media_kernel_gen9.cpp +++ b/unit_tests/gen9/enqueue_media_kernel_gen9.cpp @@ -155,21 +155,21 @@ GEN9TEST_F(MediaKernelTest, givenGen9CsrWhenEnqueueNonVmeKernelAfterVmeKernelThe } GEN9TEST_F(MediaKernelTest, givenGen9CsrWhenEnqueueVmeKernelThenVmeSubslicesConfigDoesntChangeToFalse) { - auto csr = static_cast *>(&pCmdQ->getCommandStreamReceiver()); + auto csr = static_cast *>(&pCmdQ->getGpgpuCommandStreamReceiver()); csr->lastVmeSubslicesConfig = true; enqueueVmeKernel(); EXPECT_TRUE(csr->lastVmeSubslicesConfig); } GEN9TEST_F(MediaKernelTest, givenGen9CsrWhenEnqueueVmeKernelThenVmeSubslicesConfigDoesntChangeToTrue) { - auto csr = static_cast *>(&pCmdQ->getCommandStreamReceiver()); + auto csr = static_cast *>(&pCmdQ->getGpgpuCommandStreamReceiver()); csr->lastVmeSubslicesConfig = false; enqueueVmeKernel(); EXPECT_FALSE(csr->lastVmeSubslicesConfig); } GEN9TEST_F(MediaKernelTest, gen9CmdSizeForMediaSampler) { - auto csr = static_cast *>(&pCmdQ->getCommandStreamReceiver()); + auto csr = static_cast *>(&pCmdQ->getGpgpuCommandStreamReceiver()); csr->lastVmeSubslicesConfig = false; EXPECT_EQ(0u, csr->getCmdSizeForMediaSampler(false)); diff --git a/unit_tests/gtpin/gtpin_tests.cpp b/unit_tests/gtpin/gtpin_tests.cpp index e93b8292d6..6720180593 100644 --- a/unit_tests/gtpin/gtpin_tests.cpp +++ b/unit_tests/gtpin/gtpin_tests.cpp @@ -1487,7 +1487,7 @@ TEST_F(GTPinTests, givenMultipleKernelSubmissionsWhenOneOfGtpinSurfacesIsNullThe gtpinNotifyKernelSubmit(pKernel1, pCmdQueue); EXPECT_EQ(nullptr, kernelExecQueue[0].gtpinResource); - CommandStreamReceiver &csr = pCmdQueue->getCommandStreamReceiver(); + CommandStreamReceiver &csr = pCmdQueue->getGpgpuCommandStreamReceiver(); gtpinNotifyMakeResident(pKernel1, &csr); EXPECT_FALSE(kernelExecQueue[0].isResourceResident); @@ -1671,7 +1671,7 @@ TEST_F(GTPinTests, givenInitializedGTPinInterfaceWhenKernelIsCreatedThenAllKerne cl_mem gtpinBuffer1 = kernelExecQueue[1].gtpinResource; auto pBuffer1 = castToObject(gtpinBuffer1); GraphicsAllocation *pGfxAlloc1 = pBuffer1->getGraphicsAllocation(); - CommandStreamReceiver &csr = pCmdQueue->getCommandStreamReceiver(); + CommandStreamReceiver &csr = pCmdQueue->getGpgpuCommandStreamReceiver(); EXPECT_FALSE(pGfxAlloc0->isResident(csr.getOsContext().getContextId())); EXPECT_FALSE(pGfxAlloc1->isResident(csr.getOsContext().getContextId())); gtpinNotifyMakeResident(pKernel, &csr); @@ -1841,7 +1841,7 @@ TEST_F(GTPinTests, givenInitializedGTPinInterfaceWhenOneKernelIsSubmittedSeveral cl_mem gtpinBuffer1 = kernelExecQueue[1].gtpinResource; auto pBuffer1 = castToObject(gtpinBuffer1); GraphicsAllocation *pGfxAlloc1 = pBuffer1->getGraphicsAllocation(); - CommandStreamReceiver &csr = pCmdQueue->getCommandStreamReceiver(); + CommandStreamReceiver &csr = pCmdQueue->getGpgpuCommandStreamReceiver(); // Make resident resource of first submitted kernel EXPECT_FALSE(pGfxAlloc0->isResident(csr.getOsContext().getContextId())); EXPECT_FALSE(pGfxAlloc1->isResident(csr.getOsContext().getContextId())); diff --git a/unit_tests/helpers/hw_parse.h b/unit_tests/helpers/hw_parse.h index 08be4ec58e..2557243cc9 100644 --- a/unit_tests/helpers/hw_parse.h +++ b/unit_tests/helpers/hw_parse.h @@ -79,7 +79,7 @@ struct HardwareParse { template void parseCommands(NEO::CommandQueue &commandQueue) { - auto &commandStreamReceiver = commandQueue.getCommandStreamReceiver(); + auto &commandStreamReceiver = commandQueue.getGpgpuCommandStreamReceiver(); auto &commandStreamCSR = commandStreamReceiver.getCS(); parseCommands(commandStreamCSR, startCSRCS); diff --git a/unit_tests/helpers/kmd_notify_tests.cpp b/unit_tests/helpers/kmd_notify_tests.cpp index 60de6f03ab..4342c796c6 100644 --- a/unit_tests/helpers/kmd_notify_tests.cpp +++ b/unit_tests/helpers/kmd_notify_tests.cpp @@ -28,7 +28,7 @@ struct KmdNotifyTests : public ::testing::Test { hwInfo = device->getExecutionEnvironment()->getMutableHardwareInfo(); cmdQ.reset(new MockCommandQueue(&context, device.get(), nullptr)); *device->getDefaultEngine().commandStreamReceiver->getTagAddress() = taskCountToWait; - cmdQ->getCommandStreamReceiver().waitForFlushStamp(flushStampToWait); + cmdQ->getGpgpuCommandStreamReceiver().waitForFlushStamp(flushStampToWait); overrideKmdNotifyParams(true, 2, true, 1, false, 0); } diff --git a/unit_tests/helpers/timestamp_packet_tests.cpp b/unit_tests/helpers/timestamp_packet_tests.cpp index 2eca7ea705..0391065322 100644 --- a/unit_tests/helpers/timestamp_packet_tests.cpp +++ b/unit_tests/helpers/timestamp_packet_tests.cpp @@ -236,11 +236,11 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledAndOoqWhenEstimat device->getUltCommandStreamReceiver().timestampPacketWriteEnabled = true; - MockTimestampPacketContainer timestamp1(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp2(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 2); - MockTimestampPacketContainer timestamp3(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 3); - MockTimestampPacketContainer timestamp4(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 4); - MockTimestampPacketContainer timestamp5(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 5); + MockTimestampPacketContainer timestamp1(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp2(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 2); + MockTimestampPacketContainer timestamp3(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 3); + MockTimestampPacketContainer timestamp4(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 4); + MockTimestampPacketContainer timestamp5(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 5); Event event1(mockCmdQ, 0, 0, 0); event1.addTimestampPacketNodes(timestamp1); @@ -258,7 +258,7 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledAndOoqWhenEstimat EventsRequest eventsRequest(numEventsOnWaitlist, waitlist, nullptr); CsrDependencies csrDeps; - csrDeps.fillFromEventsRequestAndMakeResident(eventsRequest, device->getCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); + csrDeps.fillFromEventsRequestAndMakeResident(eventsRequest, device->getGpgpuCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); getCommandStream(*mockCmdQ, csrDeps, false, false, false, multiDispatchInfo, nullptr, 0); auto sizeWithEnabled = mockCmdQ->requestedCmdStreamSize; @@ -279,11 +279,11 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledWhenEstimatingStr device->getUltCommandStreamReceiver().timestampPacketWriteEnabled = true; - MockTimestampPacketContainer timestamp1(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp2(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 2); - MockTimestampPacketContainer timestamp3(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 3); - MockTimestampPacketContainer timestamp4(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 4); - MockTimestampPacketContainer timestamp5(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 5); + MockTimestampPacketContainer timestamp1(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp2(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 2); + MockTimestampPacketContainer timestamp3(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 3); + MockTimestampPacketContainer timestamp4(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 4); + MockTimestampPacketContainer timestamp5(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 5); Event event1(mockCmdQ, 0, 0, 0); event1.addTimestampPacketNodes(timestamp1); @@ -301,7 +301,7 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledWhenEstimatingStr EventsRequest eventsRequest(numEventsOnWaitlist, waitlist, nullptr); CsrDependencies csrDeps; - csrDeps.fillFromEventsRequestAndMakeResident(eventsRequest, device->getCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); + csrDeps.fillFromEventsRequestAndMakeResident(eventsRequest, device->getGpgpuCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); getCommandStream(*mockCmdQ, csrDeps, false, false, false, multiDispatchInfo, nullptr, 0); auto sizeWithEnabled = mockCmdQ->requestedCmdStreamSize; @@ -327,15 +327,15 @@ HWTEST_F(TimestampPacketTests, givenEventsRequestWithEventsWithoutTimestampsWhen EventsRequest eventsRequest(numEventsOnWaitlist, waitlist, nullptr); CsrDependencies csrDepsEmpty; - csrDepsEmpty.fillFromEventsRequestAndMakeResident(eventsRequest, device->getCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); + csrDepsEmpty.fillFromEventsRequestAndMakeResident(eventsRequest, device->getGpgpuCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); EXPECT_EQ(0u, csrDepsEmpty.size()); device->getUltCommandStreamReceiver().timestampPacketWriteEnabled = true; - MockTimestampPacketContainer timestamp1(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp2(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 2); - MockTimestampPacketContainer timestamp3(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 3); - MockTimestampPacketContainer timestamp4(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 4); - MockTimestampPacketContainer timestamp5(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 5); + MockTimestampPacketContainer timestamp1(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp2(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 2); + MockTimestampPacketContainer timestamp3(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 3); + MockTimestampPacketContainer timestamp4(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 4); + MockTimestampPacketContainer timestamp5(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 5); Event event1(mockCmdQ, 0, 0, 0); event1.addTimestampPacketNodes(timestamp1); @@ -355,7 +355,7 @@ HWTEST_F(TimestampPacketTests, givenEventsRequestWithEventsWithoutTimestampsWhen cl_event waitlist2[] = {&event1, &eventWithEmptyTimestampContainer2, &event3, &eventWithEmptyTimestampContainer4, &event5}; EventsRequest eventsRequest2(numEventsOnWaitlist, waitlist2, nullptr); CsrDependencies csrDepsSize3; - csrDepsSize3.fillFromEventsRequestAndMakeResident(eventsRequest2, device->getCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); + csrDepsSize3.fillFromEventsRequestAndMakeResident(eventsRequest2, device->getGpgpuCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); EXPECT_EQ(3u, csrDepsSize3.size()); @@ -371,7 +371,7 @@ HWTEST_F(TimestampPacketTests, whenEstimatingSizeForNodeDependencyThenReturnCorr HWCMDTEST_F(IGFX_GEN8_CORE, TimestampPacketTests, givenTimestampPacketWhenDispatchingGpuWalkerThenAddTwoPcForLastWalker) { using GPGPU_WALKER = typename FamilyType::GPGPU_WALKER; using PIPE_CONTROL = typename FamilyType::PIPE_CONTROL; - MockTimestampPacketContainer timestampPacket(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 2); + MockTimestampPacketContainer timestampPacket(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 2); MockKernelWithInternals kernel2(*device); @@ -419,7 +419,7 @@ HWCMDTEST_F(IGFX_GEN8_CORE, TimestampPacketTests, givenTimestampPacketWhenDispat } HWCMDTEST_F(IGFX_GEN8_CORE, TimestampPacketTests, givenTimestampPacketDisabledWhenDispatchingGpuWalkerThenDontAddPipeControls) { - MockTimestampPacketContainer timestampPacket(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestampPacket(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); MockMultiDispatchInfo multiDispatchInfo(kernel->mockKernel); auto &cmdStream = mockCmdQ->getCS(0); @@ -525,11 +525,11 @@ HWTEST_F(TimestampPacketTests, givenEventsRequestWhenEstimatingStreamSizeForCsrT MockContext context2(device2.get()); auto cmdQ2 = std::make_unique>(&context2, device2.get(), nullptr); - MockTimestampPacketContainer timestamp1(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp2(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 2); - MockTimestampPacketContainer timestamp3(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 3); - MockTimestampPacketContainer timestamp4(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 4); - MockTimestampPacketContainer timestamp5(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 5); + MockTimestampPacketContainer timestamp1(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp2(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 2); + MockTimestampPacketContainer timestamp3(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 3); + MockTimestampPacketContainer timestamp4(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 4); + MockTimestampPacketContainer timestamp5(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 5); auto &csr = device->getUltCommandStreamReceiver(); auto &csr2 = device2->getUltCommandStreamReceiver(); @@ -567,11 +567,11 @@ HWTEST_F(TimestampPacketTests, givenEventsRequestWhenEstimatingStreamSizeForDiff cl_queue_properties props[] = {CL_QUEUE_PRIORITY_KHR, CL_QUEUE_PRIORITY_LOW_KHR, 0}; auto cmdQ2 = std::make_unique>(context, device.get(), props); - MockTimestampPacketContainer timestamp1(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp2(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 2); - MockTimestampPacketContainer timestamp3(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 3); - MockTimestampPacketContainer timestamp4(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 4); - MockTimestampPacketContainer timestamp5(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 5); + MockTimestampPacketContainer timestamp1(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp2(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 2); + MockTimestampPacketContainer timestamp3(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 3); + MockTimestampPacketContainer timestamp4(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 4); + MockTimestampPacketContainer timestamp5(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 5); auto &csr = device->getUltCommandStreamReceiver(); auto &csr2 = cmdQ2->getUltCommandStreamReceiver(); @@ -619,10 +619,10 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledWhenEnqueueingThe auto cmdQ2 = std::make_unique>(&context2, device2.get(), nullptr); const cl_uint eventsOnWaitlist = 6; - MockTimestampPacketContainer timestamp3(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp4(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp5(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp6(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 2); + MockTimestampPacketContainer timestamp3(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp4(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp5(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp6(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 2); UserEvent event1; event1.setStatus(CL_COMPLETE); @@ -705,10 +705,10 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledOnDifferentCSRsFr cmdQ2->getUltCommandStreamReceiver().timestampPacketWriteEnabled = true; const cl_uint eventsOnWaitlist = 6; - MockTimestampPacketContainer timestamp3(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp4(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp5(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp6(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 2); + MockTimestampPacketContainer timestamp3(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp4(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp5(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp6(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 2); UserEvent event1; event1.setStatus(CL_COMPLETE); @@ -758,8 +758,8 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledWhenEnqueueingBlo auto cmdQ1 = clUniquePtr(new MockCommandQueueHw(context, device.get(), nullptr)); auto cmdQ2 = new MockCommandQueueHw(context2, device2.get(), nullptr); - MockTimestampPacketContainer timestamp0(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp1(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp0(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp1(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); UserEvent userEvent; Event event0(cmdQ1.get(), 0, 0, 0); @@ -805,8 +805,8 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledOnDifferentCSRsFr auto cmdQ2 = clUniquePtr(new MockCommandQueueHw(context, device.get(), props)); cmdQ2->getUltCommandStreamReceiver().timestampPacketWriteEnabled = true; - MockTimestampPacketContainer timestamp0(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp1(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp0(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp1(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); UserEvent userEvent; Event event0(cmdQ1.get(), 0, 0, 0); @@ -852,11 +852,11 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledWhenDispatchingTh auto &cmdStream = mockCmdQ->getCS(0); const cl_uint eventsOnWaitlist = 6; - MockTimestampPacketContainer timestamp3(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp4(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp5(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 2); - MockTimestampPacketContainer timestamp6(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp7(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp3(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp4(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp5(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 2); + MockTimestampPacketContainer timestamp6(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp7(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); UserEvent event1; UserEvent event2; @@ -873,7 +873,7 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledWhenDispatchingTh EventsRequest eventsRequest(eventsOnWaitlist, waitlist, nullptr); CsrDependencies csrDeps; - csrDeps.fillFromEventsRequestAndMakeResident(eventsRequest, mockCmdQ->getCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); + csrDeps.fillFromEventsRequestAndMakeResident(eventsRequest, mockCmdQ->getGpgpuCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); HardwareInterface::dispatchWalker( *mockCmdQ, @@ -936,11 +936,11 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledOnDifferentCSRsFr auto &cmdStream = mockCmdQ->getCS(0); const cl_uint eventsOnWaitlist = 6; - MockTimestampPacketContainer timestamp3(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp4(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp5(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 2); - MockTimestampPacketContainer timestamp6(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer timestamp7(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp3(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp4(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp5(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 2); + MockTimestampPacketContainer timestamp6(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp7(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); UserEvent event1; UserEvent event2; @@ -957,7 +957,7 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledOnDifferentCSRsFr EventsRequest eventsRequest(eventsOnWaitlist, waitlist, nullptr); CsrDependencies csrDeps; - csrDeps.fillFromEventsRequestAndMakeResident(eventsRequest, mockCmdQ->getCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); + csrDeps.fillFromEventsRequestAndMakeResident(eventsRequest, mockCmdQ->getGpgpuCommandStreamReceiver(), CsrDependencies::DependenciesType::OnCsr); HardwareInterface::dispatchWalker( *mockCmdQ, @@ -1005,7 +1005,7 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledOnDifferentCSRsFr } HWTEST_F(TimestampPacketTests, givenTimestampPacketWhenItIsQueriedForCompletionStatusThenItReturnsCurrentStatus) { - MockTimestampPacketContainer timestamp(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer timestamp(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); EXPECT_FALSE(timestamp.isCompleted()); timestamp.getNode(0u)->tagForCpuAccess->packets[0].contextEnd = 0; EXPECT_FALSE(timestamp.isCompleted()); @@ -1014,7 +1014,7 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWhenItIsQueriedForCompletionS } HWTEST_F(TimestampPacketTests, givenTimestampPacketWithMultipleNodesWhenItIsQueriedForCompletionStatusThenItReturnsCurrentStatus) { - MockTimestampPacketContainer timestamp(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 2); + MockTimestampPacketContainer timestamp(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 2); timestamp.getNode(0u)->tagForCpuAccess->packets[0].contextEnd = 0; timestamp.getNode(0u)->tagForCpuAccess->packets[0].globalEnd = 0; EXPECT_FALSE(timestamp.isCompleted()); @@ -1104,7 +1104,7 @@ HWTEST_F(TimestampPacketTests, givenAlreadyAssignedNodeWhenEnqueueingThenKeepDep using MI_SEMAPHORE_WAIT = typename FamilyType::MI_SEMAPHORE_WAIT; using MI_ATOMIC = typename FamilyType::MI_ATOMIC; device->getUltCommandStreamReceiver().timestampPacketWriteEnabled = true; - MockTimestampPacketContainer firstNode(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 0); + MockTimestampPacketContainer firstNode(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 0); MockCommandQueueHw cmdQ(context, device.get(), nullptr); TimestampPacketContainer previousNodes; @@ -1320,7 +1320,7 @@ HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledWhenEnqueueingBlo TEST_F(TimestampPacketTests, givenDispatchSizeWhenAskingForNewTimestampsThenObtainEnoughTags) { size_t dispatchSize = 3; - mockCmdQ->timestampPacketContainer = std::make_unique(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 0); + mockCmdQ->timestampPacketContainer = std::make_unique(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 0); EXPECT_EQ(0u, mockCmdQ->timestampPacketContainer->peekNodes().size()); TimestampPacketContainer previousNodes; @@ -1339,8 +1339,8 @@ HWTEST_F(TimestampPacketTests, givenWaitlistAndOutputEventWhenEnqueueingWithoutK TimestampPacketContainer cmdQNodes; cmdQNodes.assignAndIncrementNodesRefCounts(*cmdQ->timestampPacketContainer); - MockTimestampPacketContainer node1(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer node2(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer node1(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer node2(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); Event event0(cmdQ.get(), 0, 0, 0); event0.addTimestampPacketNodes(node1); @@ -1384,8 +1384,8 @@ HWTEST_F(TimestampPacketTests, givenWaitlistAndOutputEventWhenEnqueueingMarkerWi auto cmdQ = clUniquePtr(new MockCommandQueueHw(context, device.get(), nullptr)); auto cmdQ2 = std::make_unique>(&context2, device2.get(), nullptr); - MockTimestampPacketContainer node1(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer node2(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer node1(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer node2(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); Event event0(cmdQ.get(), 0, 0, 0); event0.addTimestampPacketNodes(node1); @@ -1423,8 +1423,8 @@ HWTEST_F(TimestampPacketTests, givenWaitlistAndOutputEventWhenEnqueueingBarrierW auto cmdQ = clUniquePtr(new MockCommandQueueHw(context, device.get(), nullptr)); auto cmdQ2 = std::make_unique>(&context2, device2.get(), nullptr); - MockTimestampPacketContainer node1(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); - MockTimestampPacketContainer node2(*device->getCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer node1(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); + MockTimestampPacketContainer node2(*device->getGpgpuCommandStreamReceiver().getTimestampPacketAllocator(), 1); Event event0(cmdQ.get(), 0, 0, 0); event0.addTimestampPacketNodes(node1); diff --git a/unit_tests/kernel/kernel_tests.cpp b/unit_tests/kernel/kernel_tests.cpp index 3c5ff8b054..42e560ee33 100644 --- a/unit_tests/kernel/kernel_tests.cpp +++ b/unit_tests/kernel/kernel_tests.cpp @@ -557,7 +557,7 @@ TEST_F(KernelPrivateSurfaceTest, givenKernelWithPrivateSurfaceThatIsInUseByGpuWh std::unique_ptr pKernel(new MockKernel(&program, *pKernelInfo, *pDevice)); pKernel->initialize(); - auto &csr = pDevice->getCommandStreamReceiver(); + auto &csr = pDevice->getGpgpuCommandStreamReceiver(); auto privateSurface = pKernel->getPrivateSurface(); auto tagAddress = csr.getTagAddress(); @@ -1616,7 +1616,7 @@ HWTEST_F(KernelResidencyTest, givenKernelWhenMakeResidentIsCalledThenKernelIsaIs pKernel->setCrossThreadData(pCrossThreadData, sizeof(pCrossThreadData)); EXPECT_EQ(0u, commandStreamReceiver.makeResidentAllocations.size()); - pKernel->makeResident(pDevice->getCommandStreamReceiver()); + pKernel->makeResident(pDevice->getGpgpuCommandStreamReceiver()); EXPECT_EQ(1u, commandStreamReceiver.makeResidentAllocations.size()); EXPECT_TRUE(commandStreamReceiver.isMadeResident(pKernel->getKernelInfo().getGraphicsAllocation())); @@ -1638,7 +1638,7 @@ HWTEST_F(KernelResidencyTest, givenKernelWhenMakeResidentIsCalledThenExportedFun ASSERT_EQ(CL_SUCCESS, pKernel->initialize()); EXPECT_EQ(0u, commandStreamReceiver.makeResidentAllocations.size()); - pKernel->makeResident(pDevice->getCommandStreamReceiver()); + pKernel->makeResident(pDevice->getGpgpuCommandStreamReceiver()); EXPECT_TRUE(commandStreamReceiver.isMadeResident(program.exportedFunctionsSurface)); // check getResidency as well @@ -1673,7 +1673,7 @@ HWTEST_F(KernelResidencyTest, givenKernelWhenMakeResidentIsCalledThenGlobalBuffe ASSERT_EQ(CL_SUCCESS, pKernel->initialize()); EXPECT_EQ(0u, commandStreamReceiver.makeResidentAllocations.size()); - pKernel->makeResident(pDevice->getCommandStreamReceiver()); + pKernel->makeResident(pDevice->getGpgpuCommandStreamReceiver()); EXPECT_TRUE(commandStreamReceiver.isMadeResident(program.globalSurface)); std::vector residencySurfaces; @@ -1700,13 +1700,13 @@ HWTEST_F(KernelResidencyTest, givenKernelWhenItUsesIndirectUnifiedMemoryDeviceAl auto svmAllocationsManager = mockKernel.mockContext->getSVMAllocsManager(); auto unifiedMemoryAllocation = svmAllocationsManager->createUnifiedMemoryAllocation(4096u, SVMAllocsManager::UnifiedMemoryProperties(InternalMemoryType::DEVICE_UNIFIED_MEMORY)); - mockKernel.mockKernel->makeResident(this->pDevice->getCommandStreamReceiver()); + mockKernel.mockKernel->makeResident(this->pDevice->getGpgpuCommandStreamReceiver()); EXPECT_EQ(0u, commandStreamReceiver.getResidencyAllocations().size()); mockKernel.mockKernel->setUnifiedMemoryProperty(CL_KERNEL_EXEC_INFO_INDIRECT_DEVICE_ACCESS_INTEL, true); - mockKernel.mockKernel->makeResident(this->pDevice->getCommandStreamReceiver()); + mockKernel.mockKernel->makeResident(this->pDevice->getGpgpuCommandStreamReceiver()); EXPECT_EQ(1u, commandStreamReceiver.getResidencyAllocations().size()); @@ -1725,11 +1725,11 @@ HWTEST_F(KernelResidencyTest, givenKernelUsingIndirectHostMemoryWhenMakeResident auto unifiedDeviceMemoryAllocation = svmAllocationsManager->createUnifiedMemoryAllocation(4096u, SVMAllocsManager::UnifiedMemoryProperties(InternalMemoryType::DEVICE_UNIFIED_MEMORY)); auto unifiedHostMemoryAllocation = svmAllocationsManager->createUnifiedMemoryAllocation(4096u, SVMAllocsManager::UnifiedMemoryProperties(InternalMemoryType::HOST_UNIFIED_MEMORY)); - mockKernel.mockKernel->makeResident(this->pDevice->getCommandStreamReceiver()); + mockKernel.mockKernel->makeResident(this->pDevice->getGpgpuCommandStreamReceiver()); EXPECT_EQ(0u, commandStreamReceiver.getResidencyAllocations().size()); mockKernel.mockKernel->setUnifiedMemoryProperty(CL_KERNEL_EXEC_INFO_INDIRECT_HOST_ACCESS_INTEL, true); - mockKernel.mockKernel->makeResident(this->pDevice->getCommandStreamReceiver()); + mockKernel.mockKernel->makeResident(this->pDevice->getGpgpuCommandStreamReceiver()); EXPECT_EQ(1u, commandStreamReceiver.getResidencyAllocations().size()); EXPECT_EQ(commandStreamReceiver.getResidencyAllocations()[0]->getGpuAddress(), castToUint64(unifiedHostMemoryAllocation)); @@ -1745,11 +1745,11 @@ HWTEST_F(KernelResidencyTest, givenKernelUsingIndirectSharedMemoryWhenMakeReside auto unifiedSharedMemoryAllocation = svmAllocationsManager->createUnifiedMemoryAllocation(4096u, SVMAllocsManager::UnifiedMemoryProperties(InternalMemoryType::SHARED_UNIFIED_MEMORY)); auto unifiedHostMemoryAllocation = svmAllocationsManager->createUnifiedMemoryAllocation(4096u, SVMAllocsManager::UnifiedMemoryProperties(InternalMemoryType::HOST_UNIFIED_MEMORY)); - mockKernel.mockKernel->makeResident(this->pDevice->getCommandStreamReceiver()); + mockKernel.mockKernel->makeResident(this->pDevice->getGpgpuCommandStreamReceiver()); EXPECT_EQ(0u, commandStreamReceiver.getResidencyAllocations().size()); mockKernel.mockKernel->setUnifiedMemoryProperty(CL_KERNEL_EXEC_INFO_INDIRECT_SHARED_ACCESS_INTEL, true); - mockKernel.mockKernel->makeResident(this->pDevice->getCommandStreamReceiver()); + mockKernel.mockKernel->makeResident(this->pDevice->getGpgpuCommandStreamReceiver()); EXPECT_EQ(1u, commandStreamReceiver.getResidencyAllocations().size()); EXPECT_EQ(commandStreamReceiver.getResidencyAllocations()[0]->getGpuAddress(), castToUint64(unifiedSharedMemoryAllocation)); @@ -1772,7 +1772,7 @@ HWTEST_F(KernelResidencyTest, givenKernelWhenSetKernelExecInfoWithUnifiedMemoryI EXPECT_EQ(1u, mockKernel.mockKernel->kernelUnifiedMemoryGfxAllocations.size()); EXPECT_EQ(mockKernel.mockKernel->kernelUnifiedMemoryGfxAllocations[0]->getGpuAddress(), castToUint64(unifiedMemoryAllocation)); - mockKernel.mockKernel->makeResident(this->pDevice->getCommandStreamReceiver()); + mockKernel.mockKernel->makeResident(this->pDevice->getGpgpuCommandStreamReceiver()); EXPECT_EQ(1u, commandStreamReceiver.getResidencyAllocations().size()); EXPECT_EQ(commandStreamReceiver.getResidencyAllocations()[0]->getGpuAddress(), castToUint64(unifiedMemoryAllocation)); @@ -1931,7 +1931,7 @@ HWTEST_F(KernelResidencyTest, test_MakeArgsResidentCheckImageFromImage) { ASSERT_EQ(CL_SUCCESS, pKernel->initialize()); pKernel->storeKernelArg(0, Kernel::IMAGE_OBJ, (cl_mem)imageY.get(), NULL, 0); - pKernel->makeResident(pDevice->getCommandStreamReceiver()); + pKernel->makeResident(pDevice->getGpgpuCommandStreamReceiver()); EXPECT_FALSE(imageNV12->isImageFromImage()); EXPECT_TRUE(imageY->isImageFromImage()); diff --git a/unit_tests/kernel/substitute_kernel_heap_tests.cpp b/unit_tests/kernel/substitute_kernel_heap_tests.cpp index e31f17429e..fe273fe7cc 100644 --- a/unit_tests/kernel/substitute_kernel_heap_tests.cpp +++ b/unit_tests/kernel/substitute_kernel_heap_tests.cpp @@ -110,7 +110,7 @@ TEST_F(KernelSubstituteTest, givenKernelWithUsedKernelAllocationWhenSubstituteKe MockKernelWithInternals kernel(*pDevice); auto pHeader = const_cast(kernel.kernelInfo.heapInfo.pKernelHeader); auto memoryManager = pDevice->getMemoryManager(); - auto &commandStreamReceiver = pDevice->getCommandStreamReceiver(); + auto &commandStreamReceiver = pDevice->getGpgpuCommandStreamReceiver(); const size_t initialHeapSize = 0x40; pHeader->KernelHeapSize = initialHeapSize; diff --git a/unit_tests/mem_obj/buffer_tests.cpp b/unit_tests/mem_obj/buffer_tests.cpp index 24bc040202..6752cd30a7 100644 --- a/unit_tests/mem_obj/buffer_tests.cpp +++ b/unit_tests/mem_obj/buffer_tests.cpp @@ -444,11 +444,11 @@ TEST(Buffer, givenClMemCopyHostPointerPassedToBufferCreateWhenAllocationIsNotInS cl_int retVal = 0; cl_mem_flags flags = CL_MEM_READ_WRITE | CL_MEM_COPY_HOST_PTR; char memory[] = {1, 2, 3, 4, 5, 6, 7, 8}; - auto taskCount = device->getCommandStreamReceiver().peekLatestFlushedTaskCount(); + auto taskCount = device->getGpgpuCommandStreamReceiver().peekLatestFlushedTaskCount(); std::unique_ptr buffer(Buffer::create(&ctx, flags, sizeof(memory), memory, retVal)); ASSERT_NE(nullptr, buffer.get()); - auto taskCountSent = device->getCommandStreamReceiver().peekLatestFlushedTaskCount(); + auto taskCountSent = device->getGpgpuCommandStreamReceiver().peekLatestFlushedTaskCount(); EXPECT_LT(taskCount, taskCountSent); } struct RenderCompressedBuffersTests : public ::testing::Test { @@ -749,7 +749,7 @@ HWTEST_F(BcsBufferTests, givenWriteBufferEnqueueWhenProgrammingCommandStreamThen auto cmdQ = clUniquePtr(new MockCommandQueueHw(bcsMockContext.get(), device.get(), nullptr)); - auto queueCsr = cmdQ->engine->commandStreamReceiver; + auto queueCsr = cmdQ->gpgpuEngine->commandStreamReceiver; auto initialTaskCount = queueCsr->peekTaskCount(); cl_int retVal = CL_SUCCESS; @@ -792,7 +792,7 @@ HWTEST_F(BcsBufferTests, givenReadBufferEnqueueWhenProgrammingCommandStreamThenA auto cmdQ = clUniquePtr(new MockCommandQueueHw(bcsMockContext.get(), device.get(), nullptr)); - auto queueCsr = cmdQ->engine->commandStreamReceiver; + auto queueCsr = cmdQ->gpgpuEngine->commandStreamReceiver; auto initialTaskCount = queueCsr->peekTaskCount(); cl_int retVal = CL_SUCCESS; @@ -887,7 +887,7 @@ HWTEST_F(BcsBufferTests, givenInputAndOutputTimestampPacketWhenBlitCalledThenMak auto cmdQ = clUniquePtr(new MockCommandQueueHw(bcsMockContext.get(), device.get(), nullptr)); cl_int retVal = CL_SUCCESS; - auto &cmdQueueCsr = static_cast &>(cmdQ->getCommandStreamReceiver()); + auto &cmdQueueCsr = static_cast &>(cmdQ->getGpgpuCommandStreamReceiver()); auto memoryManager = cmdQueueCsr.getMemoryManager(); cmdQueueCsr.timestampPacketAllocator = std::make_unique>(memoryManager, 1, MemoryConstants::cacheLineSize); @@ -1873,7 +1873,7 @@ HWTEST_P(BufferL3CacheTests, givenMisalignedAndAlignedBufferWhenClEnqueueWriteIm using RENDER_SURFACE_STATE = typename FamilyType::RENDER_SURFACE_STATE; CommandQueueHw cmdQ(&ctx, ctx.getDevice(0), nullptr); - auto surfaceState = reinterpret_cast(cmdQ.getCommandStreamReceiver().getIndirectHeap(IndirectHeap::Type::SURFACE_STATE, 0).getSpace(0)); + auto surfaceState = reinterpret_cast(cmdQ.getGpgpuCommandStreamReceiver().getIndirectHeap(IndirectHeap::Type::SURFACE_STATE, 0).getSpace(0)); cl_image_format imageFormat; cl_image_desc imageDesc; @@ -1904,7 +1904,7 @@ HWTEST_P(BufferL3CacheTests, givenMisalignedAndAlignedBufferWhenClEnqueueWriteBu using RENDER_SURFACE_STATE = typename FamilyType::RENDER_SURFACE_STATE; CommandQueueHw cmdQ(&ctx, ctx.getDevice(0), nullptr); - auto surfaceState = reinterpret_cast(cmdQ.getCommandStreamReceiver().getIndirectHeap(IndirectHeap::Type::SURFACE_STATE, 0).getSpace(0)); + auto surfaceState = reinterpret_cast(cmdQ.getGpgpuCommandStreamReceiver().getIndirectHeap(IndirectHeap::Type::SURFACE_STATE, 0).getSpace(0)); auto buffer = clCreateBuffer(&ctx, CL_MEM_READ_WRITE, 36, nullptr, nullptr); clEnqueueWriteBufferRect(&cmdQ, buffer, false, origin, origin, region, 0, 0, 0, 0, hostPtr, 0, nullptr, nullptr); diff --git a/unit_tests/mem_obj/image_tests.cpp b/unit_tests/mem_obj/image_tests.cpp index a23bcddc7f..475129fb53 100644 --- a/unit_tests/mem_obj/image_tests.cpp +++ b/unit_tests/mem_obj/image_tests.cpp @@ -1317,7 +1317,7 @@ TEST(ImageTest, givenClMemCopyHostPointerPassedToImageCreateWhenAllocationIsNotI .WillRepeatedly(::testing::Invoke(memoryManager, &GMockMemoryManagerFailFirstAllocation::baseAllocateGraphicsMemoryInDevicePool)); char memory[] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}; - auto taskCount = device->getCommandStreamReceiver().peekLatestFlushedTaskCount(); + auto taskCount = device->getGpgpuCommandStreamReceiver().peekLatestFlushedTaskCount(); cl_int retVal = 0; cl_mem_flags flags = CL_MEM_READ_WRITE | CL_MEM_COPY_HOST_PTR; @@ -1337,7 +1337,7 @@ TEST(ImageTest, givenClMemCopyHostPointerPassedToImageCreateWhenAllocationIsNotI std::unique_ptr image(Image::create(&ctx, flags, surfaceFormat, &imageDesc, memory, retVal)); EXPECT_NE(nullptr, image); - auto taskCountSent = device->getCommandStreamReceiver().peekLatestFlushedTaskCount(); + auto taskCountSent = device->getGpgpuCommandStreamReceiver().peekLatestFlushedTaskCount(); EXPECT_LT(taskCount, taskCountSent); } diff --git a/unit_tests/memory_manager/memory_manager_tests.cpp b/unit_tests/memory_manager/memory_manager_tests.cpp index fefba060ee..15a2f99ea6 100644 --- a/unit_tests/memory_manager/memory_manager_tests.cpp +++ b/unit_tests/memory_manager/memory_manager_tests.cpp @@ -1502,7 +1502,7 @@ HWTEST_F(GraphicsAllocationTests, givenAllocationUsedOnlyByNonDefaultCsrWhenChec HWTEST_F(GraphicsAllocationTests, givenAllocationUsedOnlyByNonDefaultDeviceWhenCheckingUsageBeforeDestroyThenStoreItAsTemporaryAllocation) { ExecutionEnvironment *executionEnvironment = platformImpl->peekExecutionEnvironment(); auto device = std::unique_ptr(Device::create(executionEnvironment, 0u)); - auto &defaultCommandStreamReceiver = device->getCommandStreamReceiver(); + auto &defaultCommandStreamReceiver = device->getGpgpuCommandStreamReceiver(); auto &nonDefaultCommandStreamReceiver = static_cast &>(*executionEnvironment->commandStreamReceivers[0][1]); auto memoryManager = executionEnvironment->memoryManager.get(); auto graphicsAllocation = memoryManager->allocateGraphicsMemoryWithProperties(MockAllocationProperties{MemoryConstants::pageSize}); diff --git a/unit_tests/mocks/mock_command_queue.h b/unit_tests/mocks/mock_command_queue.h index 1af288888e..899fec4d2d 100644 --- a/unit_tests/mocks/mock_command_queue.h +++ b/unit_tests/mocks/mock_command_queue.h @@ -18,7 +18,7 @@ namespace NEO { class MockCommandQueue : public CommandQueue { public: using CommandQueue::device; - using CommandQueue::engine; + using CommandQueue::gpgpuEngine; using CommandQueue::multiEngineQueue; using CommandQueue::obtainNewTimestampPacketNodes; using CommandQueue::requiresCacheFlushAfterWalker; @@ -74,7 +74,7 @@ class MockCommandQueueHw : public CommandQueueHw { public: using BaseClass::commandStream; - using BaseClass::engine; + using BaseClass::gpgpuEngine; using BaseClass::multiEngineQueue; using BaseClass::obtainNewTimestampPacketNodes; using BaseClass::requiresCacheFlushAfterWalker; @@ -86,7 +86,7 @@ class MockCommandQueueHw : public CommandQueueHw { } UltCommandStreamReceiver &getUltCommandStreamReceiver() { - return reinterpret_cast &>(*BaseClass::engine->commandStreamReceiver); + return reinterpret_cast &>(*BaseClass::gpgpuEngine->commandStreamReceiver); } cl_int enqueueWriteImage(Image *dstImage, diff --git a/unit_tests/mocks/mock_device.h b/unit_tests/mocks/mock_device.h index 8bbbd4f1a5..d5b77e67d9 100644 --- a/unit_tests/mocks/mock_device.h +++ b/unit_tests/mocks/mock_device.h @@ -79,7 +79,7 @@ class MockDevice : public Device { return reinterpret_cast &>(*engines[defaultEngineIndex].commandStreamReceiver); } - CommandStreamReceiver &getCommandStreamReceiver() const { return *engines[defaultEngineIndex].commandStreamReceiver; } + CommandStreamReceiver &getGpgpuCommandStreamReceiver() const { return *engines[defaultEngineIndex].commandStreamReceiver; } void resetCommandStreamReceiver(CommandStreamReceiver *newCsr); void resetCommandStreamReceiver(CommandStreamReceiver *newCsr, uint32_t engineIndex); diff --git a/unit_tests/perf_tests/fixtures/device_fixture.cpp b/unit_tests/perf_tests/fixtures/device_fixture.cpp index 76591b082a..10d46756d7 100644 --- a/unit_tests/perf_tests/fixtures/device_fixture.cpp +++ b/unit_tests/perf_tests/fixtures/device_fixture.cpp @@ -20,7 +20,7 @@ void DeviceFixture::SetUp() { pDevice = DeviceHelper<>::create(); ASSERT_NE(nullptr, pDevice); - auto &commandStreamReceiver = pDevice->getCommandStreamReceiver(); + auto &commandStreamReceiver = pDevice->getGpgpuCommandStreamReceiver(); pTagMemory = commandStreamReceiver.getTagAddress(); ASSERT_NE(nullptr, const_cast(pTagMemory)); } diff --git a/unit_tests/preamble/preamble_tests.cpp b/unit_tests/preamble/preamble_tests.cpp index dcf610a696..5285263f95 100644 --- a/unit_tests/preamble/preamble_tests.cpp +++ b/unit_tests/preamble/preamble_tests.cpp @@ -149,7 +149,7 @@ HWTEST_F(PreambleTest, givenKernelDebuggingActiveWhenPreambleIsProgrammedThenPro auto miLoadRegImmCountWithoutDebugging = cmdList.size(); mockDevice->setSourceLevelDebuggerActive(true); - auto preemptionAllocation = mockDevice->getCommandStreamReceiver().getPreemptionAllocation(); + auto preemptionAllocation = mockDevice->getGpgpuCommandStreamReceiver().getPreemptionAllocation(); StackVec preambleBuffer2(8192); preambleStream.replaceBuffer(&*preambleBuffer2.begin(), preambleBuffer2.size()); diff --git a/unit_tests/program/program_tests.cpp b/unit_tests/program/program_tests.cpp index cbc20edc76..7a16dee9b5 100644 --- a/unit_tests/program/program_tests.cpp +++ b/unit_tests/program/program_tests.cpp @@ -659,7 +659,7 @@ TEST_P(ProgramFromBinaryTest, givenProgramWhenCleanKernelInfoIsCalledThenKernelA TEST_P(ProgramFromBinaryTest, givenProgramWhenCleanCurrentKernelInfoIsCalledButGpuIsNotYetDoneThenKernelAllocationIsPutOnDefferedFreeList) { cl_device_id device = pDevice; - auto &csr = pDevice->getCommandStreamReceiver(); + auto &csr = pDevice->getGpgpuCommandStreamReceiver(); EXPECT_TRUE(csr.getTemporaryAllocations().peekIsEmpty()); pProgram->build(1, &device, nullptr, nullptr, nullptr, true); auto kernelAllocation = pProgram->getKernelInfo(size_t(0))->getGraphicsAllocation(); diff --git a/unit_tests/scenarios/windows/enqueue_read_write_buffer_scenarios_windows_tests.cpp b/unit_tests/scenarios/windows/enqueue_read_write_buffer_scenarios_windows_tests.cpp index 4552c517d0..7441c8e276 100644 --- a/unit_tests/scenarios/windows/enqueue_read_write_buffer_scenarios_windows_tests.cpp +++ b/unit_tests/scenarios/windows/enqueue_read_write_buffer_scenarios_windows_tests.cpp @@ -85,7 +85,7 @@ HWTEST_F(EnqueueBufferWindowsTest, givenMisalignedHostPtrWhenEnqueueReadBufferCa ASSERT_NE(0, cmdQ->lastEnqueuedKernels.size()); Kernel *kernel = cmdQ->lastEnqueuedKernels[0]; - auto hostPtrAllcoation = cmdQ->getCommandStreamReceiver().getInternalAllocationStorage()->getTemporaryAllocations().peekHead(); + auto hostPtrAllcoation = cmdQ->getGpgpuCommandStreamReceiver().getInternalAllocationStorage()->getTemporaryAllocations().peekHead(); while (hostPtrAllcoation != nullptr) { if (hostPtrAllcoation->getUnderlyingBuffer() == misalignedPtr) { diff --git a/unit_tests/sharings/gl/gl_arb_sync_event_tests.cpp b/unit_tests/sharings/gl/gl_arb_sync_event_tests.cpp index 27ecb53f45..a0fded47cb 100644 --- a/unit_tests/sharings/gl/gl_arb_sync_event_tests.cpp +++ b/unit_tests/sharings/gl/gl_arb_sync_event_tests.cpp @@ -166,7 +166,7 @@ TEST_F(GlArbSyncEventTest, whenSetBaseEventIsCalledThenProperMembersOfParentEven EXPECT_TRUE(getBaseEvent()->peekHasChildEvents()); EXPECT_EQ(getBaseEvent(), syncEv->baseEvent); EXPECT_EQ(getBaseEvent()->getCommandQueue(), syncEv->getCommandQueue()); - EXPECT_EQ(syncEv->getCommandQueue()->getCommandStreamReceiver().getOSInterface(), syncEv->osInterface); + EXPECT_EQ(syncEv->getCommandQueue()->getGpgpuCommandStreamReceiver().getOSInterface(), syncEv->osInterface); EXPECT_EQ(3, getBaseEvent()->getRefInternalCount()); EXPECT_EQ(3, getBaseEvent()->getCommandQueue()->getRefInternalCount()); diff --git a/unit_tests/source_level_debugger/source_level_debugger_tests.cpp b/unit_tests/source_level_debugger/source_level_debugger_tests.cpp index 3e00909df5..2ae4dc8447 100644 --- a/unit_tests/source_level_debugger/source_level_debugger_tests.cpp +++ b/unit_tests/source_level_debugger/source_level_debugger_tests.cpp @@ -474,7 +474,7 @@ TEST(SourceLevelDebugger, givenKernelDebuggerLibraryActiveWhenDeviceImplIsCreate unique_ptr device(MockDevice::createWithNewExecutionEnvironment(*platformDevices)); EXPECT_TRUE(interceptor.newDeviceCalled); - uint32_t deviceHandleExpected = device->getCommandStreamReceiver().getOSInterface() != nullptr ? device->getCommandStreamReceiver().getOSInterface()->getDeviceHandle() : 0; + uint32_t deviceHandleExpected = device->getGpgpuCommandStreamReceiver().getOSInterface() != nullptr ? device->getGpgpuCommandStreamReceiver().getOSInterface()->getDeviceHandle() : 0; EXPECT_EQ(reinterpret_cast(static_cast(deviceHandleExpected)), interceptor.newDeviceArgIn.dh); } } @@ -496,10 +496,10 @@ TEST(SourceLevelDebugger, givenKernelDebuggerLibraryActiveWhenDeviceImplIsCreate hwInfo->capabilityTable.instrumentationEnabled = true; unique_ptr device(Device::create(executionEnvironment, 0)); - ASSERT_NE(nullptr, device->getCommandStreamReceiver().getOSInterface()); + ASSERT_NE(nullptr, device->getGpgpuCommandStreamReceiver().getOSInterface()); EXPECT_TRUE(interceptor.newDeviceCalled); - uint32_t deviceHandleExpected = device->getCommandStreamReceiver().getOSInterface()->getDeviceHandle(); + uint32_t deviceHandleExpected = device->getGpgpuCommandStreamReceiver().getOSInterface()->getDeviceHandle(); EXPECT_EQ(reinterpret_cast(static_cast(deviceHandleExpected)), interceptor.newDeviceArgIn.dh); } }