mirror of
https://github.com/openhwgroup/cvw
synced 2025-02-11 06:05:49 +00:00
commit
669855ad25
@ -75,6 +75,7 @@ module fcmp import cvw::*; #(parameter cvw_t P) (
|
||||
3'b0?1: if (P.ZFA_SUPPORTED)
|
||||
CmpNV = Zfa ? EitherSNaN : EitherNaN; // fltq,fleq / flt,fle perform CompareQuietLess / CompareSignalingLess differing on when to set invalid
|
||||
else CmpNV = EitherNaN; // flt, fle
|
||||
3'b100: CmpNV = 1'b0;
|
||||
default: CmpNV = 1'bx;
|
||||
endcase
|
||||
end
|
||||
|
@ -146,7 +146,8 @@ module fround import cvw::*; #(parameter cvw_t P) (
|
||||
packoutput #(P) packoutput(W, Fmt, FRound); // pack and NaN-box based on selected format.
|
||||
|
||||
// Flags
|
||||
assign FRoundNV = XSNaN; // invalid if input is signaling NaN
|
||||
assign FRoundNX = ZfaFRoundNX & ~EgeNf & (Rp | Tp); // Inexact if Round or Sticky bit set for FRoundNX instruction
|
||||
assign FRoundNV = XSNaN; // invalid if input is signaling NaN
|
||||
assign FRoundNX = ZfaFRoundNX & ~EgeNf & (Rp | Tp) & ~XNaN; // Inexact if Round or Sticky bit set for FRoundNX instruction
|
||||
// Note: NX must not be raised if input is invalid
|
||||
|
||||
endmodule
|
||||
|
Loading…
Reference in New Issue
Block a user