Remove device enqueue part 3

- isSchedulerKernel

Related-To: NEO-6559
Signed-off-by: Katarzyna Cencelewska <katarzyna.cencelewska@intel.com>
This commit is contained in:
Katarzyna Cencelewska
2022-01-10 18:55:21 +00:00
committed by Compute-Runtime-Automation
parent af7cb3ff35
commit 45ae4fe881
18 changed files with 63 additions and 154 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 2018-2021 Intel Corporation
* Copyright (C) 2018-2022 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
@@ -23,7 +23,7 @@ bool PreemptionHelper::allowThreadGroupPreemption(const PreemptionFlags &flags)
flags.flags.disableLSQCROPERFforOCL) {
return false;
}
if (flags.flags.schedulerKernel || flags.flags.vmeKernel) {
if (flags.flags.vmeKernel) {
return false;
}
@@ -77,13 +77,12 @@ PreemptionMode PreemptionHelper::getDefaultPreemptionMode(const HardwareInfo &hw
: static_cast<PreemptionMode>(DebugManager.flags.ForcePreemptionMode.get());
}
PreemptionFlags PreemptionHelper::createPreemptionLevelFlags(Device &device, const KernelDescriptor *kernelDescriptor, bool schedulerKernel) {
PreemptionFlags PreemptionHelper::createPreemptionLevelFlags(Device &device, const KernelDescriptor *kernelDescriptor) {
PreemptionFlags flags = {};
if (kernelDescriptor) {
flags.flags.disabledMidThreadPreemptionKernel = kernelDescriptor->kernelAttributes.flags.requiresDisabledMidThreadPreemption;
flags.flags.vmeKernel = kernelDescriptor->kernelAttributes.flags.usesVme;
flags.flags.usesFencesForReadWriteImages = kernelDescriptor->kernelAttributes.flags.usesFencesForReadWriteImages;
flags.flags.schedulerKernel = schedulerKernel;
}
flags.flags.deviceSupportsVmePreemption = device.getDeviceInfo().vmeAvcSupportsPreemption;
flags.flags.disablePerCtxtPreemptionGranularityControl = device.getHardwareInfo().workaroundTable.flags.waDisablePerCtxtPreemptionGranularityControl;

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 2018-2021 Intel Corporation
* Copyright (C) 2018-2022 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
@@ -31,8 +31,7 @@ struct PreemptionFlags {
uint32_t disablePerCtxtPreemptionGranularityControl : 1;
uint32_t usesFencesForReadWriteImages : 1;
uint32_t disableLSQCROPERFforOCL : 1;
uint32_t schedulerKernel : 1;
uint32_t reserved : 25;
uint32_t reserved : 26;
} flags;
uint32_t data;
};
@@ -47,7 +46,7 @@ class PreemptionHelper {
static bool allowThreadGroupPreemption(const PreemptionFlags &flags);
static bool allowMidThreadPreemption(const PreemptionFlags &flags);
static void adjustDefaultPreemptionMode(RuntimeCapabilityTable &deviceCapabilities, bool allowMidThread, bool allowThreadGroup, bool allowMidBatch);
static PreemptionFlags createPreemptionLevelFlags(Device &device, const KernelDescriptor *kernelDescriptor, bool schedulerKernel);
static PreemptionFlags createPreemptionLevelFlags(Device &device, const KernelDescriptor *kernelDescriptor);
template <typename GfxFamily>
static size_t getRequiredPreambleSize(const Device &device);