Repository navigation
Disable inline symbol visibility - #22
Closed
systems-assistant[bot] wants to merge 8 commits into
Closed
systems-assistant[bot] wants to merge 8 commits into
systems-assistant[bot] wants to merge 8 commits into
Conversation
…evelop/ROCm_rocprofiler-register/jomadsen_change-inline-visibility
ammallya
pushed a commit
that referenced
this pull request
Aug 7, 2025
* Ability to select alternative compiler per file
Implementation of ompt interface to rocprofiler SDK. task_create and task_schedule are not supported.
Misc updates
Update OpenMP target sample
- samples/ompt -> samples/openmp_target
- fix sample test of openmp-target
- reorganize files
Rework OpenMP implementation
Minor OpenMP implementation cleanup
Rename samples/openmp_target CMake targets
Add tests/bin/openmp
- OpenMP target test app in tests/bin/openmp/target
Format samples/openmp_target CMakeLists.txt
Misc lib/rocprofiler-sdk/openmp cleanup
- fix includes
- convert_arg
Update openmp.def.cpp
- tweak includes
- remove lots of temporary variables
Update samples
- common::get_callback_id_names() -> common::get_callback_tracing_names()
- add kernel dispatch, memory copy, scratch memory buffered tracing to openmp target sample
Fix code object operation names
- add "CODE_OBJECT_" prefix
Update include/rocprofiler-sdk/openmp/api_id.h
- remove spurious comment
Miscellaneous openmp updates
- similar API for openmp_begin and openmp_end
- move implementations of ompt callbacks to openmp.cpp
- ompt_{thread_begin,thread_end,parallel_begin,parallel_end}_callbacks are openmp_events
[SWDEV-484495] Fix int truncation in CSV output (#1098)
CSV output truncates doubles to ints when it shouldn't. Derived metrics
are (mostly) doubles and lose precision (or become worthless) if treated
as an int. Converted these to double to match the format we return from
rocprof-sdk.
Co-authored-by: Benjamin Welton <ben@amd.com>
Update limit for max counter records in rocprof-tool (#1073)
A fixed sized std::array is used to store counter records in rocprofiler SDK. This limit was breached in SWDEV-484742. Upping the limit to 512 to be less likely to reach this limit again.
adding proxy ompt_data_t * arguments
fixes for proxy pointers
- Implement proxy ompt_data_t* pointers for clients
- Add ompt_data_t* arguments back to callback API
- Modify openmp sample to illustrate use of proxy pointers
formatting
SWDEV-467350: Skipping tool counter iteration for unsupported hardware (#1083)
Fixing some accumulate metrics (#1089)
* Fixing some accumulate metrics
* Fixing some more accumulate metrics
---------
Co-authored-by: Benjamin Welton <bewelton@amd.com>
updating rocprofv3 help options (#1113)
* updating rocprofv3 help options
* updating CHANGELOG
Fixing installed pacakge tests in CI (#1119)
* Fixing installed pacakge tests in CI
* Formatted rocprofv3.py with black formatter
SWDEV-488948: PC Sampling - Correlation class to provide some thread safety. Adding multithread tests. (#1112)
* SWDEV-488948: PC Sampling - Correlation class to provide some thread safety. Adding multithread tests.
* Update source/lib/rocprofiler-sdk/pc_sampling/parser/correlation.hpp
Co-authored-by: Vladimir Indic <139573562+vlaindic@users.noreply.github.com>
* Update source/lib/rocprofiler-sdk/pc_sampling/parser/correlation.hpp
Co-authored-by: Vladimir Indic <139573562+vlaindic@users.noreply.github.com>
* Adding backlog for codeobj changes
* Formatting
* Update source/lib/rocprofiler-sdk/pc_sampling/code_object.hpp
Co-authored-by: Vladimir Indic <139573562+vlaindic@users.noreply.github.com>
* Update source/lib/rocprofiler-sdk/pc_sampling/code_object.hpp
Co-authored-by: Vladimir Indic <139573562+vlaindic@users.noreply.github.com>
---------
Co-authored-by: Vladimir Indic <139573562+vlaindic@users.noreply.github.com>
SWDEV-487621: Fixes for metric definitions (#1118)
* Fixes for metric definitions
* Removing gfx8
* Update changelog
* Fixing unit tests
* Small fixes
* Fix for write size
Fix PSDB change (#1120)
Reverts change to `source/include/rocprofiler-sdk/callback_tracing.h`
from commit c77e4d3
clang-18 build fix for RCCL (#1123)
Removes ambiguity on const usage, which clang-18 complains about
(preventing build with warn error).
mem copy direction field update (#1124)
Adding Node-id for debugging with log level trace (#1090)
fix botched rebase
Per Jonathan to remove -rdynamic warning so CI will continue
pedantic formatting
Correct the package name of rocprofiler-sdk (#1126)
* Correct the package name of rocprofiler-sdk
ROCM VERSION(for ex: 60300) was missing in the package name.
Added the same
* Use cmake cache string while setting the variable for ROCm Version
* correct the cmake-format
---------
Co-authored-by: Ranjith Ramakrishnan <Ranjith.Ramakrishnan@amd.com>
Fixing kokkosp tool library packaging (#1121)
* Fixing kokkosp tool library packaging
* Update source/lib/rocprofiler-sdk-tool/kokkosp/CMakeLists.txt
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* Update CMakeLists.txt
* Update CMakeLists.txt
* Component Requirement in CPack
* Adding package dependency
* Update CMakeLists.txt
* Update rocprofiler_config_packaging.cmake
* Fix rocprofiler-sdk-tool-kokkosp BUILD/INSTALL RPATH
- CMAKE_INSTALL_LIBDIR doesn't help
* Add BUILD/INSTALL RPATH to rocprofv3-trigger-list-metrics
- fixes packaging issues
* Update packaging
- core depends on rocprofiler-sdk-roctx
- add CPACK_DEBIAN_PACKAGE_SHLIBDEPS_PRIVATE_DIRS to resolve inter-package dependencies
* Fix package depends version format
* Improve tests/rocprofv3/summary/validate logging
* Update CI workflow
- prioritize roctx package in Install Packages step
* Remove setting <package-name>_VERSION in config.cmake.in
- this is automatically handled by existence of <package-name>-config-version.cmake
* Update rocprofiler-sdk-config.cmake
- relax find_package versioning requirements to same major and minor version
* Update rocprofiler-sdk-config.cmake
- relax find_package versioning requirements (remove EXACT, specify range)
* Tweak CI workflow
* Update perfetto_reader.py
- better handle failure to load trace processor
* Misc cleanup for config packaging
* Update config packaging
* Update config packaging
* Revert perfetto for core-rpm packages
* Revert perfetto for core-rpm packages
- perfetto < 0.9.0
* Tweak tests/rocprofv3/summary/validate.py
- reorder some checks
---------
Co-authored-by: Ammar Elwazir <aelwazir@useocpm2m-387-013.amd.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan R. Madsen <jonathanrmadsen@gmail.com>
Clang Warning Fixes (#1131)
Builds prevented on clang-18
Adding start and end timestamp columns in csv (#1128)
* Adding start and end timestamp columns in csv
* Adding assert check for the counter timestamps
---------
Co-authored-by: Gopesh Bhardwaj <gopesh.bhardwaj@amd.com>
rocprofv3: docs and help menu updates (#1129)
* doc updates
* Correcting ROCtx information
* Making ROCTx string consistent
* missing occurence
Renamed agent profiling service to device counting service (#1132)
* Renamed agent profiling service to device counting service
Name more aptly represents what agent profiling did (device wide
counter collection). Conversion of existing user code can be
performed by the following find/sed command:
find . -type f -exec sed -i 's/rocprofiler_agent_profile_callback_t/rocprofiler_device_counting_service_callback_t/g; s/rocprofiler_configure_agent_profile_counting_service/rocprofiler_configure_device_counting_service/g; s/agent_profile.h/device_counting_service.h/g; s/rocprofiler_sample_agent_profile_counting_service/rocprofiler_sample_device_counting_service/g' {} +
* Converted dispatch profile to dispatch counting service
* Debug for functioal counters test
* Minor changes for CI
* Minor fix
* More fixes for CI
* Update evaluate_ast.cpp
---------
Co-authored-by: Benjamin Welton <ben@amd.com>
Testing updated RPM dockers (#1136)
* Testing updated RPM dockers
* Trying to fix PSDB for test package dependency
Agent Profiling Fixes for Broken/Improper API Usage (#1122)
Prevent's multiple setups of agent profiling on the same agent.
Fixes agent read context to only read agents that were setup.
Prevent copy of agent profiling internal data struct and reset
hsa_signal on move to prevent inadvertant delete.
Simplifying PR template (#1139)
Implementation of ompt interface to rocprofiler SDK. task_create and task_schedule are not supported.
Fixing installed pacakge tests in CI (#1119)
* Fixing installed pacakge tests in CI
* Formatted rocprofv3.py with black formatter
Fix PSDB change (#1120)
Reverts change to `source/include/rocprofiler-sdk/callback_tracing.h`
from commit c77e4d3
delete unused files
added arguments to some OMPT buffter records
* Fix cmake issues
Remove rocprofiler_ompt_finalize_tool
- a public API function is not necessary: should just finalize rocprofiler-sdk
Fix duplicate ROCPROFILER_{BUFFER,CALLBACK}_TRACING_KIND_STRING
Add lib/rocprofiler-sdk/ompt.hpp
- declares rocprofiler::sdk::finalize_ompt
Remove change to tests/rocprofv3/summary/conftest.py
Add set_fini_status(1) back to registration.cpp
Deleted uneeded files
Incoporate OpenMP code and sample
Fix merge issues with amd-staging
Add push_correlation_id for OpenMP tasking; improve debugability
fixup bad merge
* Suppress OpenMP data race
* Fix openmp_target sample
* Enum and struct name changes + source code reorg
- remove mix of ompt and openmp
- opted for ompt
- changes made for consistency
- ompt_api -> ompt
- openmp_api -> ompt
- OPENMP -> OMPT
* Update tests and more renaming
- dest_device_num -> dst_device_num
- src_addr -> src_address
- dest_addr -> dst_address
- remove info_type::begin
- require OMP_TARGET_OFFLOAD
* Update openmp-target test/sample env and labels
* Formatting
* Tweaks to cmake for openmp target
- Disable for thread sanitizers due to preloading issue
* OpenMP target cmake updates
- remove gfx1010 (fails on mi300)
- OPENMP_GPU_TARGETS
* Remove device_unload and target_map_emi support
- these are never supported by AMD OpenMP compilers
* Update CI workflow
- exclude openmp-target tests from navi3 and vega20
---------
Co-authored-by: Larry Meadows <Lawrence.Meadows@amd.com>
Co-authored-by: Jonathan R. Madsen <jonathanrmadsen@gmail.com>
[ROCm/rocprofiler-sdk commit: 00c46fd]
jrmadsen
approved these changes
Aug 12, 2025
…mport/develop/ROCm_rocprofiler-register/jomadsen_change-inline-visibility
jayhawk-commits
pushed a commit
that referenced
this pull request
Aug 18, 2025
jayhawk-commits
pushed a commit
that referenced
this pull request
Aug 18, 2025
[ROCm/hipother commit: f638aa9]
ammallya
pushed a commit
that referenced
this pull request
Jan 21, 2026
add support for sync_all, barrier_all, broadcast, fcollect, and alltoall
ammallya
pushed a commit
that referenced
this pull request
Jan 21, 2026
ammallya
pushed a commit
that referenced
this pull request
Jan 21, 2026
add support for sync_all, barrier_all, broadcast, fcollect, and alltoall [ROCm/rocshmem commit: 7f6cc34]
ammallya
pushed a commit
that referenced
this pull request
Jan 21, 2026
[ROCm/rocshmem commit: 4a3c3d5]
ammallya
pushed a commit
that referenced
this pull request
Apr 9, 2026
## Motivation Allow tests to be parameterized on supported/unsupported.
ammallya
pushed a commit
that referenced
this pull request
Apr 9, 2026
## Motivation Allow tests to be parameterized on supported/unsupported. [ROCm/hipFile commit: 8c7743a]
7 of 9 tasks
ammarwa
added a commit
that referenced
this pull request
Apr 23, 2026
… polish + contributing docs (#5174) ## Summary Proven-optimizations catalog, nightly benchmark harness, contributing guides + RFC process + architecture refresh, `perfxpert doctor` polish, Phase 7.1 `ai_analysis/` module deletion, and the convergence-review fixes that establish real legacy-vs-agentic parity. This is the last PR in the original retirement series; subsequent PRs (#5179, #5180) add the bundled opencode fork and the docs-audit toolchain. Stacks on #5173. Next in stack: #5179. ## What lands ### Phase 7.1 — `perfxpert/ai_analysis/` module removed Commit `cb03e82c36` deletes the entire `ai_analysis/` module — **21 files, ~11.7 KLOC**. All execution now routes through `perfxpert/agents/`; the dispatcher and the `PERFXPERT_LEGACY` env toggle are gone. This completes the retirement started in #5173: there is no longer a "legacy path" to opt back into. ### Proven-optimizations catalog (10 canonical case studies) - `knowledge/proven_optimizations.yaml`: vgpr_reduction, lds_tiling, mfma_enablement, memory_coalescing, fast_math, hip_stream_overlap, kernel_fusion, device_sync_removal, warp_primitives, cache_blocking - Dual-schema fixture integration: synthetic `duration_ns` + real rocprofv3 UUID-suffixed `(end_ns - start_ns)` tables - `tests/fixtures/*.db`: 5 fixtures re-profiled with `--pmc` on real MI300X hardware ### Nightly benchmark harness + orchestration ### Contributing guides + RFC process + architecture refresh ### `perfxpert doctor` polish (8 checks incl. opencode bundled + LLM providers) ## Review findings addressed (29 findings, 5 fix batches) ### Batch 1 — Gate cascade fidelity (3 commits) - `gate-2-sol-signature`: `_run_sol_gate` took wrong keyword; unit tests mocked the function so the TypeError went undetected. Two-tier check now: hard cap on speedup ratio (>50× rejected arch-independent) + optional absolute FLOPS check via `sol.sanity_check`. 13 new un-mocked integration tests (`TestRunSolGateUnmocked`). - `gate-4-hot-kernel-key-unit`: `regression.compare_runs` returns `per_kernel_deltas` (list of dicts with `delta_pct` as a **fraction**, not percent), not `hot_kernels`. Old code iterated a non-existent key so Gate 4 silently treated all regressions as OK. Fraction↔percent conversion corrected. - `gate-5-skip-verdict`: verdict strings no longer misleading on skip (`candidate_binary=None` path). ### Batch 2 — Schemas, validators, framework invariants (6 findings) - #4: Pydantic cross-field validators on `GateVerdictModel` (status/failing_gate coupling), `CorrectnessOutput` (verdict/action), confidence clamps `Field(..., ge=0.0, le=1.0)`, typed `Literal` for provider - #12: `Agent` dataclass `frozen=True`; `__post_init__` validates layer in (0,1,2) - #7: `_parse_headers` raises `ValueError` on malformed JSON instead of silent `{}` - #10, #18: tasks module logs resolved store path; stale READ_ONLY docstrings rewritten - #17: README clarifies opencode is system dependency; doctor warns when PERFXPERT_TASK_ROOT unset ### Batch 3 — External tool verifier + fence alignment (6 findings) - N28: anthropic/openai SDK imports routed through `require_tool()` with install-hint on missing - N29: all 8 agent fence slices aligned to actual agent tool allowlists - #5, #6, #9, #17: smoke-test opencode binary (not just presence), hard-fail on bad `PERFXPERT_OPENCODE_PATH` override, skip subdirs in config copy - `tooldep`: user-home path search + `PERFXPERT_ROCPROF_TRACE_DECODER_PATH` env support ### Batch 4 — Classifier + data-provenance fidelity (2 findings) - **#1**: classifier no longer swallows DB errors silently (was returning empty metrics → `data_insufficient`; now logs + propagates error markers) - **#26 (priority user-flagged)**: confidence now weighted by `evidence_strength × match_ratio` instead of raw rule-count normalization — partial-PMC classifications no longer over-confident. New `test_partial_pmc_confidence` covers trace-only vs full-PMC paths. ### Batch 5 — Tests coverage gaps (9 findings) - #20: gate cascade short-circuit coverage (Gates 2/3/4) - #21: `_TraceAnalysisAdapter` shim delegation tests - #22: trace-only `memcpy_pct` path in `classify_from_metrics` - #23: `anthropic.APITimeoutError` normalization path - #24: Root agent lambda stub guard (`test_root.py::test_lambda_stubs_never_invoked`) - #25: MCP tool coverage across 5 representative tools - #27: flaky `time.sleep` → `proc.wait(timeout=5)` - #14, #15, #16: stale comments + docstring rewrites (api.py, __main__.py, recommendation.py) ## Parity story **Problem found during review**: parity test wiring was toggling a dead flag (`PERFXPERT_USE_AGENTS`) after the retirement PR flipped the default — both legs were running the agentic path. "Parity" passed vacuously. **Fixes applied (Decision A+C):** - **A**: Parity runner now toggles the operative legacy opt-out so legacy and agentic paths are genuinely distinct; Tier-1 trace-only fixtures `xfail`ed until re-profiled with `--pmc`. - **C**: Re-profiled all 5 fixtures (`baseline`, `memory_bound`, `compute_bound`, `latency_bound`, `regressed`) on real MI300X with `rocprofv3 --pmc`: - `compute_bound`: VALU-bound kernel (not MFMA, to legitimately match Compute-Bound classification) - `memory_bound` / `baseline`: 128 MB H2D+D2H loop - `latency_bound` / `regressed`: 6,000 tiny kernels - `_build_analysis_result` returns `api_overhead` (not `latency`) for `overhead_pct > 25%` (legacy heuristic fix) - E2E + dashboard tests updated for evidence-weighted classification **Result**: `parity_snapshots/_aggregate.json` → **100% agreement on PMC fixtures** (10/10 bottleneck + rec_technique signals). `rec_type` signal skipped where the agentic path can't populate without an LLM (documented asymmetric None). ## Convergence review round (2026-04-18) - **Brand scrub**: zero-tolerance removal of the prior codename across code, tests, patches, env-var names, and documentation. - **CLI flag plumbing**: all 10 CLI flags (`--prompt`, `--llm`, `--llm-model`, `--att-dir`, `--pc-sampling`, `--source-dir`, `--format`, `-d/-o`) now wired end-to-end via an `analysis_options` side-channel on `Context`. - **PMC shard UNION** across multiple `.db` files uses column-intersection and emits a `RuntimeWarning` listing dropped columns. - **FallbackProvider** has a typed exception taxonomy (`LLMRateLimitError`, `LLMAuthenticationError`, `LLMTransientError`, `LLMFatalError`). Auth/fatal errors surface immediately; only transient + rate-limit cascade. The provider is wired into `build_session`; `PERFXPERT_LLM_FALLBACK_CHAIN` now has runtime effect. ## Test plan - [x] 1036 pass / 3 skip / 0 fail from `experimental/python/perfxpert/` - [x] Core suites — 100% pass: `tests/test_agents + test_providers + test_runtime + test_tools` - [x] Parity ship-gate — 100%: `tests/test_parity/` (12 passed, 5 rec_type skips documented) - [x] Gate cascade — 100%: 28 tests including 13 new un-mocked SOL integration tests (Batch 1 recovery) - [x] E2E brain: `perfxpert-code run -m openai/gpt-4o-mini "..."` → MCP → Python → `81.7 TFLOPS` + AMD footer - [x] `perfxpert doctor`: all 8 checks green (34 MCP tools at this PR boundary; 43 after #5179+#5180; opencode 1.4.11 bundled; 3/5 LLM providers configured) - [x] No legacy opt-out path remains (Phase 7.1 removed the dispatcher and the `PERFXPERT_LEGACY` toggle) - [ ] Live MI300X nightly run (requires hardware; nightly workflow will refresh baseline) - [ ] Full interactive TUI (requires TTY; E2E can only prove banner-emitted) --------- Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
mradosav-amd
added a commit
that referenced
this pull request
Apr 30, 2026
…h in extdata
Add tsv_processor_t to core/trace_cache: consumes backtrace_region_sample records
from the trace_cache and emits the same four-file L4 TSV set as native_report_writer
(sampling_wall_clock.tsv, sampling_cpu_clock.tsv, sampling_percent.tsv, trip_count.tsv).
Locked extdata schema: { "depth": <int>, ...future fields... }. Records without
a "depth" key in extdata are silently skipped. Producer (real_trace_cache_sink)
now embeds depth (0-based frame index) in extdata for both store_timer and
store_overflow. Category "timer_sampling" aggregates into wall_clock + trip_count;
overflow_sampling path is a no-op stub pending Task #22.
tsv_processor.hpp avoids sample_processor.hpp (which requires AMD-SMI headers) so
trace-cache-tests can compile it without a ROCm install. Production wiring via
processor_view_t will be added in tsv_processor_adapter.hpp (Task #22/cache_manager).
15 new tsv_processor tests added; 871/871 total unit tests PASS.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Contributor
|
This pull request has been inactive for 25 days and will be marked as stale. If you would like to keep this PR open, please:
This PR will be automatically closed in 5 days if no further activity occurs. |
Contributor
|
This pull request has been automatically closed due to inactivity (30 days with no updates). If you'd like to continue working on this, feel free to reopen the PR or create a new one. |
1 task done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🔁 Imported from ROCm/rocprofiler-register#8
🧑💻 Originally authored by @rocm-devops