mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-25 05:24:02 +08:00
Revert "refactor: Add dc flush mitigation infrastructure"
This reverts commit 9dbf83c85a.
Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
06a00f5120
commit
ad2ff7972c
@@ -212,9 +212,6 @@ struct PerformanceHintEnqueueMapTest : public PerformanceHintEnqueueTest,
|
||||
|
||||
void SetUp() override {
|
||||
PerformanceHintEnqueueTest::SetUp();
|
||||
if (context->getDevice(0)->getRootDeviceEnvironment().getProductHelper().isDcFlushMitigated()) {
|
||||
GTEST_SKIP();
|
||||
}
|
||||
}
|
||||
|
||||
void TearDown() override {
|
||||
|
||||
@@ -130,7 +130,6 @@ class ProductHelper {
|
||||
virtual bool isTile64With3DSurfaceOnBCSSupported(const HardwareInfo &hwInfo) const = 0;
|
||||
virtual bool isDcFlushAllowed() const = 0;
|
||||
virtual bool isDcFlushMitigated() const = 0;
|
||||
virtual bool mitigateDcFlush() const = 0;
|
||||
virtual bool overridePatAndUsageForDcFlushMitigation(AllocationType allocationType) const = 0;
|
||||
virtual bool overrideCacheableForDcFlushMitigation(AllocationType allocationType) const = 0;
|
||||
virtual uint32_t computeMaxNeededSubSliceSpace(const HardwareInfo &hwInfo) const = 0;
|
||||
|
||||
@@ -389,7 +389,7 @@ bool ProductHelperHw<gfxProduct>::isDisableScratchPagesSupported() const {
|
||||
template <PRODUCT_FAMILY gfxProduct>
|
||||
bool ProductHelperHw<gfxProduct>::isDcFlushAllowed() const {
|
||||
using GfxProduct = typename HwMapper<gfxProduct>::GfxProduct;
|
||||
bool dcFlushAllowed = GfxProduct::isDcFlushAllowed && !this->mitigateDcFlush();
|
||||
bool dcFlushAllowed = GfxProduct::isDcFlushAllowed;
|
||||
|
||||
if (debugManager.flags.AllowDcFlush.get() != -1) {
|
||||
dcFlushAllowed = debugManager.flags.AllowDcFlush.get();
|
||||
@@ -398,11 +398,6 @@ bool ProductHelperHw<gfxProduct>::isDcFlushAllowed() const {
|
||||
return dcFlushAllowed;
|
||||
}
|
||||
|
||||
template <PRODUCT_FAMILY gfxProduct>
|
||||
bool ProductHelperHw<gfxProduct>::mitigateDcFlush() const {
|
||||
return false;
|
||||
}
|
||||
|
||||
template <PRODUCT_FAMILY gfxProduct>
|
||||
bool ProductHelperHw<gfxProduct>::isDcFlushMitigated() const {
|
||||
using GfxProduct = typename HwMapper<gfxProduct>::GfxProduct;
|
||||
|
||||
@@ -75,7 +75,6 @@ class ProductHelperHw : public ProductHelper {
|
||||
bool isTile64With3DSurfaceOnBCSSupported(const HardwareInfo &hwInfo) const override;
|
||||
bool isDcFlushAllowed() const override;
|
||||
bool isDcFlushMitigated() const override;
|
||||
bool mitigateDcFlush() const override;
|
||||
bool overridePatAndUsageForDcFlushMitigation(AllocationType allocationType) const override;
|
||||
bool overrideCacheableForDcFlushMitigation(AllocationType allocationType) const override;
|
||||
uint32_t computeMaxNeededSubSliceSpace(const HardwareInfo &hwInfo) const override;
|
||||
|
||||
@@ -276,11 +276,6 @@ bool ProductHelperHw<IGFX_UNKNOWN>::isDcFlushMitigated() const {
|
||||
return false;
|
||||
}
|
||||
|
||||
template <>
|
||||
bool ProductHelperHw<IGFX_UNKNOWN>::mitigateDcFlush() const {
|
||||
return false;
|
||||
}
|
||||
|
||||
template <>
|
||||
bool ProductHelperHw<IGFX_UNKNOWN>::overridePatAndUsageForDcFlushMitigation(AllocationType allocationType) const {
|
||||
return false;
|
||||
|
||||
@@ -682,11 +682,6 @@ TEST(GmmTest, givenHwInfoWhenDeviceIsCreatedThenSetThisHwInfoToGmmHelper) {
|
||||
TEST(GmmTest, givenAllocationTypeWhenGettingUsageTypeThenReturnCorrectValue) {
|
||||
MockExecutionEnvironment mockExecutionEnvironment{};
|
||||
const auto &productHelper = mockExecutionEnvironment.rootDeviceEnvironments[0]->getHelper<ProductHelper>();
|
||||
|
||||
if (productHelper.isDcFlushMitigated()) {
|
||||
GTEST_SKIP();
|
||||
}
|
||||
|
||||
for (uint32_t i = 0; i < static_cast<uint32_t>(AllocationType::count); i++) {
|
||||
auto allocationType = static_cast<AllocationType>(i);
|
||||
auto uncachedGmmUsageType = productHelper.isNewCoherencyModelSupported() ? GMM_RESOURCE_USAGE_OCL_BUFFER_CSR_UC : GMM_RESOURCE_USAGE_OCL_BUFFER_CACHELINE_MISALIGNED;
|
||||
@@ -881,10 +876,6 @@ TEST(GmmTest, givenUncachedDebugFlagMaskSetWhenAskingForUsageTypeThenReturnUncac
|
||||
MockExecutionEnvironment mockExecutionEnvironment{};
|
||||
const auto &productHelper = mockExecutionEnvironment.rootDeviceEnvironments[0]->getHelper<ProductHelper>();
|
||||
|
||||
if (productHelper.isDcFlushMitigated()) {
|
||||
GTEST_SKIP();
|
||||
}
|
||||
|
||||
constexpr int64_t bufferMask = 1 << (static_cast<int64_t>(AllocationType::buffer) - 1);
|
||||
constexpr int64_t imageMask = 1 << (static_cast<int64_t>(AllocationType::image) - 1);
|
||||
|
||||
|
||||
@@ -311,11 +311,9 @@ HWTEST_F(ProductHelperTest, givenVariousValuesWhenGettingAubStreamSteppingFromHw
|
||||
|
||||
HWTEST_F(ProductHelperTest, givenDcFlushMitigationWhenOverridePatAndUsageForDcFlushMitigationThenReturnCorrectValue) {
|
||||
DebugManagerStateRestore restorer;
|
||||
if (!productHelper->isDcFlushMitigated()) {
|
||||
for (auto i = 0; i < static_cast<int>(AllocationType::count); ++i) {
|
||||
auto allocationType = static_cast<AllocationType>(i);
|
||||
EXPECT_FALSE(productHelper->overridePatAndUsageForDcFlushMitigation(allocationType));
|
||||
}
|
||||
for (auto i = 0; i < static_cast<int>(AllocationType::count); ++i) {
|
||||
auto allocationType = static_cast<AllocationType>(i);
|
||||
EXPECT_FALSE(productHelper->overridePatAndUsageForDcFlushMitigation(allocationType));
|
||||
}
|
||||
debugManager.flags.AllowDcFlush.set(0);
|
||||
for (auto i = 0; i < static_cast<int>(AllocationType::count); ++i) {
|
||||
|
||||
Reference in New Issue
Block a user