Skip to content

Commit ef3dffc

Browse files
Remove unused function parameter
Remove parameter requiredThreadArbitrationPolicy from PreambleHelper::programPreamble function. Signed-off-by: Filip Hazubski <[email protected]>
1 parent 86434e4 commit ef3dffc

File tree

8 files changed

+8
-16
lines changed

8 files changed

+8
-16
lines changed

shared/source/command_stream/command_stream_receiver_hw_base.inl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -918,8 +918,7 @@ inline void CommandStreamReceiverHw<GfxFamily>::programStateSip(LinearStream &cm
918918
template <typename GfxFamily>
919919
inline void CommandStreamReceiverHw<GfxFamily>::programPreamble(LinearStream &csr, Device &device, uint32_t &newL3Config) {
920920
if (!this->isPreambleSent) {
921-
auto threadArbitrationPolicy = this->streamProperties.stateComputeMode.threadArbitrationPolicy.value;
922-
PreambleHelper<GfxFamily>::programPreamble(&csr, device, newL3Config, threadArbitrationPolicy, this->preemptionAllocation);
921+
PreambleHelper<GfxFamily>::programPreamble(&csr, device, newL3Config, this->preemptionAllocation);
923922
this->isPreambleSent = true;
924923
this->lastSentL3Config = newL3Config;
925924
}

shared/source/helpers/preamble.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ struct PreambleHelper {
5353
static uint64_t getScratchSpaceAddressOffsetForVfeState(LinearStream *pCommandStream, void *pVfeState);
5454
static void programAdditionalFieldsInVfeState(VFE_STATE_TYPE *mediaVfeState, const HardwareInfo &hwInfo, bool disableEUFusion);
5555
static void programPreamble(LinearStream *pCommandStream, Device &device, uint32_t l3Config,
56-
int32_t requiredThreadArbitrationPolicy, GraphicsAllocation *preemptionCsr);
56+
GraphicsAllocation *preemptionCsr);
5757
static void programKernelDebugging(LinearStream *pCommandStream);
5858
static void programSemaphoreDelay(LinearStream *pCommandStream);
5959
static uint32_t getL3Config(const HardwareInfo &hwInfo, bool useSLM);

shared/source/helpers/preamble_base.inl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ size_t PreambleHelper<GfxFamily>::getCmdSizeForPipelineSelect(const HardwareInfo
6666

6767
template <typename GfxFamily>
6868
void PreambleHelper<GfxFamily>::programPreamble(LinearStream *pCommandStream, Device &device, uint32_t l3Config,
69-
int32_t requiredThreadArbitrationPolicy, GraphicsAllocation *preemptionCsr) {
69+
GraphicsAllocation *preemptionCsr) {
7070
programL3(pCommandStream, l3Config);
7171
programPreemption(pCommandStream, device, preemptionCsr);
7272
if (device.isDebuggerActive()) {

shared/test/common/gen11/test_preamble_gen11.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,6 @@ GEN11TEST_F(ThreadArbitrationGen11, givenPreambleWhenItIsProgrammedThenThreadArb
124124
uint32_t l3Config = PreambleHelper<FamilyType>::getL3Config(*defaultHwInfo, true);
125125
MockDevice mockDevice;
126126
PreambleHelper<FamilyType>::programPreamble(&linearStream, mockDevice, l3Config,
127-
ThreadArbitrationPolicy::RoundRobin,
128127
nullptr);
129128

130129
parseCommands<FamilyType>(cs);

shared/test/common/gen12lp/test_preamble_gen12lp.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ HWTEST2_F(TglLpSlm, givenTglLpWhenPreambleIsBeingProgrammedThenThreadArbitration
2424
uint32_t l3Config = PreambleHelper<TGLLPFamily>::getL3Config(pDevice->getHardwareInfo(), true);
2525
MockDevice mockDevice;
2626
PreambleHelper<TGLLPFamily>::programPreamble(&linearStream, mockDevice, l3Config,
27-
ThreadArbitrationPolicy::RoundRobin,
2827
nullptr);
2928

3029
parseCommands<TGLLPFamily>(cs);

shared/test/common/gen9/preamble_tests_gen9.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@ GEN9TEST_F(ThreadArbitrationGen9, givenPreambleWhenItIsProgrammedThenThreadArbit
7373
uint32_t l3Config = PreambleHelper<FamilyType>::getL3Config(*defaultHwInfo, true);
7474
MockDevice mockDevice;
7575
PreambleHelper<SKLFamily>::programPreamble(&linearStream, mockDevice, l3Config,
76-
ThreadArbitrationPolicy::RoundRobin,
7776
nullptr);
7877

7978
parseCommands<SKLFamily>(cs);

shared/test/common/xe_hp_core/xehp/test_preamble_xehp.cpp

Lines changed: 1 addition & 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
*
@@ -35,7 +35,6 @@ XEHPTEST_F(XeHPSlm, givenTglWhenPreambleIsBeingProgrammedThenThreadArbitrationPo
3535
uint32_t l3Config = PreambleHelper<XeHpFamily>::getL3Config(*defaultHwInfo, true);
3636
MockDevice mockDevice;
3737
PreambleHelper<XeHpFamily>::programPreamble(&linearStream, mockDevice, l3Config,
38-
ThreadArbitrationPolicy::RoundRobin,
3938
nullptr);
4039

4140
parseCommands<XeHpFamily>(cs);

shared/test/unit_test/preamble/preamble_tests.cpp

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (C) 2018-2021 Intel Corporation
2+
* Copyright (C) 2018-2022 Intel Corporation
33
*
44
* SPDX-License-Identifier: MIT
55
*
@@ -75,8 +75,7 @@ HWCMDTEST_F(IGFX_GEN8_CORE, PreambleTest, givenMidThreadPreemptionWhenPreambleIs
7575
uintptr_t minCsrAlignment = 2 * 256 * MemoryConstants::kiloByte;
7676
MockGraphicsAllocation csrSurface(reinterpret_cast<void *>(minCsrAlignment), 1024);
7777

78-
PreambleHelper<FamilyType>::programPreamble(&preambleStream, *mockDevice, 0U,
79-
ThreadArbitrationPolicy::RoundRobin, &csrSurface);
78+
PreambleHelper<FamilyType>::programPreamble(&preambleStream, *mockDevice, 0U, &csrSurface);
8079

8180
PreemptionHelper::programStateSip<FamilyType>(preemptionStream, *mockDevice);
8281

@@ -145,8 +144,7 @@ HWTEST_F(PreambleTest, givenKernelDebuggingActiveWhenPreambleIsProgrammedThenPro
145144
StackVec<char, 8192> preambleBuffer(8192);
146145
LinearStream preambleStream(&*preambleBuffer.begin(), preambleBuffer.size());
147146

148-
PreambleHelper<FamilyType>::programPreamble(&preambleStream, *mockDevice, 0U,
149-
ThreadArbitrationPolicy::RoundRobin, nullptr);
147+
PreambleHelper<FamilyType>::programPreamble(&preambleStream, *mockDevice, 0U, nullptr);
150148

151149
HardwareParse hwParser;
152150
hwParser.parseCommands<FamilyType>(preambleStream);
@@ -159,8 +157,7 @@ HWTEST_F(PreambleTest, givenKernelDebuggingActiveWhenPreambleIsProgrammedThenPro
159157

160158
StackVec<char, 8192> preambleBuffer2(8192);
161159
preambleStream.replaceBuffer(&*preambleBuffer2.begin(), preambleBuffer2.size());
162-
PreambleHelper<FamilyType>::programPreamble(&preambleStream, *mockDevice, 0U,
163-
ThreadArbitrationPolicy::RoundRobin, preemptionAllocation);
160+
PreambleHelper<FamilyType>::programPreamble(&preambleStream, *mockDevice, 0U, preemptionAllocation);
164161
HardwareParse hwParser2;
165162
hwParser2.parseCommands<FamilyType>(preambleStream);
166163
cmdList = hwParser2.getCommandsList<MI_LOAD_REGISTER_IMM>();

0 commit comments

Comments
 (0)