Commit 590abe09 authored by Albert Ou's avatar Albert Ou Committed by Chih-Min Chao
Browse files

rvv: fix INT_ROUNDING compliance



* round-to-nearest-even: In the case that result[gb] = 0, the result
  should still be rounded up if result[gb-1] != 0 && result[gb-2:0] != 0
  (the usual round-to-nearest behavior outside of the tiebreaker).
* round-down: Since all uses of INT_ROUNDING() are immediately followed
  with a right shift by gb, clearing the lower bits is unnecessary.
* round-to-odd: The LSB should be OR'd only if result[gb-1:0] != 0.

Signed-off-by: default avatarAlbert Ou <aou@eecs.berkeley.edu>
parent b9d9e1eb
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment