intel / intel/rohd-hcl

Unify rounding modes

Open
#173 0 comments 1 reaction 0 assignees View on GitHub
enhancement
Dominant language
Dart
Stars
115
Forks
39
Avg merge
1d 13h
Merged PRs (30d)
1

Description

### Motivation

It would be nice to have the same options for rounding for both fixed and float operations by using our enum for rounding modes.
Right now we have ofDouble and ofDoubleUnrounded for the floating point type, and just ofDouble for the fixed-point.

### Desired solution

Floating and fixed-point should have a parallel API that passes in the type of rounding.

Also, the other rounding modes need implementation. Right now we have truncation and RNE supported in various places, both on the Logic side as well as the value side. These should all be combed out so they are parallel and uniform to lead to a least-surprise API.

We are working on a refactoring of the FPV API to remove some of the boilerplate and factory constructors, but this feature could be added after that is complete to help further simplify the API on the value side.

### Alternatives considered

_No response_

### Additional details

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.