mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 23:03:02 +08:00
AUB file name with suffix to indicate multiple subdevices
Change-Id: I8a6417e0c1b30c938ce863c15c5cf91da504d330 Signed-off-by: Slawomir Milczarek <slawomir.milczarek@intel.com>
This commit is contained in:
@@ -10,6 +10,7 @@
|
|||||||
#include "core/helpers/debug_helpers.h"
|
#include "core/helpers/debug_helpers.h"
|
||||||
#include "core/helpers/hw_info.h"
|
#include "core/helpers/hw_info.h"
|
||||||
#include "runtime/execution_environment/execution_environment.h"
|
#include "runtime/execution_environment/execution_environment.h"
|
||||||
|
#include "runtime/helpers/device_helpers.h"
|
||||||
#include "runtime/helpers/options.h"
|
#include "runtime/helpers/options.h"
|
||||||
#include "runtime/memory_manager/os_agnostic_memory_manager.h"
|
#include "runtime/memory_manager/os_agnostic_memory_manager.h"
|
||||||
#include "runtime/os_interface/os_inc_base.h"
|
#include "runtime/os_interface/os_inc_base.h"
|
||||||
@@ -27,8 +28,13 @@ std::string AUBCommandStreamReceiver::createFullFilePath(const HardwareInfo &hwI
|
|||||||
// Generate the full filename
|
// Generate the full filename
|
||||||
const auto >SystemInfo = hwInfo.gtSystemInfo;
|
const auto >SystemInfo = hwInfo.gtSystemInfo;
|
||||||
std::stringstream strfilename;
|
std::stringstream strfilename;
|
||||||
|
auto subDevicesCount = DeviceHelper::getSubDevicesCount(&hwInfo);
|
||||||
uint32_t subSlicesPerSlice = gtSystemInfo.SubSliceCount / gtSystemInfo.SliceCount;
|
uint32_t subSlicesPerSlice = gtSystemInfo.SubSliceCount / gtSystemInfo.SliceCount;
|
||||||
strfilename << hwPrefix << "_" << gtSystemInfo.SliceCount << "x" << subSlicesPerSlice << "x" << gtSystemInfo.MaxEuPerSubSlice << "_" << filename << ".aub";
|
strfilename << hwPrefix << "_";
|
||||||
|
if (subDevicesCount > 1) {
|
||||||
|
strfilename << subDevicesCount << "tx";
|
||||||
|
}
|
||||||
|
strfilename << gtSystemInfo.SliceCount << "x" << subSlicesPerSlice << "x" << gtSystemInfo.MaxEuPerSubSlice << "_" << filename << ".aub";
|
||||||
|
|
||||||
// clean-up any fileName issues because of the file system incompatibilities
|
// clean-up any fileName issues because of the file system incompatibilities
|
||||||
auto fileName = strfilename.str();
|
auto fileName = strfilename.str();
|
||||||
|
|||||||
@@ -975,3 +975,15 @@ HWTEST_F(AubFileStreamTests, givenAddPatchInfoCommentsCalledWhenTargetAllocation
|
|||||||
lineNo++;
|
lineNo++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
HWTEST_F(AubFileStreamTests, givenAubCommandStreamReceiverWhenCreateFullFilePathIsCalledForMultipleDevicesThenFileNameIsExtendedWithSuffixToIndicateMultipleDevices) {
|
||||||
|
DebugManagerStateRestore stateRestore;
|
||||||
|
|
||||||
|
DebugManager.flags.CreateMultipleSubDevices.set(1);
|
||||||
|
auto fullName = AUBCommandStreamReceiver::createFullFilePath(*platformDevices[0], "aubfile");
|
||||||
|
EXPECT_EQ(std::string::npos, fullName.find("tx"));
|
||||||
|
|
||||||
|
DebugManager.flags.CreateMultipleSubDevices.set(2);
|
||||||
|
fullName = AUBCommandStreamReceiver::createFullFilePath(*platformDevices[0], "aubfile");
|
||||||
|
EXPECT_NE(std::string::npos, fullName.find("2tx"));
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user