Rename Omnitrace to ROCm Systems Profiler (#4)
The Omnitrace program is being renamed.
Full name: "ROCm Systems Profiler"
Package name: "rocprofiler-systems"
Binary / Library names: "rocprof-sys-*"
---------
Co-authored-by: Xuan Chen <xuchen@amd.com>
Signed-off-by: David Galiffi <David.Galiffi@amd.com>
[ROCm/rocprofiler-systems commit: d07bf508a9]
This commit is contained in:
zatwierdzone przez
GitHub
rodzic
c444ba6131
commit
489eda995d
@@ -54,20 +54,21 @@ foreach(_VAR FIND_STRATEGY FIND_VIRTUALENV FIND_FRAMEWORK FIND_IMPLEMENTATIONS
|
||||
if(DEFINED Python3_${_VAR})
|
||||
set(Python_${_VAR}
|
||||
"${Python3_${_VAR}}"
|
||||
CACHE STRING "Set via Python3_${_VAR} setting (omnitrace)")
|
||||
CACHE STRING "Set via Python3_${_VAR} setting (rocprofsys)")
|
||||
mark_as_advanced(Python_${_VAR})
|
||||
mark_as_advanced(Python3_${_VAR})
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
# display version
|
||||
omnitrace_add_feature(OMNITRACE_PYTHON_VERSIONS "Python version for omnitrace" DOC)
|
||||
rocprofiler_systems_add_feature(ROCPROFSYS_PYTHON_VERSIONS
|
||||
"Python version for rocprofsys" DOC)
|
||||
|
||||
option(PYBIND11_INSTALL "Enable Pybind11 installation" OFF)
|
||||
|
||||
if(OMNITRACE_BUILD_PYTHON AND NOT TARGET pybind11)
|
||||
if(ROCPROFSYS_BUILD_PYTHON AND NOT TARGET pybind11)
|
||||
# checkout PyBind11 if not checked out
|
||||
omnitrace_checkout_git_submodule(
|
||||
rocprofiler_systems_checkout_git_submodule(
|
||||
RECURSIVE
|
||||
RELATIVE_PATH external/pybind11
|
||||
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
|
||||
@@ -78,15 +79,16 @@ if(OMNITRACE_BUILD_PYTHON AND NOT TARGET pybind11)
|
||||
set(CMAKE_INTERPROCEDURAL_OPTIMIZATION OFF)
|
||||
endif()
|
||||
set(PYBIND11_NOPYTHON ON)
|
||||
omnitrace_save_variables(IPO VARIABLES CMAKE_INTERPROCEDURAL_OPTIMIZATION)
|
||||
rocprofiler_systems_save_variables(IPO VARIABLES CMAKE_INTERPROCEDURAL_OPTIMIZATION)
|
||||
add_subdirectory(${PROJECT_SOURCE_DIR}/external/pybind11)
|
||||
omnitrace_restore_variables(IPO VARIABLES CMAKE_INTERPROCEDURAL_OPTIMIZATION)
|
||||
rocprofiler_systems_restore_variables(IPO
|
||||
VARIABLES CMAKE_INTERPROCEDURAL_OPTIMIZATION)
|
||||
endif()
|
||||
|
||||
execute_process(
|
||||
COMMAND ${PYTHON_EXECUTABLE} -c
|
||||
"import time ; print('{} {}'.format(time.ctime(), time.tzname[0]))"
|
||||
OUTPUT_VARIABLE OMNITRACE_INSTALL_DATE
|
||||
OUTPUT_VARIABLE ROCPROFSYS_INSTALL_DATE
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_QUIET)
|
||||
|
||||
string(REPLACE " " " " OMNITRACE_INSTALL_DATE "${OMNITRACE_INSTALL_DATE}")
|
||||
string(REPLACE " " " " ROCPROFSYS_INSTALL_DATE "${ROCPROFSYS_INSTALL_DATE}")
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
function(OMNITRACE_FIND_PYTHON _VAR)
|
||||
function(ROCPROFILER_SYSTEMS_FIND_PYTHON _VAR)
|
||||
set(options REQUIRED QUIET)
|
||||
set(args VERSION ROOT_DIR)
|
||||
set(kwargs COMPONENTS)
|
||||
@@ -68,13 +68,13 @@ function(OMNITRACE_FIND_PYTHON _VAR)
|
||||
"${_PYTHON_VERSION_LIST}"
|
||||
PARENT_SCOPE)
|
||||
else()
|
||||
omnitrace_message(WARNING "${_PYTHON_ERROR_VALUE}")
|
||||
rocprofiler_systems_message(WARNING "${_PYTHON_ERROR_VALUE}")
|
||||
endif()
|
||||
endif()
|
||||
endfunction()
|
||||
#
|
||||
# Internal: find the appropriate link time optimization flags for this compiler
|
||||
function(_OMNITRACE_PYBIND11_ADD_LTO_FLAGS target_name prefer_thin_lto)
|
||||
function(_ROCPROFSYS_PYBIND11_ADD_LTO_FLAGS target_name prefer_thin_lto)
|
||||
# Checks whether the given CXX/linker flags can compile and link a cxx file. cxxflags
|
||||
# and linkerflags are lists of flags to use. The result variable is a unique variable
|
||||
# name for each set of flags: the compilation result will be cached base on the result
|
||||
@@ -141,9 +141,9 @@ function(_OMNITRACE_PYBIND11_ADD_LTO_FLAGS target_name prefer_thin_lto)
|
||||
endif()
|
||||
|
||||
if(PYBIND11_LTO_CXX_FLAGS)
|
||||
omnitrace_message(STATUS "${target_name} :: LTO enabled")
|
||||
rocprofiler_systems_message(STATUS "${target_name} :: LTO enabled")
|
||||
else()
|
||||
omnitrace_message(
|
||||
rocprofiler_systems_message(
|
||||
STATUS
|
||||
"${target_name} :: LTO disabled (not supported by the compiler and/or linker)"
|
||||
)
|
||||
@@ -162,14 +162,14 @@ function(_OMNITRACE_PYBIND11_ADD_LTO_FLAGS target_name prefer_thin_lto)
|
||||
endif()
|
||||
endfunction()
|
||||
#
|
||||
function(OMNITRACE_PYBIND11_ADD_MODULE target_name)
|
||||
function(ROCPROFILER_SYSTEMS_PYBIND11_ADD_MODULE target_name)
|
||||
set(options MODULE SHARED EXCLUDE_FROM_ALL NO_EXTRAS SYSTEM THIN_LTO LTO)
|
||||
set(args PYTHON_VERSION VISIBILITY CXX_STANDARD)
|
||||
set(kwargs)
|
||||
cmake_parse_arguments(ARG "${options}" "${args}" "${kwargs}" ${ARGN})
|
||||
|
||||
if(ARG_MODULE AND ARG_SHARED)
|
||||
omnitrace_message(FATAL_ERROR "Can't be both MODULE and SHARED")
|
||||
rocprofiler_systems_message(FATAL_ERROR "Can't be both MODULE and SHARED")
|
||||
elseif(ARG_SHARED)
|
||||
set(lib_type SHARED)
|
||||
else()
|
||||
@@ -261,7 +261,7 @@ function(OMNITRACE_PYBIND11_ADD_MODULE target_name)
|
||||
endif()
|
||||
|
||||
if(ARG_LTO OR ARG_THIN_LTO)
|
||||
_omnitrace_pybind11_add_lto_flags(${target_name} ${ARG_THIN_LTO})
|
||||
_rocprofiler_systems_pybind11_add_lto_flags(${target_name} ${ARG_THIN_LTO})
|
||||
endif()
|
||||
|
||||
if(NOT MSVC AND NOT ${CMAKE_BUILD_TYPE} MATCHES Debug|RelWithDebInfo)
|
||||
|
||||
Reference in New Issue
Block a user