-
Notifications
You must be signed in to change notification settings - Fork 14.9k
[libc][math][c++23] Add {get,set}payloadbf16 and setpayloadsigbf16 math functions #153994
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
Merged
Merged
Changes from 13 commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
b58785d
feat: implement {,u}fromfp{,x}bf16 math functions
krishna2803 0a2b527
chore: add tests for {,u}fromfp{,x}bf16 math functions
krishna2803 baaf0e0
chore: update entrypoints
krishna2803 733f4f1
chore: update docs
krishna2803 4a80312
feat: implement next{after,down,toward,up}bf16 math functions
krishna2803 446e637
chore: add smoke tests for next{after,down,toward,up}bf16 math functions
krishna2803 a98b928
chore: update entrypoints
krishna2803 12f1923
docs: add next{after,down,toward,up}bf16 math functions
krishna2803 6f8d84d
feat: implement {get,set}payloadbf16 and setpayloadsigbf16 math funct…
krishna2803 c8f4380
chore: implement smoke tests for {get,set}payloadbf16 and setpayloads…
krishna2803 8ea9354
fix: add correct static_cast for fputil::getpload for bfloat16
krishna2803 fc2b6eb
chore: update entrypoints
krishna2803 70e4463
docs: add {get,set}payloadbf16 and setpayloadsigbf16 math functions
krishna2803 5ad41c5
revert: "fix: add correct static_cast for fputil::getpload for bfloat16"
krishna2803 3486509
fix: remove BFloat16(uint16) ctor
krishna2803 c1f0b9e
Merge branch 'main' into users/krishna2803/payloadbf16
krishna2803 b310e15
nit: add separate gaurd for 5 bits
krishna2803 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
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
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
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
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
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we have the
BFloat16(uint16_t bits)
constructor again? Removing it makes this change unnecessary andlibc-math-smoke-tests
andlibc.test.src.__support.FPUtil.bfloat16_test.__unit__
still pass.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added it in case we might need to construct bfloat16 directly using uint16 values to be able to set its bits directly, but I think it can be removed as we don't use it anywhere. I will run all tests locally to confirm this.