Skip to content
This repository was archived by the owner on Sep 30, 2026. It is now read-only.

Remove roctracer support - #1419

Closed
scotts wants to merge 1 commit into
pytorch:mainfrom
scotts:export-D107135523
Closed

scotts wants to merge 1 commit into
pytorch:mainfrom
scotts:export-D107135523

Conversation

@scotts

@scotts scotts commented Jun 2, 2026 •

Copy link
Copy Markdown
Contributor

Summary:

Motivation — D92225068 added rocprofiler-sdk support but kept roctracer as a fallback through the ROCTRACER_FALLBACK define. Three months on, nothing exercises it: PyTorch OSS is on ROCm 7.2 and we don't test it on GitHub. AMD has frozen roctracer; it is in maintenance mode and superseded by rocprofiler-sdk. The fallback is dead code.

Approach

  • Delete the roctracer-only sources (RoctracerActivityApi, RoctracerLogger, RoctracerActivity).
  • Delete the activity_profiler_roctracer library target, and roctracer_activity_profiler_test.
  • Collapse the ROCTRACER_FALLBACK #ifdef branches in the shared RocmActivityProfiler, ActivityProfilerController, and DeviceUtil down to the rocprofiler-sdk arm.
  • CMake now requires ROCm >= 7.0 (the rocprofiler-sdk floor) and always builds and links rocprofiler-sdk; the version-conditional roctracer selection and ROCTRACER_INCLUDE_DIR plumbing are removed.
  • HAS_ROCTRACER is now a misnomer, but we keep the name as-is; renaming it is a separate cleanup. (Changing the name may require coordinating with PyTorch upstream; I want to keep this change a clean removal in case we need to revert.)

Reviewed By: aaronenyeshi

Differential Revision: D107135523

@meta-codesync

meta-codesync Bot commented Jun 2, 2026

Copy link
Copy Markdown

@scotts has exported this pull request. If you are a Meta employee, you can view the originating Diff in D107135523.

@scotts

scotts commented Jun 2, 2026

Copy link
Copy Markdown
Contributor Author

@mwootton, can you also take a look?

@aaronenyeshi aaronenyeshi left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review automatically exported from Phabricator review in Meta.

@scotts
scotts force-pushed the export-D107135523 branch from 0a89a97 to 6d7594e Compare June 4, 2026 02:21
Summary:
Pull Request resolved: pytorch#1419

