-
Notifications
You must be signed in to change notification settings - Fork 111
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
✨ Add symmetric add operation for same source FP format add/sub #114
Merged
zarubaf
merged 4 commits into
openhwgroup:develop
from
michael-platzer:feature/multi-fma-symmetric-add
May 23, 2024
Merged
✨ Add symmetric add operation for same source FP format add/sub #114
zarubaf
merged 4 commits into
openhwgroup:develop
from
michael-platzer:feature/multi-fma-symmetric-add
May 23, 2024
Conversation
This file contains 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
e046e1a
to
3740255
Compare
@lucabertaccini @pascalgouedo @stmach Any feedback on this? 🙃 |
Hi @michael-platzer |
stmach
reviewed
May 21, 2024
3740255
to
ba48b59
Compare
lucabertaccini
approved these changes
May 22, 2024
LGTM |
stmach
approved these changes
May 22, 2024
michael-platzer
added a commit
to michael-platzer/cvfpu
that referenced
this pull request
Aug 22, 2024
…hwgroup#114) * 🏷️ Add new operation for symmetric (same src fmt) add * ✨ Select multi FMA addend fmt independently * 💡 Add new operation to comment in multi FMA src * 📝 Document new symmetric add operation
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This PR adds a new operation
ADDS
to theoperation_e
enum, which implements a symmetric addition/subtraction, i.e., with both addends having the same source format.As discussed in #113, currently the addend (i.e., the third operand) of the multi-format FMA is given in destination FP format, rather than source FP format. While this makes sense for fused multiply-accumulate operations, which add the product of two multiplicands in one FP format to an accumulator value in destination FP format, it is beneficial to support symmetric addition and subtraction, for which both addends are in source FP format.
For backwards compatibility and to avoid adding new ports to the top module, this PR adds a dedicated new operation
ADDS
for this symmetric add, which has the effect of selecting the source FP format for the FMA's third operand, rather than the destination FP format. A new portadd_fmt_i
is added to the multi-format FMA for this purpose and assigned based on the selected operation.Closes #113.