amd_smi: fail on unexpected add/start errors#555
Merged
Treece-Burgess merged 1 commit intoicl-utk-edu:masterfrom Feb 6, 2026
Merged
amd_smi: fail on unexpected add/start errors#555Treece-Burgess merged 1 commit intoicl-utk-edu:masterfrom
Treece-Burgess merged 1 commit intoicl-utk-edu:masterfrom
Conversation
f4629c0 to
58be8a3
Compare
Treece-Burgess
requested changes
Feb 5, 2026
c52cf22 to
767ae83
Compare
Treece-Burgess
approved these changes
Feb 6, 2026
Contributor
Treece-Burgess
left a comment
There was a problem hiding this comment.
Testing was done on Odyssey at Oregon with ROCm 7.2.0.
In the master branch, if the call prepare_event_handle failed with an error code outside of PAPI_ENOEVNT, PAPI_ECNFLCT, PAPI_EPERM, or PAPI_ENOSUPP the test would pass:
[tburgess@odyssey tests]$ ./amdsmi_set_test
Skipping fan_speed test: event unavailable
PASSED
However, this branch updates this to the correct behavior:
[tburgess@odyssey tests]$ ./amdsmi_set_test
Unexpected error encountered (-24) when adding the event amd_smi:::power_cap.
Along with this, papi_component_avail, papi_native_avail, and papi_command_line work as expected.
The amd_smi component tests all pass (minus amdsmi_set_test.c as I lack the permissions to properly run this test).
767ae83 to
acb8caa
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
Updates EXIT_WARNING_ON_ADD to treat unexpected error codes (e.g., PAPI_EISRUN, PAPI_EINVAL) as test failures. Previously, non-listed errors were silently ignored, causing tests to pass incorrectly.
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