**Motivation** — D92225068 added rocprofiler-sdk support but kept roctracer as a fallback through the `ROCTRACER_FALLBACK` define. Three months on, nothing exercises it: [PyTorch OSS is on ROCm 7.2](https://pytorch.org/get-started/locally/?__hstc=76629258.724dacd2270c1ae797f3a62ecd655d50.1746547368336.1746547368336.1746547368336.1&__hssc=76629258.9.1746547368336&__hsfp=2230748894) and we don't test it on GitHub. AMD has frozen roctracer; it is in maintenance mode and superseded by rocprofiler-sdk. The fallback is dead code.

**Approach**
* Delete the roctracer-only sources (`RoctracerActivityApi`, `RoctracerLogger`, `RoctracerActivity`).
* Delete the `activity_profiler_roctracer` library target, and `roctracer_activity_profiler_test`.
* Collapse the `ROCTRACER_FALLBACK` `#ifdef` branches in the shared `RocmActivityProfiler`, `ActivityProfilerController`, and `DeviceUtil` down to the rocprofiler-sdk arm.
* CMake now requires ROCm >= 7.0 (the rocprofiler-sdk floor) and always builds and links rocprofiler-sdk; the version-conditional roctracer selection and `ROCTRACER_INCLUDE_DIR` plumbing are removed.
* `HAS_ROCTRACER` is now a misnomer, but we keep the name as-is; renaming it is a separate cleanup. (Changing the name may require coordinating with PyTorch upstream; I want to keep this change a clean removal in case we need to revert.)

Reviewed By: aaronenyeshi

Differential Revision: D107135523
@meta-codesync meta-codesync Bot changed the title Remove roctracer support Remove roctracer support (#1419) Jun 4, 2026
@scotts
scotts force-pushed the export-D107135523 branch from 6d7594e to e4dc14c Compare June 4, 2026 02:26
@scotts scotts changed the title Remove roctracer support (#1419) Remove roctracer support Jun 4, 2026
@meta-codesync meta-codesync Bot closed this in 2a3a002 Jun 4, 2026
@meta-codesync

meta-codesync Bot commented Jun 4, 2026

Copy link
Copy Markdown

This pull request has been merged in 2a3a002.

scotts added a commit to scotts/pytorch that referenced this pull request Jun 16, 2026
Includes the following commits:

- surface HSA queue ID (pytorch/kineto#1425) 1d43601
- Add TypedMetadata to CUPTI activities (pytorch/kineto#1434) 461a26c
- Move around methods so they are accurately described by the comments (pytorch/kineto#1435) ff95265
- Introduce TypedMetadata structs (pytorch/kineto#1433) 965a14d
- Add unit tests for sync/async interleaving behavior (pytorch/kineto#1431) 67612e6
- Restrict on-demand trace output path to a safe directory (pytorch/kineto#1426) 9ea826e
- Add a cancellation state to the state machine and remove syncTraceActive_ (pytorch/kineto#1355) 3289139
- Move state machine from profiler into async handler (pytorch/kineto#1352) eb578c5
- map kernel and copy events to logical stream ID instead of HSA queue ID (pytorch/kineto#1424) 25856f7
- Speedup and fix PyTorch CI build (pytorch/kineto#1428) e675bbb
- Add logging for async rejections (pytorch/kineto#1422) 14becfb
- Make sure we clear the logger observer before starting a new session (pytorch/kineto#1387) a8cae92
- Add a scope guard for logging to help us capture all exit paths (pytorch/kineto#1383) ce13b13
- Remove roctracer support (pytorch/kineto#1419) 2a3a002
pytorchmergebot pushed a commit to pytorch/pytorch that referenced this pull request Jun 16, 2026
Includes the following commits:

- surface HSA queue ID (pytorch/kineto#1425) 1d43601
- Add TypedMetadata to CUPTI activities (pytorch/kineto#1434) 461a26c
- Move around methods so they are accurately described by the comments (pytorch/kineto#1435) ff95265
- Introduce TypedMetadata structs (pytorch/kineto#1433) 965a14d
- Add unit tests for sync/async interleaving behavior (pytorch/kineto#1431) 67612e6
- Restrict on-demand trace output path to a safe directory (pytorch/kineto#1426) 9ea826e
- Add a cancellation state to the state machine and remove syncTraceActive_ (pytorch/kineto#1355) 3289139
- Move state machine from profiler into async handler (pytorch/kineto#1352) eb578c5
- map kernel and copy events to logical stream ID instead of HSA queue ID (pytorch/kineto#1424) 25856f7
- Speedup and fix PyTorch CI build (pytorch/kineto#1428) e675bbb
- Add logging for async rejections (pytorch/kineto#1422) 14becfb
- Make sure we clear the logger observer before starting a new session (pytorch/kineto#1387) a8cae92
- Add a scope guard for logging to help us capture all exit paths (pytorch/kineto#1383) ce13b13
- Remove roctracer support (pytorch/kineto#1419) 2a3a002
Pull Request resolved: #187440
Approved by: https://github.com/ryanzhang22, https://github.com/Skylion007
gplutop7 pushed a commit to gplutop7/pytorch that referenced this pull request Jul 15, 2026
Includes the following commits:

- surface HSA queue ID (pytorch/kineto#1425) 1d43601
- Add TypedMetadata to CUPTI activities (pytorch/kineto#1434) 461a26c
- Move around methods so they are accurately described by the comments (pytorch/kineto#1435) ff95265
- Introduce TypedMetadata structs (pytorch/kineto#1433) 965a14d
- Add unit tests for sync/async interleaving behavior (pytorch/kineto#1431) 67612e6
- Restrict on-demand trace output path to a safe directory (pytorch/kineto#1426) 9ea826e
- Add a cancellation state to the state machine and remove syncTraceActive_ (pytorch/kineto#1355) 3289139
- Move state machine from profiler into async handler (pytorch/kineto#1352) eb578c5
- map kernel and copy events to logical stream ID instead of HSA queue ID (pytorch/kineto#1424) 25856f7
- Speedup and fix PyTorch CI build (pytorch/kineto#1428) e675bbb
- Add logging for async rejections (pytorch/kineto#1422) 14becfb
- Make sure we clear the logger observer before starting a new session (pytorch/kineto#1387) a8cae92
- Add a scope guard for logging to help us capture all exit paths (pytorch/kineto#1383) ce13b13
- Remove roctracer support (pytorch/kineto#1419) 2a3a002
Pull Request resolved: pytorch#187440
Approved by: https://github.com/ryanzhang22, https://github.com/Skylion007
aws-kingrj pushed a commit to amazon-contributing/upstream-to-pytorch that referenced this pull request Jul 29, 2026
Includes the following commits:

- surface HSA queue ID (pytorch/kineto#1425) 1d43601
- Add TypedMetadata to CUPTI activities (pytorch/kineto#1434) 461a26c
- Move around methods so they are accurately described by the comments (pytorch/kineto#1435) ff95265
- Introduce TypedMetadata structs (pytorch/kineto#1433) 965a14d
- Add unit tests for sync/async interleaving behavior (pytorch/kineto#1431) 67612e6
- Restrict on-demand trace output path to a safe directory (pytorch/kineto#1426) 9ea826e
- Add a cancellation state to the state machine and remove syncTraceActive_ (pytorch/kineto#1355) 3289139
- Move state machine from profiler into async handler (pytorch/kineto#1352) eb578c5
- map kernel and copy events to logical stream ID instead of HSA queue ID (pytorch/kineto#1424) 25856f7
- Speedup and fix PyTorch CI build (pytorch/kineto#1428) e675bbb
- Add logging for async rejections (pytorch/kineto#1422) 14becfb
- Make sure we clear the logger observer before starting a new session (pytorch/kineto#1387) a8cae92
- Add a scope guard for logging to help us capture all exit paths (pytorch/kineto#1383) ce13b13
- Remove roctracer support (pytorch/kineto#1419) 2a3a002
Pull Request resolved: pytorch#187440
Approved by: https://github.com/ryanzhang22, https://github.com/Skylion007
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants