mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-05 09:09:04 +08:00
Revert "refactor: remove platform type string"
This reverts commit 58b443ecf1.
Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
b7ee3486d9
commit
5a6d358166
@@ -425,6 +425,12 @@ std::string &OfflineCompiler::getBuildLog() {
|
||||
return buildLog;
|
||||
}
|
||||
|
||||
void OfflineCompiler::setFamilyType() {
|
||||
familyNameWithType.clear();
|
||||
familyNameWithType.append(familyName[hwInfo.platform.eRenderCoreFamily]);
|
||||
familyNameWithType.append(hwInfo.capabilityTable.platformType);
|
||||
}
|
||||
|
||||
int OfflineCompiler::initHardwareInfoForDeprecatedAcronyms(std::string deviceName, int deviceId) {
|
||||
std::vector<PRODUCT_FAMILY> allSupportedProduct{ALL_SUPPORTED_PRODUCT_FAMILIES};
|
||||
std::transform(deviceName.begin(), deviceName.end(), deviceName.begin(), ::tolower);
|
||||
@@ -442,7 +448,7 @@ int OfflineCompiler::initHardwareInfoForDeprecatedAcronyms(std::string deviceNam
|
||||
setHwInfoValuesFromConfig(config, hwInfo);
|
||||
hardwareInfoBaseSetup[hwInfo.platform.eProductFamily](&hwInfo, true);
|
||||
|
||||
productFamilyName = hardwarePrefix[hwInfo.platform.eProductFamily];
|
||||
setFamilyType();
|
||||
return SUCCESS;
|
||||
}
|
||||
}
|
||||
@@ -468,7 +474,7 @@ int OfflineCompiler::initHardwareInfoForProductConfig(std::string deviceName) {
|
||||
hwInfo.platform.usRevId = revisionId;
|
||||
}
|
||||
deviceConfig = productConfig;
|
||||
productFamilyName = hardwarePrefix[hwInfo.platform.eProductFamily];
|
||||
setFamilyType();
|
||||
return SUCCESS;
|
||||
}
|
||||
argHelper->printf("Could not determine target based on product config: %s\n", deviceName.c_str());
|
||||
@@ -825,8 +831,8 @@ std::string OfflineCompiler::parseBinAsCharArray(uint8_t *binary, size_t size, s
|
||||
// Convert binary to cpp
|
||||
out << "#include <cstddef>\n";
|
||||
out << "#include <cstdint>\n\n";
|
||||
out << "size_t " << builtinName << "BinarySize_" << productFamilyName << " = " << size << ";\n";
|
||||
out << "uint32_t " << builtinName << "Binary_" << productFamilyName << "[" << (size + 3) / 4 << "] = {"
|
||||
out << "size_t " << builtinName << "BinarySize_" << familyNameWithType << " = " << size << ";\n";
|
||||
out << "uint32_t " << builtinName << "Binary_" << familyNameWithType << "[" << (size + 3) / 4 << "] = {"
|
||||
<< std::endl
|
||||
<< " ";
|
||||
|
||||
@@ -1115,9 +1121,9 @@ void OfflineCompiler::writeOutAllFiles() {
|
||||
}
|
||||
} else {
|
||||
if (outputFile.empty()) {
|
||||
fileBase = fileTrunk + "_" + productFamilyName;
|
||||
fileBase = fileTrunk + "_" + familyNameWithType;
|
||||
} else {
|
||||
fileBase = outputFile + "_" + productFamilyName;
|
||||
fileBase = outputFile + "_" + familyNameWithType;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -98,6 +98,7 @@ All supported acronyms: %s.
|
||||
protected:
|
||||
OfflineCompiler();
|
||||
|
||||
void setFamilyType();
|
||||
int initHardwareInfo(std::string deviceName);
|
||||
int initHardwareInfoForProductConfig(std::string deviceName);
|
||||
int initHardwareInfoForDeprecatedAcronyms(std::string deviceName, int deviceId);
|
||||
@@ -133,7 +134,7 @@ All supported acronyms: %s.
|
||||
|
||||
AOT::PRODUCT_CONFIG deviceConfig = {};
|
||||
std::string deviceName;
|
||||
std::string productFamilyName;
|
||||
std::string familyNameWithType;
|
||||
std::string inputFile;
|
||||
std::string outputFile;
|
||||
std::string outputDirectory;
|
||||
|
||||
@@ -84,7 +84,7 @@ StackVec<std::string, 3> getBuiltinResourceNames(EBuiltInOps::Type builtin, Buil
|
||||
auto &gfxCoreHelper = device.getGfxCoreHelper();
|
||||
auto &productHelper = device.getRootDeviceEnvironment().getHelper<ProductHelper>();
|
||||
|
||||
const auto platformName = hardwarePrefix[hwInfo.platform.eProductFamily];
|
||||
const auto platformName = getFamilyNameWithType(hwInfo);
|
||||
const auto revisionId = std::to_string(hwInfo.platform.usRevId);
|
||||
const auto builtinName = getBuiltinAsString(builtin);
|
||||
const auto extension = BuiltinCode::getExtension(type);
|
||||
|
||||
@@ -24,9 +24,9 @@ if("${CMAKE_BUILD_TYPE}" STREQUAL "Debug")
|
||||
list(APPEND __ocloc__options__ "-D DEBUG")
|
||||
endif()
|
||||
|
||||
function(get_bits_for_stateless core_type platform_it_lower)
|
||||
function(get_bits_for_stateless core_type platform_type)
|
||||
# Force 32bits compiling on gen9lp for stateless builtins
|
||||
if((${core_type} STREQUAL "GEN9") AND ((${platform_it_lower} STREQUAL "glk") OR (${platform_it_lower} STREQUAL "bxt")))
|
||||
if((${core_type} STREQUAL "GEN9") AND (${platform_type} STREQUAL "LP"))
|
||||
set(BITS "32" PARENT_SCOPE)
|
||||
else()
|
||||
set(BITS ${NEO_BITS} PARENT_SCOPE)
|
||||
@@ -44,9 +44,9 @@ function(get_builtin_options core_type neo_arch)
|
||||
endfunction()
|
||||
|
||||
# Define function for compiling built-ins (with ocloc)
|
||||
function(compile_builtin core_type platform_it builtin bits builtin_options mode)
|
||||
string(TOLOWER ${platform_it} platform_it_lower)
|
||||
function(compile_builtin core_type platform_type builtin bits builtin_options mode)
|
||||
string(TOLOWER ${core_type} core_type_lower)
|
||||
get_family_name_with_type(${core_type} ${platform_type})
|
||||
set(OUTPUTDIR "${BUILTINS_OUTDIR_WITH_ARCH}/${core_type_lower}")
|
||||
# get filename
|
||||
set(FILENAME ${builtin})
|
||||
@@ -55,40 +55,40 @@ function(compile_builtin core_type platform_it builtin bits builtin_options mode
|
||||
get_filename_component(absolute_filepath ${builtin} ABSOLUTE)
|
||||
|
||||
set(OUTPUT_FILE_SPV
|
||||
${OUTPUTDIR}/${mode}_${BASENAME}_${platform_it_lower}.spv
|
||||
${OUTPUTDIR}/${mode}_${BASENAME}_${family_name_with_type}.spv
|
||||
)
|
||||
list(APPEND __ocloc__options__ "-cl-kernel-arg-info")
|
||||
set(INTERNAL_OPTIONS "${${mode}_OPTIONS}")
|
||||
add_custom_command(
|
||||
OUTPUT ${OUTPUT_FILE_SPV}
|
||||
COMMAND ${ocloc_cmd_prefix} -q -file ${absolute_filepath} -spv_only -device ${platform_it_lower} ${builtin_options} -${bits} -output ${mode}_${BASENAME} -out_dir ${OUTPUTDIR} ${INTERNAL_OPTIONS} -options "$<JOIN:${__ocloc__options__}, >"
|
||||
COMMAND ${ocloc_cmd_prefix} -q -file ${absolute_filepath} -spv_only -device ${DEFAULT_SUPPORTED_${core_type}_${platform_type}_PLATFORM} ${builtin_options} -${bits} -output ${mode}_${BASENAME} -out_dir ${OUTPUTDIR} ${INTERNAL_OPTIONS} -options "$<JOIN:${__ocloc__options__}, >"
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
||||
DEPENDS ${builtin} ocloc copy_compiler_files
|
||||
)
|
||||
foreach(REVISION_ID ${${platform_it}_${core_type}_REVISIONS})
|
||||
foreach(REVISION_ID ${${platform_type}_${core_type}_REVISIONS})
|
||||
set(OUTPUT_FILE_CPP
|
||||
${OUTPUTDIR}/${mode}_${BASENAME}_${platform_it_lower}_${REVISION_ID}.cpp
|
||||
${OUTPUTDIR}/${mode}_${BASENAME}_${family_name_with_type}_${REVISION_ID}.cpp
|
||||
)
|
||||
set(BINARY_OUTPUT "${OUTPUTDIR}/${mode}_${BASENAME}_${REVISION_ID}_${platform_it_lower}")
|
||||
set(BINARY_OUTPUT "${OUTPUTDIR}/${mode}_${BASENAME}_${REVISION_ID}_${family_name_with_type}")
|
||||
if(NOT NEO_DISABLE_BUILTINS_COMPILATION)
|
||||
set(OUTPUT_FILES_BINARIES ${BINARY_OUTPUT}.bin)
|
||||
get_filename_component(absolute_filepath_spv ${OUTPUT_FILE_SPV} ABSOLUTE)
|
||||
add_custom_command(
|
||||
OUTPUT ${OUTPUT_FILES_BINARIES}
|
||||
COMMAND ${ocloc_cmd_prefix} -q -file ${absolute_filepath_spv} -spirv_input -device ${platform_it_lower} ${builtin_options} -${bits} -output ${mode}_${BASENAME}_${REVISION_ID} -out_dir ${OUTPUTDIR} -revision_id ${REVISION_ID} ${INTERNAL_OPTIONS} -options "$<JOIN:${__ocloc__options__}, >"
|
||||
COMMAND ${ocloc_cmd_prefix} -q -file ${absolute_filepath_spv} -spirv_input -device ${DEFAULT_SUPPORTED_${core_type}_${platform_type}_PLATFORM} ${builtin_options} -${bits} -output ${mode}_${BASENAME}_${REVISION_ID} -out_dir ${OUTPUTDIR} -revision_id ${REVISION_ID} ${INTERNAL_OPTIONS} -options "$<JOIN:${__ocloc__options__}, >"
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
||||
DEPENDS ${OUTPUT_FILE_SPV} ocloc copy_compiler_files
|
||||
)
|
||||
add_custom_command(
|
||||
OUTPUT ${OUTPUT_FILE_CPP}
|
||||
COMMAND $<TARGET_FILE:cpp_generate_tool> --file ${BINARY_OUTPUT}.bin --output ${OUTPUT_FILE_CPP} --array ${mode}_${BASENAME} --platform ${platform_it_lower} --revision_id ${REVISION_ID}
|
||||
COMMAND $<TARGET_FILE:cpp_generate_tool> --file ${BINARY_OUTPUT}.bin --output ${OUTPUT_FILE_CPP} --array ${mode}_${BASENAME} --platform ${family_name_with_type} --revision_id ${REVISION_ID}
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
||||
DEPENDS ${OUTPUT_FILES_BINARIES} $<TARGET_FILE:cpp_generate_tool>
|
||||
)
|
||||
list(APPEND BUILTINS_COMMANDS "${OUTPUT_FILE_CPP}")
|
||||
else()
|
||||
foreach(_file_name "bin")
|
||||
set(_file_prebuilt "${NEO_KERNELS_BIN_DIR}/built_ins/${NEO_ARCH}/${core_type_lower}/${mode}_${BASENAME}_${REVISION_ID}_${platform_it_lower}.${_file_name}")
|
||||
set(_file_prebuilt "${NEO_KERNELS_BIN_DIR}/built_ins/${NEO_ARCH}/${core_type_lower}/${mode}_${BASENAME}_${REVISION_ID}_${family_name_with_type}.${_file_name}")
|
||||
if(EXISTS ${_file_prebuilt})
|
||||
add_custom_command(
|
||||
OUTPUT ${BINARY_OUTPUT}.${_file_name}
|
||||
@@ -97,7 +97,7 @@ function(compile_builtin core_type platform_it builtin bits builtin_options mode
|
||||
)
|
||||
endif()
|
||||
endforeach()
|
||||
set(_file_prebuilt "${NEO_KERNELS_BIN_DIR}/built_ins/${NEO_ARCH}/${core_type_lower}/${mode}_${BASENAME}_${platform_it_lower}_${REVISION_ID}.cpp")
|
||||
set(_file_prebuilt "${NEO_KERNELS_BIN_DIR}/built_ins/${NEO_ARCH}/${core_type_lower}/${mode}_${BASENAME}_${family_name_with_type}_${REVISION_ID}.cpp")
|
||||
if(EXISTS ${_file_prebuilt})
|
||||
add_custom_command(
|
||||
OUTPUT ${OUTPUT_FILE_CPP}
|
||||
@@ -157,83 +157,85 @@ function(generate_cpp_spirv builtin)
|
||||
endif()
|
||||
endfunction()
|
||||
|
||||
macro(macro_for_each_platform)
|
||||
unset(IMAGE_SUPPORT)
|
||||
unset(AUX_TRANSLATION_SUPPORT)
|
||||
CORE_CONTAINS_PLATFORMS("SUPPORTED_IMAGES" ${CORE_TYPE} IMAGE_SUPPORT)
|
||||
CORE_CONTAINS_PLATFORMS("SUPPORTED_AUX_TRANSLATION" ${CORE_TYPE} AUX_TRANSLATION_SUPPORT)
|
||||
get_bits_for_stateless(${CORE_TYPE} ${PLATFORM_IT})
|
||||
get_builtin_options(${CORE_TYPE} ${NEO_ARCH})
|
||||
set(target_name builtins_${PLATFORM_IT_LOWER})
|
||||
add_custom_target(${target_name})
|
||||
add_dependencies(builtins ${target_name})
|
||||
set_target_properties(${target_name} PROPERTIES FOLDER "${SHARED_SOURCE_PROJECTS_FOLDER}/${SHARED_BUILTINS_PROJECTS_FOLDER}/${PLATFORM_IT_LOWER}")
|
||||
foreach(MODE ${ADDRESSING_MODES})
|
||||
unset(BUILTINS_COMMANDS)
|
||||
macro(macro_for_each_core_type)
|
||||
foreach(PLATFORM_TYPE ${PLATFORM_TYPES})
|
||||
if(${CORE_TYPE}_HAS_${PLATFORM_TYPE})
|
||||
unset(IMAGE_SUPPORT)
|
||||
unset(AUX_TRANSLATION_SUPPORT)
|
||||
CORE_CONTAINS_PLATFORMS("SUPPORTED_IMAGES" ${CORE_TYPE} IMAGE_SUPPORT)
|
||||
CORE_CONTAINS_PLATFORMS("SUPPORTED_AUX_TRANSLATION" ${CORE_TYPE} AUX_TRANSLATION_SUPPORT)
|
||||
get_family_name_with_type(${CORE_TYPE} ${PLATFORM_TYPE})
|
||||
string(TOLOWER ${PLATFORM_TYPE} PLATFORM_TYPE_LOWER)
|
||||
get_bits_for_stateless(${CORE_TYPE} ${PLATFORM_TYPE})
|
||||
get_builtin_options(${CORE_TYPE} ${NEO_ARCH})
|
||||
set(target_name builtins_${family_name_with_type})
|
||||
add_custom_target(${target_name})
|
||||
add_dependencies(builtins ${target_name})
|
||||
set_target_properties(${target_name} PROPERTIES FOLDER "${SHARED_SOURCE_PROJECTS_FOLDER}/${SHARED_BUILTINS_PROJECTS_FOLDER}/${family_name_with_type}")
|
||||
foreach(MODE ${ADDRESSING_MODES})
|
||||
unset(BUILTINS_COMMANDS)
|
||||
|
||||
if((${MODE} STREQUAL "bindless") AND (NOT BUILD_WITH_L0 OR("${CORE_TYPE}" STREQUAL "GEN8")))
|
||||
continue()
|
||||
endif()
|
||||
if((${MODE} STREQUAL "bindless") AND (NOT BUILD_WITH_L0 OR("${CORE_TYPE}" STREQUAL "GEN8")))
|
||||
continue()
|
||||
endif()
|
||||
|
||||
if(${AUX_TRANSLATION_SUPPORT})
|
||||
foreach(GENERATED_BUILTIN_AUX_TRANSLATION ${GENERATED_BUILTINS_AUX_TRANSLATION})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_IT} ${GENERATED_BUILTIN_AUX_TRANSLATION}.builtin_kernel ${NEO_BITS} "${BUILTIN_OPTIONS}" ${MODE})
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
if(${MODE} STREQUAL "stateless")
|
||||
foreach(GENERATED_BUILTIN_STATELESS ${GENERATED_BUILTINS_STATELESS})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_IT} ${GENERATED_BUILTIN_STATELESS}.builtin_kernel ${BITS} "${BUILTIN_OPTIONS_STATELESS}" ${MODE})
|
||||
endforeach()
|
||||
|
||||
if(${IMAGE_SUPPORT})
|
||||
foreach(GENERATED_BUILTIN_IMAGES_STATELESS ${GENERATED_BUILTINS_IMAGES_STATELESS})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_IT} ${GENERATED_BUILTIN_IMAGES_STATELESS}.builtin_kernel ${BITS} "${BUILTIN_OPTIONS_STATELESS}" ${MODE})
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
if("${CORE_TYPE}" STREQUAL "XE_HPC_CORE")
|
||||
# Compile stateful versions as stateless
|
||||
foreach(GENERATED_BUILTIN ${GENERATED_BUILTINS})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_IT} ${GENERATED_BUILTIN}.builtin_kernel ${NEO_BITS} "${BUILTIN_OPTIONS}" ${MODE})
|
||||
endforeach()
|
||||
|
||||
if(${IMAGE_SUPPORT})
|
||||
foreach(GENERATED_BUILTINS_IMAGES ${GENERATED_BUILTINS_IMAGES})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_IT} ${GENERATED_BUILTINS_IMAGES}.builtin_kernel ${NEO_BITS} "${BUILTIN_OPTIONS}" ${MODE})
|
||||
if(${AUX_TRANSLATION_SUPPORT})
|
||||
foreach(GENERATED_BUILTIN_AUX_TRANSLATION ${GENERATED_BUILTINS_AUX_TRANSLATION})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_TYPE} ${GENERATED_BUILTIN_AUX_TRANSLATION}.builtin_kernel ${NEO_BITS} "${BUILTIN_OPTIONS}" ${MODE})
|
||||
endforeach()
|
||||
endif()
|
||||
endif()
|
||||
else()
|
||||
if("${CORE_TYPE}" STREQUAL "XE_HPC_CORE")
|
||||
continue()
|
||||
endif()
|
||||
foreach(GENERATED_BUILTIN ${GENERATED_BUILTINS})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_IT} ${GENERATED_BUILTIN}.builtin_kernel ${NEO_BITS} "${BUILTIN_OPTIONS}" ${MODE})
|
||||
endforeach()
|
||||
|
||||
if(${IMAGE_SUPPORT})
|
||||
foreach(GENERATED_BUILTINS_IMAGES ${GENERATED_BUILTINS_IMAGES})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_IT} ${GENERATED_BUILTINS_IMAGES}.builtin_kernel ${NEO_BITS} "${BUILTIN_OPTIONS}" ${MODE})
|
||||
if(${MODE} STREQUAL "stateless")
|
||||
foreach(GENERATED_BUILTIN_STATELESS ${GENERATED_BUILTINS_STATELESS})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_TYPE} ${GENERATED_BUILTIN_STATELESS}.builtin_kernel ${BITS} "${BUILTIN_OPTIONS_STATELESS}" ${MODE})
|
||||
endforeach()
|
||||
|
||||
if(${IMAGE_SUPPORT})
|
||||
foreach(GENERATED_BUILTIN_IMAGES_STATELESS ${GENERATED_BUILTINS_IMAGES_STATELESS})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_TYPE} ${GENERATED_BUILTIN_IMAGES_STATELESS}.builtin_kernel ${BITS} "${BUILTIN_OPTIONS_STATELESS}" ${MODE})
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
if("${CORE_TYPE}" STREQUAL "XE_HPC_CORE")
|
||||
# Compile stateful versions as stateless
|
||||
foreach(GENERATED_BUILTIN ${GENERATED_BUILTINS})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_TYPE} ${GENERATED_BUILTIN}.builtin_kernel ${NEO_BITS} "${BUILTIN_OPTIONS}" ${MODE})
|
||||
endforeach()
|
||||
|
||||
if(${IMAGE_SUPPORT})
|
||||
foreach(GENERATED_BUILTINS_IMAGES ${GENERATED_BUILTINS_IMAGES})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_TYPE} ${GENERATED_BUILTINS_IMAGES}.builtin_kernel ${NEO_BITS} "${BUILTIN_OPTIONS}" ${MODE})
|
||||
endforeach()
|
||||
endif()
|
||||
endif()
|
||||
else()
|
||||
if("${CORE_TYPE}" STREQUAL "XE_HPC_CORE")
|
||||
continue()
|
||||
endif()
|
||||
foreach(GENERATED_BUILTIN ${GENERATED_BUILTINS})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_TYPE} ${GENERATED_BUILTIN}.builtin_kernel ${NEO_BITS} "${BUILTIN_OPTIONS}" ${MODE})
|
||||
endforeach()
|
||||
|
||||
if(${IMAGE_SUPPORT})
|
||||
foreach(GENERATED_BUILTINS_IMAGES ${GENERATED_BUILTINS_IMAGES})
|
||||
compile_builtin(${CORE_TYPE} ${PLATFORM_TYPE} ${GENERATED_BUILTINS_IMAGES}.builtin_kernel ${NEO_BITS} "${BUILTIN_OPTIONS}" ${MODE})
|
||||
endforeach()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
get_property(GENERATED_BUILTINS_CPPS_${MODE} GLOBAL PROPERTY GENERATED_BUILTINS_CPPS_${MODE})
|
||||
foreach(BUILTIN ${BUILTINS_COMMANDS})
|
||||
list(APPEND GENERATED_BUILTINS_CPPS_${MODE} ${BUILTIN})
|
||||
endforeach()
|
||||
endif()
|
||||
set_property(GLOBAL PROPERTY GENERATED_BUILTINS_CPPS_${MODE} ${GENERATED_BUILTINS_CPPS_${MODE}})
|
||||
add_custom_target(${target_name}_${MODE} DEPENDS ${BUILTINS_COMMANDS})
|
||||
add_dependencies(${target_name} ${target_name}_${MODE})
|
||||
set_target_properties(${target_name}_${MODE} PROPERTIES FOLDER "${SHARED_SOURCE_PROJECTS_FOLDER}/${SHARED_BUILTINS_PROJECTS_FOLDER}/${family_name_with_type}")
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
get_property(GENERATED_BUILTINS_CPPS_${MODE} GLOBAL PROPERTY GENERATED_BUILTINS_CPPS_${MODE})
|
||||
foreach(BUILTIN ${BUILTINS_COMMANDS})
|
||||
list(APPEND GENERATED_BUILTINS_CPPS_${MODE} ${BUILTIN})
|
||||
endforeach()
|
||||
set_property(GLOBAL PROPERTY GENERATED_BUILTINS_CPPS_${MODE} ${GENERATED_BUILTINS_CPPS_${MODE}})
|
||||
add_custom_target(${target_name}_${MODE} DEPENDS ${BUILTINS_COMMANDS})
|
||||
add_dependencies(${target_name} ${target_name}_${MODE})
|
||||
set_target_properties(${target_name}_${MODE} PROPERTIES FOLDER "${SHARED_SOURCE_PROJECTS_FOLDER}/${SHARED_BUILTINS_PROJECTS_FOLDER}/${PLATFORM_IT_LOWER}")
|
||||
endforeach()
|
||||
endmacro()
|
||||
|
||||
macro(macro_for_each_core_type)
|
||||
apply_macro_for_each_platform("SUPPORTED")
|
||||
endmacro()
|
||||
|
||||
file(MAKE_DIRECTORY "${BUILTINS_OUTDIR_WITH_ARCH}/spirv")
|
||||
foreach(builtin ${GENERATED_BUILTINS})
|
||||
generate_cpp_spirv(${builtin})
|
||||
|
||||
@@ -193,4 +193,5 @@ inline std::pair<DecodeError, DeviceBinaryFormat> decodeSingleDeviceBinary(Progr
|
||||
return ret;
|
||||
}
|
||||
|
||||
bool haveSameCore(PRODUCT_FAMILY productFamilyLeft, PRODUCT_FAMILY productFamilyRight);
|
||||
} // namespace NEO
|
||||
|
||||
@@ -60,8 +60,10 @@ bool validateTargetDevice(const TargetDevice &targetDevice, Elf::ELF_IDENTIFIER_
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if (targetDevice.productFamily != productFamily) {
|
||||
return false;
|
||||
if (productFamily != IGFX_UNKNOWN) {
|
||||
if (false == haveSameCore(targetDevice.productFamily, productFamily)) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (targetMetadata.validateRevisionId) {
|
||||
|
||||
@@ -36,6 +36,7 @@ const RuntimeCapabilityTable EHL::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"ehl", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -36,6 +36,7 @@ const RuntimeCapabilityTable ICLLP::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"icllp", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -36,6 +36,7 @@ const RuntimeCapabilityTable LKF::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"lkf", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -37,6 +37,7 @@ const RuntimeCapabilityTable ADLN::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"adln", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -37,6 +37,7 @@ const RuntimeCapabilityTable ADLP::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"adlp", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -37,6 +37,7 @@ const RuntimeCapabilityTable ADLS::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"adls", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -37,6 +37,7 @@ const RuntimeCapabilityTable DG1::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"dg1", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -37,6 +37,7 @@ const RuntimeCapabilityTable RKL::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"rkl", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -37,6 +37,7 @@ const RuntimeCapabilityTable TGLLP::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"tgllp", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -36,6 +36,7 @@ const RuntimeCapabilityTable BDW::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
80, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"bdw", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::Disabled, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -36,6 +36,7 @@ const RuntimeCapabilityTable BXT::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
52.083, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"bxt", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -36,6 +36,7 @@ const RuntimeCapabilityTable CFL::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"cfl", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -36,6 +36,7 @@ const RuntimeCapabilityTable GLK::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
52.083, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"glk", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -36,6 +36,7 @@ const RuntimeCapabilityTable KBL::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"kbl", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -36,6 +36,7 @@ const RuntimeCapabilityTable SKL::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"skl", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::MidThread, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_RCS, // defaultEngineType
|
||||
|
||||
@@ -29,6 +29,10 @@ uint64_t defaultHardwareInfoConfigTable[IGFX_MAX_PRODUCT] = {
|
||||
0x0,
|
||||
};
|
||||
|
||||
// Global table of family names
|
||||
const char *familyName[IGFX_MAX_CORE] = {
|
||||
nullptr,
|
||||
};
|
||||
// Global table of family names
|
||||
bool familyEnabled[IGFX_MAX_CORE] = {
|
||||
false,
|
||||
@@ -120,4 +124,18 @@ aub_stream::EngineType getChosenEngineType(const HardwareInfo &hwInfo) {
|
||||
? hwInfo.capabilityTable.defaultEngineType
|
||||
: static_cast<aub_stream::EngineType>(DebugManager.flags.NodeOrdinal.get());
|
||||
}
|
||||
|
||||
const std::string getFamilyNameWithType(const HardwareInfo &hwInfo) {
|
||||
std::string platformName = familyName[hwInfo.platform.eRenderCoreFamily];
|
||||
platformName.append(hwInfo.capabilityTable.platformType);
|
||||
return platformName;
|
||||
}
|
||||
|
||||
bool haveSameCore(PRODUCT_FAMILY productFamilyLeft, PRODUCT_FAMILY productFamilyRight) {
|
||||
UNRECOVERABLE_IF(productFamilyLeft >= IGFX_MAX_PRODUCT || productFamilyRight >= IGFX_MAX_PRODUCT);
|
||||
auto hwInfoLeft = NEO::hardwareInfoTable[productFamilyLeft];
|
||||
auto hwInfoRight = NEO::hardwareInfoTable[productFamilyRight];
|
||||
UNRECOVERABLE_IF(hwInfoLeft == nullptr || hwInfoRight == nullptr);
|
||||
return hwInfoLeft->platform.eRenderCoreFamily == hwInfoRight->platform.eRenderCoreFamily;
|
||||
}
|
||||
} // namespace NEO
|
||||
|
||||
@@ -24,6 +24,7 @@ struct RuntimeCapabilityTable {
|
||||
uint64_t sharedSystemMemCapabilities;
|
||||
double defaultProfilingTimerResolution;
|
||||
size_t requiredPreemptionSurfaceSize;
|
||||
const char *platformType;
|
||||
const char *deviceName;
|
||||
PreemptionMode defaultPreemptionMode;
|
||||
aub_stream::EngineType defaultEngineType;
|
||||
@@ -112,6 +113,7 @@ inline bool operator==(const RuntimeCapabilityTable &lhs, const RuntimeCapabilit
|
||||
result &= (lhs.ftrRenderCompressedImages == rhs.ftrRenderCompressedImages);
|
||||
result &= (lhs.ftr64KBpages == rhs.ftr64KBpages);
|
||||
result &= (lhs.instrumentationEnabled == rhs.instrumentationEnabled);
|
||||
result &= (lhs.platformType == rhs.platformType);
|
||||
result &= (lhs.deviceName == rhs.deviceName);
|
||||
result &= (lhs.debuggerSupported == rhs.debuggerSupported);
|
||||
result &= (lhs.supportsVme == rhs.supportsVme);
|
||||
@@ -154,6 +156,7 @@ struct GfxFamilyMapper {};
|
||||
|
||||
// Global table of hardware prefixes
|
||||
extern bool familyEnabled[IGFX_MAX_CORE];
|
||||
extern const char *familyName[IGFX_MAX_CORE];
|
||||
extern const char *hardwarePrefix[IGFX_MAX_PRODUCT];
|
||||
extern uint64_t defaultHardwareInfoConfigTable[IGFX_MAX_PRODUCT];
|
||||
extern const HardwareInfo *hardwareInfoTable[IGFX_MAX_PRODUCT];
|
||||
@@ -164,6 +167,7 @@ template <GFXCORE_FAMILY gfxFamily>
|
||||
struct EnableGfxFamilyHw {
|
||||
EnableGfxFamilyHw() {
|
||||
familyEnabled[gfxFamily] = true;
|
||||
familyName[gfxFamily] = GfxFamilyMapper<gfxFamily>::name;
|
||||
}
|
||||
};
|
||||
|
||||
@@ -171,6 +175,8 @@ bool getHwInfoForPlatformString(std::string &platform, const HardwareInfo *&hwIn
|
||||
void setHwInfoValuesFromConfig(const uint64_t hwInfoConfig, HardwareInfo &hwInfoIn);
|
||||
bool parseHwInfoConfigString(const std::string &hwInfoConfigStr, uint64_t &hwInfoConfig);
|
||||
aub_stream::EngineType getChosenEngineType(const HardwareInfo &hwInfo);
|
||||
const std::string getFamilyNameWithType(const HardwareInfo &hwInfo);
|
||||
bool haveSameCore(PRODUCT_FAMILY productFamilyLeft, PRODUCT_FAMILY productFamilyRight);
|
||||
|
||||
// Utility conversion
|
||||
template <PRODUCT_FAMILY productFamily>
|
||||
|
||||
@@ -40,6 +40,7 @@ const RuntimeCapabilityTable XE_HP_SDV::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"core", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::ThreadGroup, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_CCS, // defaultEngineType
|
||||
|
||||
@@ -50,6 +50,7 @@ const RuntimeCapabilityTable PVC::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"pvc", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::ThreadGroup, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_CCS, // defaultEngineType
|
||||
|
||||
@@ -41,6 +41,7 @@ const RuntimeCapabilityTable DG2::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"dg2", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::ThreadGroup, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_CCS, // defaultEngineType
|
||||
|
||||
@@ -38,6 +38,7 @@ const RuntimeCapabilityTable MTL::capabilityTable{
|
||||
0, // sharedSystemMemCapabilities
|
||||
83.333, // defaultProfilingTimerResolution
|
||||
MemoryConstants::pageSize, // requiredPreemptionSurfaceSize
|
||||
"mtl", // platformType
|
||||
"", // deviceName
|
||||
PreemptionMode::ThreadGroup, // defaultPreemptionMode
|
||||
aub_stream::ENGINE_CCS, // defaultEngineType
|
||||
|
||||
@@ -5,9 +5,9 @@
|
||||
#
|
||||
|
||||
set(SHARED_TEST_PROJECTS_SUB_FOLDER "prepare test files")
|
||||
function(compile_kernels_gen revision_id platform_name)
|
||||
function(compile_kernels_gen platform_name_with_type revision_id platform_name suffix)
|
||||
|
||||
set(outputdir "${TargetDir}/${platform_name}/${revision_id}/test_files/${NEO_ARCH}/")
|
||||
set(outputdir "${TargetDir}/${suffix}/${revision_id}/test_files/${NEO_ARCH}/")
|
||||
set(compiled_kernels)
|
||||
|
||||
foreach(filepath ${ARGN})
|
||||
@@ -16,7 +16,7 @@ function(compile_kernels_gen revision_id platform_name)
|
||||
get_filename_component(workdir ${filepath} DIRECTORY)
|
||||
get_filename_component(absolute_filepath ${filepath} ABSOLUTE)
|
||||
|
||||
set(outputpath_base "${outputdir}${basename}_${platform_name}")
|
||||
set(outputpath_base "${outputdir}${basename}_${suffix}")
|
||||
|
||||
if(NOT NEO_DISABLE_BUILTINS_COMPILATION)
|
||||
set(output_files
|
||||
@@ -31,21 +31,21 @@ function(compile_kernels_gen revision_id platform_name)
|
||||
DEPENDS ${filepath} ocloc copy_compiler_files
|
||||
)
|
||||
|
||||
list(APPEND compiled_kernels_${platform_name}_${revision_id} ${output_files})
|
||||
list(APPEND compiled_kernels_${platform_name_with_type}_${revision_id} ${output_files})
|
||||
else()
|
||||
foreach(_file_name "spv" "bin")
|
||||
set(_file_prebuilt "${NEO_KERNELS_BIN_DIR}/${platform_name}/${revision_id}/test_files/${NEO_ARCH}/${basename}_${platform_name}.${_file_name}")
|
||||
set(_file_prebuilt "${NEO_KERNELS_BIN_DIR}/${suffix}/${revision_id}/test_files/${NEO_ARCH}/${basename}_${suffix}.${_file_name}")
|
||||
add_custom_command(
|
||||
OUTPUT ${outputpath_base}.${_file_name}
|
||||
COMMAND ${CMAKE_COMMAND} -E make_directory ${outputdir}
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${_file_prebuilt} ${outputdir}
|
||||
)
|
||||
|
||||
list(APPEND compiled_kernels_${platform_name}_${revision_id} ${outputpath_base}.${_file_name})
|
||||
list(APPEND compiled_kernels_${platform_name_with_type}_${revision_id} ${outputpath_base}.${_file_name})
|
||||
endforeach()
|
||||
endif()
|
||||
endforeach()
|
||||
set(compiled_kernels_${platform_name}_${revision_id} ${compiled_kernels_${platform_name}_${revision_id}} PARENT_SCOPE)
|
||||
set(compiled_kernels_${platform_name_with_type}_${revision_id} ${compiled_kernels_${platform_name_with_type}_${revision_id}} PARENT_SCOPE)
|
||||
endfunction()
|
||||
|
||||
file(GLOB_RECURSE TEST_KERNELS *.cl)
|
||||
@@ -58,27 +58,41 @@ if(TARGET ${BUILTINS_SPIRV_LIB_NAME})
|
||||
add_dependencies(prepare_test_kernels_for_shared ${BUILTINS_SPIRV_LIB_NAME})
|
||||
endif()
|
||||
set_target_properties(prepare_test_kernels_for_shared PROPERTIES FOLDER "${SHARED_TEST_PROJECTS_FOLDER}/${SHARED_TEST_PROJECTS_SUB_FOLDER}")
|
||||
add_dependencies(prepare_test_kernels_for_shared copy_compiler_files)
|
||||
|
||||
macro(macro_for_each_platform)
|
||||
set(KERNELS_TO_COMPILE ${TEST_KERNELS})
|
||||
set(IMAGE_SUPPORT FALSE)
|
||||
CORE_CONTAINS_PLATFORMS("SUPPORTED_IMAGES" ${CORE_TYPE} IMAGE_SUPPORT)
|
||||
if(NOT IMAGE_SUPPORT)
|
||||
list(REMOVE_ITEM KERNELS_TO_COMPILE ${TEST_KERNELS_IMAGES})
|
||||
endif()
|
||||
|
||||
foreach(REVISION_ID ${${PLATFORM_IT}_${CORE_TYPE}_REVISIONS})
|
||||
compile_kernels_gen(${REVISION_ID} ${PLATFORM_IT_LOWER} ${KERNELS_TO_COMPILE})
|
||||
|
||||
add_custom_target(prepare_test_kernels_for_shared_${PLATFORM_IT_LOWER}_${REVISION_ID} DEPENDS ${compiled_kernels_${PLATFORM_IT_LOWER}_${REVISION_ID}})
|
||||
set_target_properties(prepare_test_kernels_for_shared_${PLATFORM_IT_LOWER}_${REVISION_ID} PROPERTIES FOLDER "${SHARED_TEST_PROJECTS_FOLDER}/${SHARED_TEST_PROJECTS_SUB_FOLDER}/${PLATFORM_SPECIFIC_TEST_TARGETS_FOLDER}/${PLATFORM_IT_LOWER}/${REVISION_ID}")
|
||||
add_dependencies(prepare_test_kernels_for_shared prepare_test_kernels_for_shared_${PLATFORM_IT_LOWER}_${REVISION_ID})
|
||||
foreach(PLATFORM_TYPE ${PLATFORM_TYPES})
|
||||
foreach(REVISION_ID ${${PLATFORM_TYPE}_${CORE_TYPE}_REVISIONS})
|
||||
if(${PLATFORM_IT}_IS_${PLATFORM_TYPE})
|
||||
add_dependencies(prepare_test_kernels_for_shared copy_compiler_files)
|
||||
endif()
|
||||
endforeach()
|
||||
endforeach()
|
||||
endmacro()
|
||||
|
||||
macro(macro_for_each_core_type)
|
||||
apply_macro_for_each_platform("TESTED")
|
||||
foreach(PLATFORM_TYPE ${PLATFORM_TYPES})
|
||||
|
||||
if(${CORE_TYPE}_HAS_${PLATFORM_TYPE})
|
||||
|
||||
set(KERNELS_TO_COMPILE ${TEST_KERNELS})
|
||||
set(IMAGE_SUPPORT FALSE)
|
||||
CORE_CONTAINS_PLATFORMS("SUPPORTED_IMAGES" ${CORE_TYPE} IMAGE_SUPPORT)
|
||||
if(NOT IMAGE_SUPPORT)
|
||||
list(REMOVE_ITEM KERNELS_TO_COMPILE ${TEST_KERNELS_IMAGES})
|
||||
endif()
|
||||
|
||||
get_family_name_with_type(${CORE_TYPE} ${PLATFORM_TYPE})
|
||||
set(PLATFORM_LOWER ${DEFAULT_SUPPORTED_${CORE_TYPE}_${PLATFORM_TYPE}_PLATFORM})
|
||||
foreach(REVISION_ID ${${PLATFORM_TYPE}_${CORE_TYPE}_REVISIONS})
|
||||
compile_kernels_gen(${family_name_with_type} ${REVISION_ID} ${PLATFORM_LOWER} ${family_name_with_type} ${KERNELS_TO_COMPILE})
|
||||
|
||||
add_custom_target(prepare_test_kernels_for_shared_${family_name_with_type}_${REVISION_ID} DEPENDS ${compiled_kernels_${family_name_with_type}_${REVISION_ID}})
|
||||
set_target_properties(prepare_test_kernels_for_shared_${family_name_with_type}_${REVISION_ID} PROPERTIES FOLDER "${SHARED_TEST_PROJECTS_FOLDER}/${SHARED_TEST_PROJECTS_SUB_FOLDER}/${PLATFORM_SPECIFIC_TEST_TARGETS_FOLDER}/${family_name_with_type}/${REVISION_ID}")
|
||||
add_dependencies(prepare_test_kernels_for_shared prepare_test_kernels_for_shared_${family_name_with_type}_${REVISION_ID})
|
||||
endforeach()
|
||||
endif()
|
||||
endforeach()
|
||||
endmacro()
|
||||
|
||||
apply_macro_for_each_core_type("TESTED")
|
||||
|
||||
@@ -24,7 +24,7 @@ HWTEST2_F(BuiltInSharedTest, givenUseBindlessBuiltinDisabledWhenBinExtensionPass
|
||||
DebugManager.flags.UseBindlessMode.set(0);
|
||||
auto &hwInfo = *pDevice->getRootDeviceEnvironment().getMutableHardwareInfo();
|
||||
auto &productHelper = pDevice->getRootDeviceEnvironment().getHelper<ProductHelper>();
|
||||
const std::string platformName = hardwarePrefix[hwInfo.platform.eProductFamily];
|
||||
const std::string platformName = getFamilyNameWithType(hwInfo);
|
||||
const std::string revId = std::to_string(hwInfo.platform.usRevId);
|
||||
const std::string defaultRevId = std::to_string(productHelper.getDefaultRevisionId());
|
||||
|
||||
@@ -44,7 +44,7 @@ HWTEST2_F(BuiltInSharedTest, givenUseBindlessBuiltinEnabledWhenBinExtensionPasse
|
||||
DebugManager.flags.UseBindlessMode.set(1);
|
||||
auto &hwInfo = *pDevice->getRootDeviceEnvironment().getMutableHardwareInfo();
|
||||
auto &productHelper = pDevice->getRootDeviceEnvironment().getHelper<ProductHelper>();
|
||||
const std::string platformName = hardwarePrefix[hwInfo.platform.eProductFamily];
|
||||
const std::string platformName = getFamilyNameWithType(hwInfo);
|
||||
const std::string revId = std::to_string(hwInfo.platform.usRevId);
|
||||
const std::string defaultRevId = std::to_string(productHelper.getDefaultRevisionId());
|
||||
|
||||
@@ -88,7 +88,7 @@ HWTEST2_F(BuiltInSharedTest, GivenBuiltinTypeBinaryWhenGettingBuiltinResourceFor
|
||||
HWTEST2_F(BuiltInSharedTest, GivenStatelessBuiltinWhenGettingResourceNameThenAddressingIsStateless, HasStatefulSupport) {
|
||||
auto &hwInfo = *pDevice->getRootDeviceEnvironment().getMutableHardwareInfo();
|
||||
auto &productHelper = pDevice->getRootDeviceEnvironment().getHelper<ProductHelper>();
|
||||
const std::string platformName = hardwarePrefix[hwInfo.platform.eProductFamily];
|
||||
const std::string platformName = getFamilyNameWithType(hwInfo);
|
||||
const std::string revId = std::to_string(hwInfo.platform.usRevId);
|
||||
const std::string defaultRevId = std::to_string(productHelper.getDefaultRevisionId());
|
||||
|
||||
@@ -105,7 +105,7 @@ HWTEST2_F(BuiltInSharedTest, GivenStatelessBuiltinWhenGettingResourceNameThenAdd
|
||||
|
||||
HWTEST2_F(BuiltInSharedTest, GivenPlatformWithoutStatefulAddresingSupportWhenGettingResourceNamesThenStatelessResourceNameIsReturned, HasNoStatefulSupport) {
|
||||
auto &hwInfo = *pDevice->getRootDeviceEnvironment().getMutableHardwareInfo();
|
||||
const std::string platformName = hardwarePrefix[hwInfo.platform.eProductFamily];
|
||||
const std::string platformName = getFamilyNameWithType(hwInfo);
|
||||
const std::string revId = std::to_string(hwInfo.platform.usRevId);
|
||||
|
||||
{
|
||||
@@ -126,7 +126,7 @@ HWTEST_F(BuiltInSharedTest, GivenRequestedTypeIntermediateWhenGettingResourceNam
|
||||
DebugManager.flags.UseBindlessMode.set(0);
|
||||
auto &hwInfo = *pDevice->getRootDeviceEnvironment().getMutableHardwareInfo();
|
||||
auto &productHelper = pDevice->getRootDeviceEnvironment().getHelper<ProductHelper>();
|
||||
const std::string platformName = hardwarePrefix[hwInfo.platform.eProductFamily];
|
||||
const std::string platformName = getFamilyNameWithType(hwInfo);
|
||||
const std::string revId = std::to_string(hwInfo.platform.usRevId);
|
||||
const std::string defaultRevId = std::to_string(productHelper.getDefaultRevisionId());
|
||||
|
||||
@@ -152,7 +152,7 @@ HWTEST_F(BuiltInSharedTest, GivenValidBuiltinTypeAndAnyTypeWhenGettingBuiltinCod
|
||||
|
||||
auto &hwInfo = *pDevice->getRootDeviceEnvironment().getMutableHardwareInfo();
|
||||
auto &productHelper = pDevice->getRootDeviceEnvironment().getHelper<ProductHelper>();
|
||||
const std::string platformName = hardwarePrefix[hwInfo.platform.eProductFamily];
|
||||
const std::string platformName = getFamilyNameWithType(hwInfo);
|
||||
const std::string revId = std::to_string(hwInfo.platform.usRevId);
|
||||
const std::string defaultRevId = std::to_string(productHelper.getDefaultRevisionId());
|
||||
|
||||
|
||||
@@ -296,7 +296,8 @@ int main(int argc, char **argv) {
|
||||
gtSystemInfo.MaxSubSlicesSupported = std::max(gtSystemInfo.MaxSubSlicesSupported, gtSystemInfo.SubSliceCount);
|
||||
// clang-format on
|
||||
|
||||
binaryNameSuffix.append(hardwarePrefix[hwInfoForTests.platform.eProductFamily]);
|
||||
binaryNameSuffix.append(familyName[hwInfoForTests.platform.eRenderCoreFamily]);
|
||||
binaryNameSuffix.append(hwInfoForTests.capabilityTable.platformType);
|
||||
|
||||
std::string testBinaryFiles = getRunPath(argv[0]);
|
||||
testBinaryFiles.append("/");
|
||||
|
||||
Reference in New Issue
Block a user