rocp_sdk: Update errorcodes#531
Merged
Treece-Burgess merged 1 commit intoicl-utk-edu:masterfrom Feb 2, 2026
Merged
Conversation
3 tasks
djwoun
requested changes
Feb 1, 2026
Contributor
djwoun
left a comment
There was a problem hiding this comment.
Tested on MI300A (Odyssey) with ROCm 7.1.1 and 7.2.0 (pre-release) as well. advanced.c passes and the fix behaves as expected.
The PAPI_EINVAL → PAPI_ENOEVNT change for unsupported event variants makes sense, but I think we should keep PAPI_EINVAL for malformed qualifier syntax (e.g., missing =) to avoid masking user typos.
djwoun
approved these changes
Feb 2, 2026
Contributor
djwoun
left a comment
There was a problem hiding this comment.
My concerns regarding typos are resolved given that:
- A missing = could be treated as either PAPI_EINVAL or PAPI_ENOEVNT
- PAPI_ENOEVNT aligns with the CUDA component's behavior.
- The skip logic in the component tests is being removed in PR #530.
562ef28 to
cc90324
Compare
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.
Pull Request Description
Background:
Currently in the master branch, the
rocp_sdkcomponent tests have "desired events" or events that we want to run the tests with as they will actually give non-zero values back to us. A helper function exists which attempts to add these events and ifPAPI_ENOEVNTis returned then we continue to the next "desired event"; however, if an errorcode besidesPAPI_ENOEVNTis returned then the test fails.Issue #524 was created as in ROCm versions >= 7.0.1 the
advanced.ctest fails due to a subset of the "desired events" not existing anymore. The helper function should catch this and move onto the next desired event, but the actual errorcode being returned internally isPAPI_EINVAL. Thus resulting in the test failing.After discussion with Daniel, we agreed that updating
PAPI_EINVALtoPAPI_ENOEVNTwhere applicable was the proper step to remedy this issue.Testing
Setup
System: Odyssey at Oregon
OS: RHEL 8.10
CPU: AMD MI300A
GPU: AMD MI300A
ROCm version: 7.1.1 and 7.2.0 (pre-release)
Results
advanced.cpasses: ✅simple.c,simple_sampling.c, andtwo_eventsets.cpass: ✅ (for 7.2.0two_eventsets.cshows zero values for events which previously did not have zero values this is a separate issue and will be looked into)./papi_command_line rocp_sdk:::SQ_BUSY_CYCLES:DIMENSION_INSTANCE=0:DIMENSION_SHADER_ENGINE=4:device=0returnsPAPI_ENOEVNT: ✅Author Checklist
Why this PR exists. Reference all relevant information, including background, issues, test failures, etc
Commits are self contained and only do one thing
Commits have a header of the form:
module: short descriptionCommits have a body (whenever relevant) containing a detailed description of the addressed problem and its solution
The PR needs to pass all the tests