-
Notifications
You must be signed in to change notification settings - Fork 146
Float: Introduce floating point api sign #542
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
Float: Introduce floating point api sign #542
Conversation
* Both the positive and negative are included. * Add test case for half, single and double floating point. * Add sign to interface. Signed-off-by: Pan Li <pan2.li@intel.com>
…oat-point-sign Signed-off-by: Pan Li <pan2.li@intel.com>
Signed-off-by: Pan Li <pan2.li@intel.com>
|
|
||
| val float_is_negative : fp_bits -> bool | ||
| function float_is_negative (op) = { | ||
| let struct {sign, _} = float_decompose(op); |
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 expect here may be {sign, _, _} but it will result in error like below. Not sure if I missed something.
37 | let struct {sign, _, _} = float_decompose(op);
| ^ previous field wildcard here
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.
That's correct. The wildcard there ignores all fields of the struct, so having two is redundant. I've added a bit more to the error message for this.
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.
Thanks for explain, that make much sense to me.
|
I think this branch needs rebased, but once that's done I should be able to merge it. |
Sure, merged upstream/sail2 already. |
|
BTW, github may support rebase code with a simple click in Pull Request. Maybe we can try to enable it, just a proposal here. |
|
Kindly ping, and rebase the upstream branch already. |
|
Great, thanks a lot. |
Signed-off-by: Pan Li pan2.li@intel.com