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

Improve UnitCL pow testing. #278

Merged
merged 1 commit into from
Jan 4, 2024
Merged

Conversation

hvdijk
Copy link
Collaborator

@hvdijk hvdijk commented Jan 4, 2024

Overview

Improve UnitCL pow testing.

Reason for change

We single out the value 0x39f6 in our implementation of log2_extended_precision, so in tests that use that function, we should ensure that that value is always tested.

Description of change

This adds an overridable GetEdgeCases() function, defaulting to the InputGenerator::half_edge_cases we previously used, but overridden for HalfMathBuiltinsPow to additionally add 0x39f6 as an edge case.

Tested by locally reverting commit 90cf2fa and verifying that UnitCL reliably picks up the error.

Anything else we should know?

If there's any other relevant information we should know that may help us in
understanding and verifying your patch, please include it here.

Checklist

  • Read and follow the project Code of Conduct.
  • Make sure the project builds successfully with your changes.
  • Run relevant testing locally to avoid regressions.
  • Run clang-format-16 (the most
    recent version available through pip) on all modified code.

We single out the value 0x39f6 in our implementation of
log2_extended_precision, so in tests that use that function, we should
ensure that that value is always tested.
@hvdijk hvdijk merged commit ae30b07 into uxlfoundation:main Jan 4, 2024
3 checks passed
@hvdijk hvdijk deleted the pow-testing branch January 4, 2024 14:57
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.

3 participants