rocprofiler-sdk/ompt/api_id.h Source File

rocprofiler-sdk/ompt/api_id.h Source File#

ROCprofiler-SDK developer API: rocprofiler-sdk/ompt/api_id.h Source File
ROCprofiler-SDK developer API 1.0.0
ROCm Profiling API and tools
api_id.h
1// MIT License
2//
3// Copyright (c) 2023-2025 Advanced Micro Devices, Inc. All rights reserved.
4//
5// Permission is hereby granted, free of charge, to any person obtaining a copy
6// of this software and associated documentation files (the "Software"), to deal
7// in the Software without restriction, including without limitation the rights
8// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9// copies of the Software, and to permit persons to whom the Software is
10// furnished to do so, subject to the following conditions:
11//
12// The above copyright notice and this permission notice shall be included in
13// all copies or substantial portions of the Software.
14//
15// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21// THE SOFTWARE.
22
23#pragma once
24
25/**
26 * @brief ROCProfiler enumeration of OMPT (OpenMP tools) tracing operations
27 * NOTE: These are callbacks into the ROCProfiler SDK from the vendor-provided OMPT implementation
28 */
29typedef enum rocprofiler_ompt_operation_t // NOLINT(performance-enum-size)
30{
31 ROCPROFILER_OMPT_ID_NONE = -1,
32 ROCPROFILER_OMPT_ID_thread_begin = 0,
33 ROCPROFILER_OMPT_ID_thread_end,
34 ROCPROFILER_OMPT_ID_parallel_begin,
35 ROCPROFILER_OMPT_ID_parallel_end,
36 ROCPROFILER_OMPT_ID_task_create,
37 ROCPROFILER_OMPT_ID_task_schedule,
38 ROCPROFILER_OMPT_ID_implicit_task,
39 ROCPROFILER_OMPT_ID_device_initialize,
40 ROCPROFILER_OMPT_ID_device_finalize,
41 ROCPROFILER_OMPT_ID_device_load,
42 // ROCPROFILER_OMPT_ID_device_unload,
43 ROCPROFILER_OMPT_ID_sync_region_wait,
44 ROCPROFILER_OMPT_ID_mutex_released,
45 ROCPROFILER_OMPT_ID_dependences,
46 ROCPROFILER_OMPT_ID_task_dependence,
47 ROCPROFILER_OMPT_ID_work,
48 ROCPROFILER_OMPT_ID_masked,
49 ROCPROFILER_OMPT_ID_sync_region,
50 ROCPROFILER_OMPT_ID_lock_init,
51 ROCPROFILER_OMPT_ID_lock_destroy,
52 ROCPROFILER_OMPT_ID_mutex_acquire,
53 ROCPROFILER_OMPT_ID_mutex_acquired,
54 ROCPROFILER_OMPT_ID_nest_lock,
55 ROCPROFILER_OMPT_ID_flush,
56 ROCPROFILER_OMPT_ID_cancel,
57 ROCPROFILER_OMPT_ID_reduction,
58 ROCPROFILER_OMPT_ID_dispatch,
59 ROCPROFILER_OMPT_ID_target_emi,
60 ROCPROFILER_OMPT_ID_target_data_op_emi,
61 ROCPROFILER_OMPT_ID_target_submit_emi,
62 // ROCPROFILER_OMPT_ID_target_map_emi,
63 ROCPROFILER_OMPT_ID_error,
64 ROCPROFILER_OMPT_ID_callback_functions, // fake to return struct of ompt callback function
65 // pointers
66 ROCPROFILER_OMPT_ID_LAST
67} rocprofiler_ompt_operation_t;