Conversion from FP32 -2^31 to INT32 sets NV status
Created by: pashenden
In v0.7.0, converting the FP32 value -2147483648.0 to INT32 produces the result 0x80000000 and sets the NV status flag. However, the input value can be exactly represented as an INT32.
Test case:
operands_i = '{0: 32'hcf000000, 1: 32'h00000000, 2: 32'h00000000};
rnd_mode_i = RNE;
op_i = F2I;
op_mod_i = 1'b0;
src_fmt_i = FP32;
int_fmt_i = INT32;
Root cause: These lines do not take account of the fact that for the valid input value, the exponent is exactly 31. If the sign is negative and the mantissa is 0x80000000 in this case, there should not be overflow.