Using miniconda docker (#366)

* Using miniconda docker

* remove sudo

* Remove double install of rocprofiler-docs conda environment

* Fix building docs

* Fix build docs

- Additional system packages

* Using miniforge

* Fixing warning as errors build issue

* cmake formatting

---------

Co-authored-by: Jonathan R. Madsen <jonathanrmadsen@gmail.com>

[ROCm/rocprofiler-sdk commit: 024cf0e5e3]
This commit is contained in:
Bhardwaj, Gopesh
2025-04-24 10:22:03 +05:30
gecommit door GitHub
bovenliggende 71a46f97c6
commit 1646c6fdd0
4 gewijzigde bestanden met toevoegingen van 23 en 34 verwijderingen
+6 -18
Bestand weergeven
@@ -30,6 +30,7 @@ env:
jobs:
build-docs:
runs-on: ubuntu-latest
container: continuumio/miniconda3
permissions:
contents: read
pages: write
@@ -39,41 +40,28 @@ jobs:
uses: actions/checkout@v4
with:
submodules: true
- name: Install Conda
shell: bash -el {0}
run: |
curl -O https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
bash ./Miniconda3-latest-Linux-x86_64.sh -b
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Create Docs Directory
run:
mkdir -p docs/_doxygen/rocprofiler-sdk
mkdir -p docs/_doxygen/roctx
- name: Install Conda environment
shell: bash -el {0}
working-directory: source/docs
run: |
conda env create -n rocprofiler-docs -f environment.yml
- name: Install documentation dependencies
timeout-minutes: 10
shell: bash
run: |
sudo apt-get update
sudo apt-get install -y doxygen graphviz
sudo python3 -m pip install sphinx
sudo python3 -m pip install doxysphinx rocm-docs-core
apt-get update
apt-get install -y doxygen graphviz build-essential cmake
- name: Build Docs
shell: bash -el {0}
working-directory: source/docs
run: |
source /home/runner/.bashrc
export PATH=/home/runner/miniconda3/bin:$PATH
conda init
conda env create -n rocprofiler-docs -f environment.yml
source activate
conda activate rocprofiler-docs
sudo ../scripts/update-docs.sh
python3 -m pip install sphinx
python3 -m pip install doxysphinx rocm-docs-core
../scripts/update-docs.sh
- name: Upload artifact
if: ${{ github.event_name == 'workflow_dispatch' }}
uses: actions/upload-pages-artifact@v3
@@ -22,10 +22,11 @@ find_program(CHMOD_CMD NAMES chmod)
if(NOT EXISTS ${PROJECT_BINARY_DIR}/external/miniconda.sh)
message(
STATUS
"Downloading https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh"
"Downloading https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-Linux-x86_64.sh"
)
file(
DOWNLOAD https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh
DOWNLOAD
https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-Linux-x86_64.sh
${PROJECT_BINARY_DIR}/external/miniconda.sh
STATUS MINICONDA_DOWNLOAD_RET
INACTIVITY_TIMEOUT 60
@@ -34,7 +35,7 @@ if(NOT EXISTS ${PROJECT_BINARY_DIR}/external/miniconda.sh)
if(NOT MINICONDA_DOWNLOAD_RET EQUAL 0)
message(
FATAL_ERROR
"Download to ${PROJECT_BINARY_DIR}/external/miniconda.sh from https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh failed"
"Download to ${PROJECT_BINARY_DIR}/external/miniconda.sh from https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-Linux-x86_64.sh failed"
)
endif()
endif()
@@ -89,7 +90,7 @@ export PATH
source ${CONDA_ROOT}/bin/activate
conda config --set always_yes yes
conda update -c defaults -n base conda
conda update -n base conda
if [ ! -d '${CONDA_ROOT}/envs/rocprofiler-docs' ]; then
${CONDA_ROOT}/bin/conda env create -n rocprofiler-docs -f ${CMAKE_CURRENT_LIST_DIR}/environment.yml
@@ -1,7 +1,7 @@
name: rocprofiler-docs
channels:
- conda-forge
- defaults
dependencies:
- _libgcc_mutex=0.1=conda_forge
- _openmp_mutex=4.5=2_gnu
@@ -18,7 +18,6 @@ dependencies:
- cmake=3.27.4=hcfe8598_4
- colorama=0.4.6=pyhd8ed1ab_0
- commonmark=0.9.1=py_0
- docutils=0.18.1=py311h06a4308_3
- doxygen=1.9.8=h661eb56_0
- expat=2.5.0=hcb278e6_1
- font-ttf-dejavu-sans-mono=2.37=hab24e00_0
@@ -85,7 +85,7 @@ The following table lists the commonly used ``rocprofv3`` command-line options c
| ``--hsa-trace`` [BOOL] |br| |br| |br| |br| |br| |br| |br| |br|
| ``--rccl-trace`` [BOOL] |br| |br| |br| |br|
| ``--kokkos-trace`` [BOOL] |br| |br| |br| |br|
| ``--rocdecode-trace`` [BOOL] |br| |br| |br| |br|
| ``--rocdecode-trace`` [BOOL]
- | Combination of ``--hip-runtime-trace`` and ``--hip-compiler-trace``. This option only enables the HIP API tracing. Unlike previous iterations of ``rocprof``, this option doesn't enable kernel tracing, memory copy tracing, and so on. |br| |br|
| Collects marker (ROCTx) traces. Similar to ``--roctx-trace`` option in earlier ``rocprof`` versions, but with improved ``ROCTx`` library with more features. |br| |br|
| Collects kernel dispatch traces. |br| |br|
@@ -95,7 +95,7 @@ The following table lists the commonly used ``rocprofv3`` command-line options c
| Collects ``--hsa-core-trace``, ``--hsa-amd-trace``, ``--hsa-image-trace``, and ``--hsa-finalizer-trace``. This option only enables the HSA API tracing. Unlike previous iterations of ``rocprof``, this doesn't enable kernel tracing, memory copy tracing, and so on. |br| |br|
| Collects traces for RCCL (ROCm Communication Collectives Library), which is also pronounced as 'Rickle'. |br| |br|
| Enables builtin Kokkos tools support, which implies enabling ``--marker-trace`` collection and ``--kernel-rename``. |br| |br|
| Collects traces for rocDecode APIs. |br| |br|
| Collects traces for rocDecode APIs.
* - Granular tracing
- | ``--hip-runtime-trace`` [BOOL] |br| |br| |br| |br|
@@ -162,16 +162,16 @@ The following table lists the commonly used ``rocprofv3`` command-line options c
| Specifies Perfetto shared memory size hint in KB. Default: 64 KB.
* - Display
- ``-L`` [BOOL] \| ``--list-avail`` [BOOL]
- Lists the PC sampling configurations and metrics available in the counter_defs.yaml file for counter collection. In earlier ``rocprof`` versions, this was known as ``--list-basic``, ``--list-derived``, and ``--list-counters``.
- | ``-L`` [BOOL] \| ``--list-avail`` [BOOL] |br|
- | Lists the PC sampling configurations and metrics available in the counter_defs.yaml file for counter collection. In earlier ``rocprof`` versions, this was known as ``--list-basic``, ``--list-derived``, and ``--list-counters``.
* - Other
- ``--preload`` [PRELOAD ...]
- Specifies libraries to prepend to ``LD_PRELOAD``. It is useful for sanitizer libraries.
- ``--minimum-output-data``
- Output files are generated only if output data size is greater than minimum output data size. It can be used for controlling the generation of output files so that user don't recieve empty files. The input is in KB units.
- ``--disable-signal-handlers``
- Disables the signal handlers in the rocprofv3 tool. It disables the prioritizing of rocprofv3 signal handler over application installed signal handler. When --disable-signal-handlers is set to true, and application has its signal handler on SIGSEGV or similar installed, then its signal handler will be used not the rocprofv3 signal handler. Note: glog still installs signal handlers which provide backtraces.
- | ``--preload`` PRELOAD |br| |br|
| ``--minimum-output-data`` |br| |br|
| ``--disable-signal-handlers``
- | Specifies libraries to prepend to ``LD_PRELOAD``. It is useful for sanitizer libraries. |br| |br|
| Output files are generated only if output data size is greater than minimum output data size. It can be used for controlling the generation of output files so that user don't recieve empty files. The input is in KB units. |br| |br|
| Disables the signal handlers in the rocprofv3 tool. It disables the prioritizing of rocprofv3 signal handler over application installed signal handler. When --disable-signal-handlers is set to true, and application has its signal handler on SIGSEGV or similar installed, then its signal handler will be used not the rocprofv3 signal handler. Note: glog still installs signal handlers which provide backtraces.
To see exhaustive list of ``rocprofv3`` options:
@@ -1019,6 +1019,7 @@ The generated Perfetto trace file can be opened in the `Perfetto UI <https://ui.
You can also combine this with the system trace option to get a more comprehensive view of the system's performance. For example, you can use the following command to collect both system trace and performance counter data:
.. code-block:: bash
rocprofv3 --pmc SQ_WAVES GRBM_COUNT --sys-trace --output-format pftrace -- <application_path>
.. image:: /data/perfetto_counters.png