mirror of
https://github.com/intel/compute-runtime.git
synced 2025-09-15 13:01:45 +08:00
Fix ThreadArbitrationMode programming
For non-kernel submission, TAM was incorrectly reprogrammed to default mode. Correct programming should reuse value from previous submission. Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
This commit is contained in:

committed by
Compute-Runtime-Automation

parent
79bf9401ef
commit
e7f2676d5e
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2021 Intel Corporation
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@ -664,6 +664,25 @@ HWTEST_F(CommandStreamReceiverFlushTaskTests, givenStaticPartitioningEnabledWhen
|
||||
EXPECT_TRUE(found);
|
||||
}
|
||||
|
||||
HWTEST_F(CommandStreamReceiverFlushTaskTests, givenEnqueueWithoutArbitrationPolicyWhenPolicyIsAlreadyProgrammedThenReuse) {
|
||||
auto &commandStreamReceiver = pDevice->getUltCommandStreamReceiver<FamilyType>();
|
||||
auto &csrThreadArbitrationPolicy = commandStreamReceiver.streamProperties.stateComputeMode.threadArbitrationPolicy.value;
|
||||
|
||||
uint32_t sentThreadArbitrationPolicy = ThreadArbitrationPolicy::RoundRobinAfterDependency;
|
||||
|
||||
flushTaskFlags.threadArbitrationPolicy = sentThreadArbitrationPolicy;
|
||||
|
||||
flushTask(commandStreamReceiver);
|
||||
|
||||
EXPECT_EQ(static_cast<uint32_t>(csrThreadArbitrationPolicy), sentThreadArbitrationPolicy);
|
||||
|
||||
flushTaskFlags.threadArbitrationPolicy = ThreadArbitrationPolicy::NotPresent;
|
||||
|
||||
flushTask(commandStreamReceiver);
|
||||
|
||||
EXPECT_EQ(static_cast<uint32_t>(csrThreadArbitrationPolicy), sentThreadArbitrationPolicy);
|
||||
}
|
||||
|
||||
struct PreambleThreadArbitrationMatcher {
|
||||
template <PRODUCT_FAMILY productFamily>
|
||||
static constexpr bool isMatched() {
|
||||
|
Reference in New Issue
Block a user