Skip to content
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

Change GFX number checking for fp8 hw support #3634

Closed
wants to merge 1 commit into from
Closed

Conversation

CharlieL7
Copy link
Collaborator

  • Enable fp8ocp for upcoming hardware

@CharlieL7 CharlieL7 added the simple small or simple changes label Nov 19, 2024
@CharlieL7 CharlieL7 self-assigned this Nov 19, 2024
@@ -52,13 +52,15 @@ std::string get_device_name()
bool gfx_has_fp8fnuz_intrinsics()
{
const auto device_name = trim(split_string(get_device_name(), ':').front());
return (starts_with(device_name, "gfx9") and device_name >= "gfx940");
return (starts_with(device_name, "gfx94"));
Copy link
Collaborator

Choose a reason for hiding this comment

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

How do you deal with MI100, MI2xx ?

Copy link
Collaborator

Choose a reason for hiding this comment

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

They don't officially support fp8. They weren't going through with the previous condition anyways.

}

bool gfx_has_fp8ocp_intrinsics()
{
const auto device_name = trim(split_string(get_device_name(), ':').front());
return (starts_with(device_name, "gfx12") and device_name >= "gfx1200");
bool is_navi4x = starts_with(device_name, "gfx12") and device_name >= "gfx1200";
bool is_mi35x = starts_with(device_name, "gfx9") and device_name >= "gfx950";
Copy link
Collaborator

Choose a reason for hiding this comment

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

I get what you are trying to do here, just be mindful of future work. If there is ever a mi36x the next person wouldn't need to make a code change here since the gfx number "should" increase in number. Yet the variable being named mi35x would still cause someone to come look at the code and have to think about the intention. is_mi_fp8ocp may show intent with less head scratching for the next developer

@CharlieL7 CharlieL7 closed this Nov 19, 2024
@CharlieL7 CharlieL7 deleted the fp8ocp_mi350 branch November 19, 2024 18:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
simple small or simple changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants