refactor: remove not needed code

Related-To: NEO-7527

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
Mateusz Jablonski
2023-09-27 09:15:56 +00:00
committed by Compute-Runtime-Automation
parent cb730d11f4
commit 3a21b3b228
113 changed files with 16 additions and 14838 deletions

View File

@@ -136,48 +136,6 @@ const std::map<std::string, std::map<std::string, uint64_t>> guidToKeyOffsetMap
{"DISPLAY_VC1_READS[13]", 1456},
{"DISPLAY_VC1_READS[14]", 1464},
{"DISPLAY_VC1_READS[15]", 1472}}},
{"0xfdc76194", // For XeHP_SDV device
{{"HBM0MaxDeviceTemperature", 28},
{"HBM1MaxDeviceTemperature", 36},
{"TileMinTemperature", 40},
{"TileMaxTemperature", 44},
{"GTMinTemperature", 48},
{"GTMaxTemperature", 52},
{"VF0_VFID", 88},
{"VF0_HBM0_READ", 92},
{"VF0_HBM0_WRITE", 96},
{"VF0_HBM1_READ", 104},
{"VF0_HBM1_WRITE", 108},
{"VF0_TIMESTAMP_L", 168},
{"VF0_TIMESTAMP_H", 172},
{"VF1_VFID", 176},
{"VF1_HBM0_READ", 180},
{"VF1_HBM0_WRITE", 184},
{"VF1_HBM1_READ", 192},
{"VF1_HBM1_WRITE", 196},
{"VF1_TIMESTAMP_L", 256},
{"VF1_TIMESTAMP_H", 260}}},
{"0xfdc76196", // For XeHP_SDV B0 device
{{"HBM0MaxDeviceTemperature", 28},
{"HBM1MaxDeviceTemperature", 36},
{"TileMinTemperature", 40},
{"TileMaxTemperature", 44},
{"GTMinTemperature", 48},
{"GTMaxTemperature", 52},
{"VF0_VFID", 88},
{"VF0_HBM0_READ", 92},
{"VF0_HBM0_WRITE", 96},
{"VF0_HBM1_READ", 104},
{"VF0_HBM1_WRITE", 108},
{"VF0_TIMESTAMP_L", 168},
{"VF0_TIMESTAMP_H", 172},
{"VF1_VFID", 176},
{"VF1_HBM0_READ", 180},
{"VF1_HBM0_WRITE", 184},
{"VF1_HBM1_READ", 192},
{"VF1_HBM1_WRITE", 196},
{"VF1_TIMESTAMP_L", 256},
{"VF1_TIMESTAMP_H", 260}}},
{"0xb15a0edc", // For PVC device
{{"HBM0MaxDeviceTemperature", 28},
{"HBM1MaxDeviceTemperature", 36},

View File

@@ -60,7 +60,7 @@ struct MockPmtFsAccess : public FsAccess {
std::string guidPathForSubdevice1 = baseTelemSysFSNodeForSubdevice1 + std::string("/guid");
if ((file.compare(guidPathForSubdevice0) == 0) ||
(file.compare(guidPathForSubdevice1) == 0)) {
val = "0xfdc76194";
val = "0x490e01";
return ZE_RESULT_SUCCESS;
}
return ZE_RESULT_ERROR_NOT_AVAILABLE;

View File

@@ -604,68 +604,6 @@ HWTEST2_F(SysmanDeviceMemoryFixture, GivenValidMemoryHandleWhenCallingzesSysmanM
}
}
HWTEST2_F(SysmanDeviceMemoryFixture, GivenValidMemoryHandleWhenCallingzesSysmanMemoryGetBandwidthWhenVFID0IsActiveThenSuccessIsReturnedAndBandwidthIsValid, IsXEHP) {
setLocalSupportedAndReinit(true);
auto handles = getMemoryHandles(memoryHandleComponentCount);
for (auto &handle : handles) {
zes_mem_bandwidth_t bandwidth{};
uint64_t expectedReadCounters = 0, expectedWriteCounters = 0;
uint64_t expectedBandwidth = 0;
zes_mem_properties_t properties = {ZES_STRUCTURE_TYPE_MEM_PROPERTIES};
zesMemoryGetProperties(handle, &properties);
auto hwInfo = pLinuxSysmanImp->getDeviceHandle()->getNEODevice()->getRootDeviceEnvironment().getMutableHardwareInfo();
auto &productHelper = pLinuxSysmanImp->getDeviceHandle()->getNEODevice()->getProductHelper();
hwInfo->platform.usRevId = productHelper.getHwRevIdFromStepping(REVISION_B, *hwInfo);
auto pPmt = static_cast<MockMemoryPmt *>(pLinuxSysmanImp->getPlatformMonitoringTechAccess(properties.subdeviceId));
pPmt->mockVfid0Status = true;
pSysfsAccess->mockReadUInt64Value.push_back(hbmRP0Frequency);
pSysfsAccess->mockReadReturnStatus.push_back(ZE_RESULT_SUCCESS);
EXPECT_EQ(zesMemoryGetBandwidth(handle, &bandwidth), ZE_RESULT_SUCCESS);
expectedReadCounters = vF0Hbm0ReadValue + vF0Hbm1ReadValue + vF0Hbm2ReadValue + vF0Hbm3ReadValue;
EXPECT_EQ(bandwidth.readCounter, expectedReadCounters);
expectedWriteCounters = vF0Hbm0WriteValue + vF0Hbm1WriteValue + vF0Hbm2WriteValue + vF0Hbm3WriteValue;
EXPECT_EQ(bandwidth.writeCounter, expectedWriteCounters);
EXPECT_GT(bandwidth.timestamp, 0u);
expectedBandwidth = 128 * hbmRP0Frequency * 1000 * 1000 * 4;
EXPECT_EQ(bandwidth.maxBandwidth, expectedBandwidth);
}
}
HWTEST2_F(SysmanDeviceMemoryFixture, GivenValidMemoryHandleWhenCallingzesSysmanMemoryGetBandwidthWhenVFID1IsActiveThenSuccessIsReturnedAndBandwidthIsValid, IsXEHP) {
setLocalSupportedAndReinit(true);
auto handles = getMemoryHandles(memoryHandleComponentCount);
for (auto &handle : handles) {
zes_mem_bandwidth_t bandwidth{};
uint64_t expectedReadCounters = 0, expectedWriteCounters = 0;
uint64_t expectedBandwidth = 0;
zes_mem_properties_t properties = {ZES_STRUCTURE_TYPE_MEM_PROPERTIES};
zesMemoryGetProperties(handle, &properties);
auto hwInfo = pLinuxSysmanImp->getDeviceHandle()->getNEODevice()->getRootDeviceEnvironment().getMutableHardwareInfo();
auto &productHelper = pLinuxSysmanImp->getDeviceHandle()->getNEODevice()->getProductHelper();
hwInfo->platform.usRevId = productHelper.getHwRevIdFromStepping(REVISION_B, *hwInfo);
auto pPmt = static_cast<MockMemoryPmt *>(pLinuxSysmanImp->getPlatformMonitoringTechAccess(properties.subdeviceId));
pPmt->mockVfid1Status = true;
pSysfsAccess->mockReadUInt64Value.push_back(hbmRP0Frequency);
pSysfsAccess->mockReadReturnStatus.push_back(ZE_RESULT_SUCCESS);
EXPECT_EQ(zesMemoryGetBandwidth(handle, &bandwidth), ZE_RESULT_SUCCESS);
expectedReadCounters = vF1Hbm0ReadValue + vF1Hbm1ReadValue + vF1Hbm2ReadValue + vF1Hbm3ReadValue;
EXPECT_EQ(bandwidth.readCounter, expectedReadCounters);
expectedWriteCounters = vF1Hbm0WriteValue + vF1Hbm1WriteValue + vF1Hbm2WriteValue + vF1Hbm3WriteValue;
EXPECT_EQ(bandwidth.writeCounter, expectedWriteCounters);
EXPECT_GT(bandwidth.timestamp, 0u);
expectedBandwidth = 128 * hbmRP0Frequency * 1000 * 1000 * 4;
EXPECT_EQ(bandwidth.maxBandwidth, expectedBandwidth);
}
}
HWTEST2_F(SysmanDeviceMemoryFixture, GivenValidUsRevIdForRevisionBWhenCallingzesSysmanMemoryGetBandwidthThenSuccessIsReturnedAndBandwidthIsValid, IsPVC) {
setLocalSupportedAndReinit(true);
auto handles = getMemoryHandles(memoryHandleComponentCount);