Skip to content

Commit bee5f91

Browse files
Add AIL for Wondershare Filmora
Related-To: NEO-6982 Signed-off-by: Konstanty Misiak <konstanty.misiak@intel.com>
1 parent 481ac32 commit bee5f91

File tree

3 files changed

+38
-4
lines changed

3 files changed

+38
-4
lines changed

shared/source/ail/ail_configuration.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
namespace NEO {
2929

3030
enum class AILEnumeration : uint32_t {
31+
DISABLE_BLITTER,
3132
DISABLE_COMPRESSION,
3233
ENABLE_FP64,
3334
AIL_MAX_OPTIONS_COUNT

shared/source/ail/xe_hpg_core/dg2/ail_configuration_dg2.cpp

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (C) 2021 Intel Corporation
2+
* Copyright (C) 2021-2022 Intel Corporation
33
*
44
* SPDX-License-Identifier: MIT
55
*
@@ -11,9 +11,22 @@
1111
namespace NEO {
1212
static EnableAIL<IGFX_DG2> enableAILDG2;
1313

14-
std::map<std::string_view, std::vector<AILEnumeration>> applicationMapDG2 = {};
14+
std::map<std::string_view, std::vector<AILEnumeration>> applicationMapDG2 = {{"Wondershare Filmora 11", {AILEnumeration::DISABLE_BLITTER}}}; // Blitter is disabled as a temporary mitigation of high GPU utilization
1515

1616
template <>
1717
inline void AILConfigurationHw<IGFX_DG2>::applyExt(RuntimeCapabilityTable &runtimeCapabilityTable) {
18+
auto search = applicationMapDG2.find(processName);
19+
20+
if (search != applicationMapDG2.end()) {
21+
for (size_t i = 0; i < search->second.size(); ++i) {
22+
switch (search->second[i]) {
23+
case AILEnumeration::DISABLE_BLITTER:
24+
runtimeCapabilityTable.blitterOperationsSupported = false;
25+
break;
26+
default:
27+
break;
28+
}
29+
}
30+
}
1831
}
1932
} // namespace NEO

shared/test/unit_test/ail/ail_tests.cpp

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (C) 2021 Intel Corporation
2+
* Copyright (C) 2021-2022 Intel Corporation
33
*
44
* SPDX-License-Identifier: MIT
55
*
@@ -12,6 +12,7 @@
1212

1313
namespace NEO {
1414
using IsSKL = IsProduct<IGFX_SKYLAKE>;
15+
using IsDG2 = IsProduct<IGFX_DG2>;
1516

1617
using AILTests = ::testing::Test;
1718
template <PRODUCT_FAMILY productFamily>
@@ -43,4 +44,23 @@ HWTEST2_F(AILTests, givenInitilizedTemplateWhenApplyWithBlenderIsCalledThenFP64S
4344

4445
EXPECT_EQ(rtTable.ftrSupportsFP64, true);
4546
}
46-
} // namespace NEO
47+
48+
HWTEST2_F(AILTests, givenInitilizedTemplateWhenApplyWithWondershareFilmora11IsCalledThenBlitterSupportIsDisabled, IsDG2) {
49+
VariableBackup<AILConfiguration *> ailConfigurationBackup(&ailConfigurationTable[productFamily]);
50+
51+
AILMock<productFamily> ailTemp;
52+
ailTemp.processName = "Wondershare Filmora 11";
53+
ailConfigurationTable[productFamily] = &ailTemp;
54+
55+
auto ailConfiguration = AILConfiguration::get(productFamily);
56+
ASSERT_NE(nullptr, ailConfiguration);
57+
58+
NEO::RuntimeCapabilityTable rtTable = {};
59+
rtTable.blitterOperationsSupported = true;
60+
61+
ailConfiguration->apply(rtTable);
62+
63+
EXPECT_EQ(rtTable.blitterOperationsSupported, false);
64+
}
65+
66+
} // namespace NEO

0 commit comments

Comments
 (0)