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>
这个提交包含在:
David Galiffi
2024-10-15 11:20:40 -04:00
提交者 GitHub
父节点 dc63370a1f
当前提交 d07bf508a9
修改 420 个文件,包含 10418 行新增9914 行删除
+51 -50
查看文件
@@ -1,12 +1,12 @@
# ########################################################################################
#
# omnitrace (Python)
# rocprofsys (Python)
#
# ########################################################################################
if(OMNITRACE_BUILD_STATIC_LIBSTDCXX)
# omnitrace_message(FATAL_ERROR "static libstdc++ is not compatible with python
# bindings")
if(ROCPROFSYS_BUILD_STATIC_LIBSTDCXX)
# rocprofiler_systems_message(FATAL_ERROR "static libstdc++ is not compatible with
# python bindings")
endif()
# if set, will screw up loading library
@@ -17,27 +17,27 @@ set(CMAKE_INSTALL_DEFAULT_COMPONENT_NAME python)
# ########################################################################################
function(OMNITRACE_CONFIGURE_PYTARGET _TARGET _VERSION)
function(ROCPROFILER_SYSTEMS_CONFIGURE_PYTARGET _TARGET _VERSION)
add_library(omnitrace::${_TARGET} ALIAS ${_TARGET})
target_link_libraries(${_TARGET} PRIVATE libpyomnitrace-interface)
add_dependencies(libpyomnitrace ${_TARGET})
add_library(rocprofiler-systems::${_TARGET} ALIAS ${_TARGET})
target_link_libraries(${_TARGET} PRIVATE libpyrocprofiler-systems-interface)
add_dependencies(libpyrocprofsys ${_TARGET})
set_target_properties(
${_TARGET}
PROPERTIES PREFIX ""
OUTPUT_NAME libpyomnitrace
OUTPUT_NAME libpyrocprofsys
LIBRARY_OUTPUT_DIRECTORY
${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_PYTHONDIR}/omnitrace
${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_PYTHONDIR}/rocprofsys
ARCHIVE_OUTPUT_DIRECTORY
${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_PYTHONDIR}/omnitrace
${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_PYTHONDIR}/rocprofsys
RUNTIME_OUTPUT_DIRECTORY
${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_PYTHONDIR}/omnitrace
${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_PYTHONDIR}/rocprofsys
PDB_OUTPUT_DIRECTORY
${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_PYTHONDIR}/omnitrace
${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_PYTHONDIR}/rocprofsys
${EXTRA_PROPERTIES})
set(_PYLIB ${CMAKE_INSTALL_PYTHONDIR}/omnitrace)
set(_PYLIB ${CMAKE_INSTALL_PYTHONDIR}/rocprofsys)
if(NOT IS_ABSOLUTE "${_PYLIB}")
set(_PYLIB ${CMAKE_INSTALL_PREFIX}/${_PYLIB})
endif()
@@ -54,71 +54,72 @@ function(OMNITRACE_CONFIGURE_PYTARGET _TARGET _VERSION)
install(
TARGETS ${_TARGET}
DESTINATION ${CMAKE_INSTALL_PYTHONDIR}/omnitrace
DESTINATION ${CMAKE_INSTALL_PYTHONDIR}/rocprofsys
OPTIONAL)
endfunction()
# ########################################################################################
add_library(omnitrace-python-compile-options INTERFACE)
add_library(omnitrace::omnitrace-python-compile-options ALIAS
omnitrace-python-compile-options)
add_library(rocprofiler-systems-python-compile-options INTERFACE)
add_library(rocprofiler-systems::rocprofiler-systems-python-compile-options ALIAS
rocprofiler-systems-python-compile-options)
add_target_cxx_flag_if_avail(
omnitrace-python-compile-options "-Wno-unused-value" "-Wno-range-loop-analysis"
"-Wno-deprecated-declarations" "-Wno-unused-but-set-parameter"
"-ftls-model=global-dynamic")
rocprofiler-systems-python-compile-options "-Wno-unused-value"
"-Wno-range-loop-analysis" "-Wno-deprecated-declarations"
"-Wno-unused-but-set-parameter" "-ftls-model=global-dynamic")
file(GLOB pyheaders ${CMAKE_CURRENT_LIST_DIR}/libpyomnitrace*.hpp)
set(pysources ${CMAKE_CURRENT_LIST_DIR}/libpyomnitrace.cpp)
file(GLOB pyheaders ${CMAKE_CURRENT_LIST_DIR}/libpyrocprofsys*.hpp)
set(pysources ${CMAKE_CURRENT_LIST_DIR}/libpyrocprofsys.cpp)
set(pybind_libs pybind11::module)
add_library(libpyomnitrace-interface INTERFACE)
add_library(libpyrocprofiler-systems-interface INTERFACE)
target_link_libraries(
libpyomnitrace-interface
libpyrocprofiler-systems-interface
INTERFACE pybind11::module
timemory::timemory-headers
omnitrace::omnitrace-headers
omnitrace::omnitrace-compile-options
omnitrace::omnitrace-static-libgcc-optional
omnitrace::omnitrace-lto
omnitrace::omnitrace-dl-library
omnitrace::omnitrace-user-library
omnitrace::omnitrace-python
omnitrace::omnitrace-python-compile-options)
rocprofiler-systems::rocprofiler-systems-headers
rocprofiler-systems::rocprofiler-systems-compile-options
rocprofiler-systems::rocprofiler-systems-static-libgcc-optional
rocprofiler-systems::rocprofiler-systems-lto
rocprofiler-systems::rocprofiler-systems-dl-library
rocprofiler-systems::rocprofiler-systems-user-library
rocprofiler-systems::rocprofiler-systems-python
rocprofiler-systems::rocprofiler-systems-python-compile-options)
omnitrace_target_compile_definitions(libpyomnitrace-interface
INTERFACE OMNITRACE_PYBIND11_SOURCE)
rocprofiler_systems_target_compile_definitions(libpyrocprofiler-systems-interface
INTERFACE ROCPROFSYS_PYBIND11_SOURCE)
add_custom_target(libpyomnitrace)
add_custom_target(libpyrocprofsys)
file(GLOB_RECURSE PYTHON_FILES ${CMAKE_CURRENT_SOURCE_DIR}/omnitrace/*.py)
file(GLOB_RECURSE PYTHON_FILES ${CMAKE_CURRENT_SOURCE_DIR}/rocprofsys/*.py)
foreach(_IN ${PYTHON_FILES})
string(REPLACE "${CMAKE_CURRENT_SOURCE_DIR}/omnitrace"
"${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_PYTHONDIR}/omnitrace" _OUT
string(REPLACE "${CMAKE_CURRENT_SOURCE_DIR}/rocprofsys"
"${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_PYTHONDIR}/rocprofsys" _OUT
"${_IN}")
configure_file(${_IN} ${_OUT} @ONLY)
install(
FILES ${_OUT}
DESTINATION ${CMAKE_INSTALL_PYTHONDIR}/omnitrace
DESTINATION ${CMAKE_INSTALL_PYTHONDIR}/rocprofsys
OPTIONAL)
endforeach()
omnitrace_python_console_script("omnitrace-python" "omnitrace")
rocprofiler_systems_python_console_script("${BINARY_NAME_PREFIX}-python" "rocprofsys")
set(_INDEX 0)
foreach(_VERSION ${OMNITRACE_PYTHON_VERSIONS})
# add_library(libpyomnitrace MODULE ${pysources} ${pyheaders})
list(GET OMNITRACE_PYTHON_ROOT_DIRS ${_INDEX} Python3_ROOT_DIR)
omnitrace_pybind11_add_module(
libpyomnitrace-${_VERSION} MODULE
foreach(_VERSION ${ROCPROFSYS_PYTHON_VERSIONS})
# add_library(libpyrocprofsys MODULE ${pysources} ${pyheaders})
list(GET ROCPROFSYS_PYTHON_ROOT_DIRS ${_INDEX} Python3_ROOT_DIR)
rocprofiler_systems_pybind11_add_module(
libpyrocprofiler-systems-${_VERSION} MODULE
PYTHON_VERSION ${_VERSION}
VISIBILITY "hidden" ${pysources} ${pyheaders})
omnitrace_configure_pytarget(libpyomnitrace-${_VERSION} ${_VERSION})
rocprofiler_systems_configure_pytarget(libpyrocprofiler-systems-${_VERSION}
${_VERSION})
if(OMNITRACE_USE_PYTHON)
omnitrace_python_console_script(
"omnitrace-python" "omnitrace"
if(ROCPROFSYS_USE_PYTHON)
rocprofiler_systems_python_console_script(
"${BINARY_NAME_PREFIX}-python" "rocprofsys"
VERSION ${_VERSION}
ROOT_DIR "${Python3_ROOT_DIR}")
endif()