diff --git a/runtime/aub/aub_helper.cpp b/runtime/aub/aub_helper.cpp index 039eb5b5c7..26d4122722 100644 --- a/runtime/aub/aub_helper.cpp +++ b/runtime/aub/aub_helper.cpp @@ -24,9 +24,6 @@ uint64_t AubHelper::getPTEntryBits(uint64_t pdEntryBits) { return pdEntryBits; } -void AubHelper::checkPTEAddress(const HardwareInfo *pHwInfo, uint64_t address) { -} - uint32_t AubHelper::getMemType(uint32_t addressSpace) { return 0; } diff --git a/runtime/aub/aub_helper.h b/runtime/aub/aub_helper.h index 46ccbd2457..44af008e9d 100644 --- a/runtime/aub/aub_helper.h +++ b/runtime/aub/aub_helper.h @@ -31,7 +31,6 @@ class AubHelper : public NonCopyableOrMovableClass { static uint64_t getTotalMemBankSize(); static int getMemTrace(uint64_t pdEntryBits); static uint64_t getPTEntryBits(uint64_t pdEntryBits); - static void checkPTEAddress(const HardwareInfo *pHwInfo, uint64_t address); static uint32_t getMemType(uint32_t addressSpace); static uint64_t getMemBankSize(const HardwareInfo *pHwInfo); static uint32_t getDevicesCount(const HardwareInfo *pHwInfo); diff --git a/runtime/aub_mem_dump/aub_mem_dump.h b/runtime/aub_mem_dump/aub_mem_dump.h index e51fda7cf7..2e166103e7 100644 --- a/runtime/aub_mem_dump/aub_mem_dump.h +++ b/runtime/aub_mem_dump/aub_mem_dump.h @@ -19,7 +19,6 @@ namespace OCLRT { class AubHelper; -struct HardwareInfo; } namespace AubMemDump { @@ -243,7 +242,7 @@ struct AubPageTableHelper32 : public AubPageTableHelper, PageTableTraits static void createContext(typename Traits::Stream &stream, uint32_t context); static uint64_t reserveAddressPPGTT(typename Traits::Stream &stream, uintptr_t gfxAddress, size_t blockSize, uint64_t physAddress, - uint64_t additionalBits, const OCLRT::AubHelper &aubHelper, const OCLRT::HardwareInfo *hwInfo); + uint64_t additionalBits, const OCLRT::AubHelper &aubHelper); static void fixupLRC(uint8_t *pLrc); }; @@ -259,7 +258,7 @@ struct AubPageTableHelper64 : public AubPageTableHelper, PageTableTraits static void createContext(typename Traits::Stream &stream, uint32_t context); static uint64_t reserveAddressPPGTT(typename Traits::Stream &stream, uintptr_t gfxAddress, size_t blockSize, uint64_t physAddress, - uint64_t additionalBits, const OCLRT::AubHelper &aubHelper, const OCLRT::HardwareInfo *hwInfo); + uint64_t additionalBits, const OCLRT::AubHelper &aubHelper); static void fixupLRC(uint8_t *pLrc); }; @@ -294,8 +293,7 @@ struct AubDump : public std::conditional::reserveAddressGGTT(typename Traits::Stream &stream, co template void AubDump::reserveAddressGGTTAndWriteMmeory(typename Traits::Stream &stream, uintptr_t gfxAddress, const void *memory, uint64_t physAddress, - size_t size, size_t offset, uint64_t additionalBits, - const OCLRT::AubHelper &aubHelper, const HardwareInfo *hwInfo) { + size_t size, size_t offset, + uint64_t additionalBits, const OCLRT::AubHelper &aubHelper) { auto vmAddr = (gfxAddress + offset) & ~(MemoryConstants::pageSize - 1); auto pAddr = physAddress & ~(MemoryConstants::pageSize - 1); - AubDump::reserveAddressPPGTT(stream, vmAddr, MemoryConstants::pageSize, pAddr, additionalBits, aubHelper, hwInfo); + AubDump::reserveAddressPPGTT(stream, vmAddr, MemoryConstants::pageSize, pAddr, additionalBits, aubHelper); int hint = OCLRT::AubHelper::getMemTrace(additionalBits); @@ -142,7 +142,7 @@ void AubDump::setGttEntry(MiGttEntry &entry, uint64_t address, AubGTTDat template uint64_t AubPageTableHelper32::reserveAddressPPGTT(typename Traits::Stream &stream, uintptr_t gfxAddress, size_t blockSize, uint64_t physAddress, - uint64_t additionalBits, const OCLRT::AubHelper &aubHelper, const HardwareInfo *hwInfo) { + uint64_t additionalBits, const OCLRT::AubHelper &aubHelper) { auto startAddress = gfxAddress; auto endAddress = gfxAddress + blockSize - 1; @@ -206,7 +206,7 @@ uint64_t AubPageTableHelper32::reserveAddressPPGTT(typename Traits::Stre template uint64_t AubPageTableHelper64::reserveAddressPPGTT(typename Traits::Stream &stream, uintptr_t gfxAddress, size_t blockSize, uint64_t physAddress, - uint64_t additionalBits, const OCLRT::AubHelper &aubHelper, const HardwareInfo *hwInfo) { + uint64_t additionalBits, const OCLRT::AubHelper &aubHelper) { auto startAddress = gfxAddress; auto endAddress = gfxAddress + blockSize - 1; @@ -312,7 +312,6 @@ uint64_t AubPageTableHelper64::reserveAddressPPGTT(typename Traits::Stre stream.writePTE(startAddress, pte, addressSpace); startAddress += sizeof(pte); - OCLRT::AubHelper::checkPTEAddress(hwInfo, startAddress); physPage += 4096; currPTE++; diff --git a/runtime/command_stream/aub_command_stream_receiver_hw.inl b/runtime/command_stream/aub_command_stream_receiver_hw.inl index cc0664aded..c6bef3ae93 100644 --- a/runtime/command_stream/aub_command_stream_receiver_hw.inl +++ b/runtime/command_stream/aub_command_stream_receiver_hw.inl @@ -421,7 +421,7 @@ void AUBCommandStreamReceiverHw::submitBatchBuffer(uint64_t batchBuff auto physBatchBuffer = ppgtt->map(static_cast(batchBufferGpuAddress), batchBufferSize, entryBits, memoryBank); AubHelperHw aubHelperHw(this->localMemoryEnabled); AUB::reserveAddressPPGTT(*stream, static_cast(batchBufferGpuAddress), batchBufferSize, physBatchBuffer, - entryBits, aubHelperHw, &this->hwInfo); + entryBits, aubHelperHw); AUB::addMemoryWrite( *stream, @@ -625,7 +625,7 @@ void AUBCommandStreamReceiverHw::writeMemory(uint64_t gpuAddress, voi PageWalker walker = [&](uint64_t physAddress, size_t size, size_t offset, uint64_t entryBits) { AUB::reserveAddressGGTTAndWriteMmeory(*stream, static_cast(gpuAddress), cpuAddress, physAddress, size, offset, entryBits, - aubHelperHw, &this->hwInfo); + aubHelperHw); }; ppgtt->pageWalk(static_cast(gpuAddress), size, 0, entryBits, walker, memoryBank); @@ -818,7 +818,7 @@ void AUBCommandStreamReceiverHw::addGUCStartMessage(uint64_t batchBuf AUB::reserveAddressPPGTT(*stream, reinterpret_cast(buffer.get()), bufferSize, physBufferAddres, this->getPPGTTAdditionalBits(linearStream.getGraphicsAllocation()), - aubHelperHw, &this->hwInfo); + aubHelperHw); AUB::addMemoryWrite( *stream, diff --git a/runtime/command_stream/tbx_command_stream_receiver_hw.inl b/runtime/command_stream/tbx_command_stream_receiver_hw.inl index 1322bd3971..ea6429cad7 100644 --- a/runtime/command_stream/tbx_command_stream_receiver_hw.inl +++ b/runtime/command_stream/tbx_command_stream_receiver_hw.inl @@ -234,7 +234,7 @@ void TbxCommandStreamReceiverHw::submitBatchBuffer(uint64_t batchBuff AubHelperHw aubHelperHw(this->localMemoryEnabled); AUB::reserveAddressPPGTT(tbxStream, static_cast(batchBufferGpuAddress), batchBufferSize, physBatchBuffer, - entryBits, aubHelperHw, &this->hwInfo); + entryBits, aubHelperHw); AUB::addMemoryWrite( tbxStream, @@ -373,7 +373,7 @@ void TbxCommandStreamReceiverHw::writeMemory(uint64_t gpuAddress, voi PageWalker walker = [&](uint64_t physAddress, size_t size, size_t offset, uint64_t entryBits) { AUB::reserveAddressGGTTAndWriteMmeory(tbxStream, static_cast(gpuAddress), cpuAddress, physAddress, size, offset, entryBits, - aubHelperHw, &this->hwInfo); + aubHelperHw); }; ppgtt->pageWalk(static_cast(gpuAddress), size, 0, entryBits, walker, memoryBank); diff --git a/unit_tests/aub_tests/command_stream/aub_mem_dump_tests.cpp b/unit_tests/aub_tests/command_stream/aub_mem_dump_tests.cpp index dd82bac2dc..54425c7187 100644 --- a/unit_tests/aub_tests/command_stream/aub_mem_dump_tests.cpp +++ b/unit_tests/aub_tests/command_stream/aub_mem_dump_tests.cpp @@ -86,7 +86,7 @@ HWTEST_F(AubMemDumpTests, reserveMaxAddress) { auto enableLocalMemory = HwHelper::get(hwInfo.pPlatform->eRenderCoreFamily).getEnableLocalMemory(hwInfo); OCLRT::AubHelperHw aubHelperHw(enableLocalMemory); - AUB::reserveAddressPPGTT(aubFile, gAddress, 4096, pAddress, 7, aubHelperHw, &hwInfo); + AUB::reserveAddressPPGTT(aubFile, gAddress, 4096, pAddress, 7, aubHelperHw); aubFile.fileHandle.close(); } @@ -108,7 +108,7 @@ HWTEST_F(AubMemDumpTests, DISABLED_writeVerifyOneBytePPGTT) { uint64_t physAddress = reinterpret_cast(&byte) & 0xFFFFFFFF; OCLRT::AubHelperHw aubHelperHw(false); - AUB::reserveAddressPPGTT(aubFile, gAddress, sizeof(byte), physAddress, 7, aubHelperHw, &pDevice->getHardwareInfo()); + AUB::reserveAddressPPGTT(aubFile, gAddress, sizeof(byte), physAddress, 7, aubHelperHw); AUB::addMemoryWrite(aubFile, physAddress, &byte, sizeof(byte), AubMemDump::AddressSpaceValues::TraceNonlocal); aubFile.expectMemory(physAddress, &byte, sizeof(byte), AubMemDump::AddressSpaceValues::TraceNonlocal, AubMemDump::CmdServicesMemTraceMemoryCompare::CompareOperationValues::CompareEqual); @@ -156,7 +156,7 @@ HWTEST_F(AubMemDumpTests, writeVerifySevenBytesPPGTT) { auto physAddress = reinterpret_cast(bytes) & 0xFFFFFFFF; OCLRT::AubHelperHw aubHelperHw(false); - AUB::reserveAddressPPGTT(aubFile, gAddress, sizeof(bytes), physAddress, 7, aubHelperHw, &pDevice->getHardwareInfo()); + AUB::reserveAddressPPGTT(aubFile, gAddress, sizeof(bytes), physAddress, 7, aubHelperHw); AUB::addMemoryWrite(aubFile, physAddress, bytes, sizeof(bytes), AubMemDump::AddressSpaceValues::TraceNonlocal); aubFile.expectMemory(physAddress, bytes, sizeof(bytes), AubMemDump::AddressSpaceValues::TraceNonlocal, AubMemDump::CmdServicesMemTraceMemoryCompare::CompareOperationValues::CompareEqual); diff --git a/unit_tests/aub_tests/gen10/batch_buffer/aub_batch_buffer_tests_gen10.cpp b/unit_tests/aub_tests/gen10/batch_buffer/aub_batch_buffer_tests_gen10.cpp index 2c3a85e739..fbc69810d8 100644 --- a/unit_tests/aub_tests/gen10/batch_buffer/aub_batch_buffer_tests_gen10.cpp +++ b/unit_tests/aub_tests/gen10/batch_buffer/aub_batch_buffer_tests_gen10.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2017-2018 Intel Corporation + * Copyright (C) 2017-2019 Intel Corporation * * SPDX-License-Identifier: MIT * diff --git a/unit_tests/aub_tests/gen10/batch_buffer/aub_batch_buffer_tests_gen10.h b/unit_tests/aub_tests/gen10/batch_buffer/aub_batch_buffer_tests_gen10.h index e800f32910..5febcb5471 100644 --- a/unit_tests/aub_tests/gen10/batch_buffer/aub_batch_buffer_tests_gen10.h +++ b/unit_tests/aub_tests/gen10/batch_buffer/aub_batch_buffer_tests_gen10.h @@ -55,7 +55,7 @@ void setupAUBWithBatchBuffer(const OCLRT::Device *pDevice, OCLRT::EngineType eng OCLRT::AubHelperHw aubHelperHw(false); - AUB::reserveAddressPPGTT(aubFile, gpuBatchBuffer, sizeBatchBuffer, physBatchBuffer, 7, aubHelperHw, &pDevice->getHardwareInfo()); + AUB::reserveAddressPPGTT(aubFile, gpuBatchBuffer, sizeBatchBuffer, physBatchBuffer, 7, aubHelperHw); uint8_t batchBuffer[sizeBatchBuffer]; auto noop = MI_NOOP::sInit(); diff --git a/unit_tests/aub_tests/gen9/batch_buffer/aub_batch_buffer_tests.h b/unit_tests/aub_tests/gen9/batch_buffer/aub_batch_buffer_tests.h index d02c5a578c..26d8ae36b6 100644 --- a/unit_tests/aub_tests/gen9/batch_buffer/aub_batch_buffer_tests.h +++ b/unit_tests/aub_tests/gen9/batch_buffer/aub_batch_buffer_tests.h @@ -56,7 +56,7 @@ void setupAUBWithBatchBuffer(const OCLRT::Device *pDevice, OCLRT::EngineType eng OCLRT::AubHelperHw aubHelperHw(false); - AUB::reserveAddressPPGTT(aubFile, gpuBatchBuffer, sizeBatchBuffer, physBatchBuffer, 7, aubHelperHw, &pDevice->getHardwareInfo()); + AUB::reserveAddressPPGTT(aubFile, gpuBatchBuffer, sizeBatchBuffer, physBatchBuffer, 7, aubHelperHw); uint8_t batchBuffer[sizeBatchBuffer]; auto noop = FamilyType::cmdInitNoop;