-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Issue]: Recent changes to 6.0.1-112 make it ABI incompatible to 6.0.0 #152
Comments
Are you referring specifically to the fact the |
Correct.
This is a particular bad example in this case, as it does not tell the linker/runtime loader, that |
That's a great point. We expect the Question: Did it break your application? or are you just saying it should have a different version to identify the change? |
I'm just reading the code. There are at least two possible ways I know to prevent changing the soname every time a struct changes its size:
I think its too late for option 2., but 1. should still be able to add, but it wont avoid the increment in this bugfix |
@bertwesarg @oliveiradan Internal ticket has been created to fix this issue. Thanks! |
Hi @bertwesarg, sorry for the late follow up. Note that rocm-smi is going to be deprecated soon in favor of amd-smi. Currently, amd-smi follows a versioning pattern of YEAR.MAJOR.MINOR.RELEASE where "Major version should be changed for every header change (adding/deleting APIs, changing names, fields of structures, etc.)" (see here). So the MAJOR version will be updated (but not necessarily the YEAR) in scenarios like the one you have described. As a workaround, at the start of your program, you can get the full version of libamd_smi.so loaded using Let me know if you have any follow-up questions. |
You are using |
The YEAR is only updated alongside a MAJOR update (not for a MINOR update).
Why is that? Unless you have multiple versions of ROCm installed it won't work anyways. |
@bertwesarg waiting on a response |
But that was not mentioned in your first message: "So the MAJOR version will be updated (but not necessarily the YEAR)". if YEAR and MAJOR are interlinked why having both? So you could try use both YEAR and MAJOR in the SONAME. I saw such libraries already in the wild.
checking the ABI at runtime is not mandatory, you cannot force the users to do it and abort appropriately. And documentation does not help either. The SONAME will be obeyed by the loader, no checking from the user needed you don't need multiple version installed at the same time, a version upgrade is all you need |
Sorry if this wasn't clear. I meant to say that:
Right, which is why I said that it is a workaround. If someone is using the AMD SMI C++ library as part of their own tool or something (note that there is already the cli tool for normal users) and they are worried about undefined behavior from a version upgrade that changes the library's API, they can check the version at runtime using
That is possible. Anyways amd smi may undergo a change in the versioning scheme matching what you're asking for, I will update this issue once there is more info. |
Problem Description
6.0.1-112
includes this change to therocm_smi.h
header:but this change of the size of type
rsmi_gpu_metrics_t
breaks the ABI to 6.0.0. And currently bothlibrocm_smi.so
libs have the same interface version6
.The text was updated successfully, but these errors were encountered: