diff --git a/shared/source/aub/aub_center.cpp b/shared/source/aub/aub_center.cpp index 592046fd86..dfd9312f38 100644 --- a/shared/source/aub/aub_center.cpp +++ b/shared/source/aub/aub_center.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2018-2020 Intel Corporation + * Copyright (C) 2018-2021 Intel Corporation * * SPDX-License-Identifier: MIT * @@ -29,10 +29,14 @@ AubCenter::AubCenter(const HardwareInfo *pHwInfo, bool localMemoryEnabled, const aubStreamMode = getAubStreamMode(aubFileName, type); - AubHelper::setAdditionalMmioList(); - if (DebugManager.flags.AubDumpAddMmioRegistersList.get() != "unk") { - aub_stream::injectMMIOList(AubHelper::getAdditionalMmioList()); - } + auto &hwHelper = HwHelper::get(pHwInfo->platform.eRenderCoreFamily); + + aub_stream::MMIOList extraMmioList = hwHelper.getExtraMmioList(); + aub_stream::MMIOList debugMmioList = AubHelper::getAdditionalMmioList(); + + extraMmioList.insert(extraMmioList.end(), debugMmioList.begin(), debugMmioList.end()); + + aub_stream::injectMMIOList(extraMmioList); AubHelper::setTbxConfiguration(); diff --git a/shared/source/aub/aub_helper.cpp b/shared/source/aub/aub_helper.cpp index cd05a90fd8..0f895a529a 100644 --- a/shared/source/aub/aub_helper.cpp +++ b/shared/source/aub/aub_helper.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2018-2020 Intel Corporation + * Copyright (C) 2018-2021 Intel Corporation * * SPDX-License-Identifier: MIT * @@ -35,9 +35,6 @@ uint64_t AubHelper::getMemBankSize(const HardwareInfo *pHwInfo) { return getTotalMemBankSize(); } -void AubHelper::setAdditionalMmioList() { -} - void AubHelper::setTbxConfiguration() { aub_stream::setTbxServerIp(DebugManager.flags.TbxServer.get()); aub_stream::setTbxServerPort(DebugManager.flags.TbxPort.get()); diff --git a/shared/source/aub/aub_helper.h b/shared/source/aub/aub_helper.h index 716db5eb6d..6550889e5b 100644 --- a/shared/source/aub/aub_helper.h +++ b/shared/source/aub/aub_helper.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2018-2020 Intel Corporation + * Copyright (C) 2018-2021 Intel Corporation * * SPDX-License-Identifier: MIT * @@ -44,7 +44,6 @@ class AubHelper : public NonCopyableOrMovableClass { static uint32_t getMemType(uint32_t addressSpace); static uint64_t getMemBankSize(const HardwareInfo *pHwInfo); static MMIOList getAdditionalMmioList(); - static void setAdditionalMmioList(); static void setTbxConfiguration(); virtual int getDataHintForPml4Entry() const = 0; @@ -57,7 +56,6 @@ class AubHelper : public NonCopyableOrMovableClass { virtual int getMemTraceForPdEntry() const = 0; virtual int getMemTraceForPtEntry() const = 0; - protected: static MMIOList splitMMIORegisters(const std::string ®isters, char delimiter); }; diff --git a/shared/source/helpers/hw_helper.h b/shared/source/helpers/hw_helper.h index 3374e60624..38cc116569 100644 --- a/shared/source/helpers/hw_helper.h +++ b/shared/source/helpers/hw_helper.h @@ -17,6 +17,7 @@ #include "engine_group_types.h" #include "hw_cmds.h" +#include "third_party/aub_stream/headers/aubstream.h" #include #include @@ -129,6 +130,7 @@ class HwHelper { virtual bool additionalKernelExecInfoSupported(const HardwareInfo &hwInfo) const = 0; virtual bool isCpuImageTransferPreferred(const HardwareInfo &hwInfo) const = 0; virtual bool isKmdMigrationSupported(const HardwareInfo &hwInfo) const = 0; + virtual aub_stream::MMIOList getExtraMmioList() const = 0; static uint32_t getSubDevicesCount(const HardwareInfo *pHwInfo); static uint32_t getEnginesCount(const HardwareInfo &hwInfo); @@ -328,6 +330,8 @@ class HwHelperHw : public HwHelper { bool isCpuImageTransferPreferred(const HardwareInfo &hwInfo) const override; + aub_stream::MMIOList getExtraMmioList() const override; + protected: LocalMemoryAccessMode getDefaultLocalMemoryAccessMode(const HardwareInfo &hwInfo) const override; diff --git a/shared/source/helpers/hw_helper_bdw_plus.inl b/shared/source/helpers/hw_helper_bdw_plus.inl index 5e44b57f5e..eba7faa45a 100644 --- a/shared/source/helpers/hw_helper_bdw_plus.inl +++ b/shared/source/helpers/hw_helper_bdw_plus.inl @@ -98,6 +98,11 @@ uint64_t HwHelperHw::getGpuTimeStampInNS(uint64_t timeStamp, double f return static_cast(timeStamp * frequency); } +template +aub_stream::MMIOList HwHelperHw::getExtraMmioList() const { + return {}; +} + template inline void MemorySynchronizationCommands::addPipeControlWA(LinearStream &commandStream, uint64_t gpuAddress, const HardwareInfo &hwInfo) { }