Skip to content

Conversation

@whitneywhtsang
Copy link
Contributor

@whitneywhtsang whitneywhtsang commented Oct 12, 2024

Move setting of fast math flags from ScheduleLoad pass, so that it can be reused for both default and advanced path.
CI: https://github.com/intel/intel-xpu-backend-for-triton/actions/runs/11302770929

@whitneywhtsang whitneywhtsang self-assigned this Oct 12, 2024
@whitneywhtsang whitneywhtsang force-pushed the whitneywhtsang/fastmath branch from 3f4acb1 to e5996c5 Compare October 12, 2024 04:00
@whitneywhtsang whitneywhtsang marked this pull request as ready for review October 12, 2024 14:04
Signed-off-by: Whitney Tsang <[email protected]>
@whitneywhtsang whitneywhtsang force-pushed the whitneywhtsang/fastmath branch from e5996c5 to 831d42b Compare October 13, 2024 17:16
@chengjunlu
Copy link
Contributor

Should be the fast math controlled by the user for tuning the accuracy?

@whitneywhtsang
Copy link
Contributor Author

Should be the fast math controlled by the user for tuning the accuracy?

According to the logic in triton-lang/triton@84fe9da, users are expected to use libdevice if they want high precision.

@chengjunlu
Copy link
Contributor

Should be the fast math controlled by the user for tuning the accuracy?

According to the logic in triton-lang/triton@84fe9da, users are expected to use libdevice if they want high precision.

Make sense. Another question not related to this PR. It seems the default path has already uses the fast math because we use the same lowering logic as the upstream. Is it?

@whitneywhtsang
Copy link
Contributor Author

Make sense. Another question not related to this PR. It seems the default path has already uses the fast math because we use the same lowering logic as the upstream. Is it?

Default path uses the same lowering logic as upstream, but it doesn't add fast math as aggressive as this PR. This PR adds to add possible operations that have the fast math interface.

Copy link
Contributor

@FMarno FMarno left a comment

Choose a reason for hiding this comment

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

It would be nice to see something to evidence that this change makes a difference (like some tests) but the changes look fine.

Signed-off-by: Whitney Tsang <[email protected]>
@whitneywhtsang whitneywhtsang enabled auto-merge (squash) October 15, 2024 14:00
@whitneywhtsang whitneywhtsang merged commit fc4da18 into main Oct 15, 2024
4 checks passed
@whitneywhtsang whitneywhtsang deleted the whitneywhtsang/fastmath branch October 15, 2024 15:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants