From 2bf51431637e52e467c7ce9660e97aa087759e2e Mon Sep 17 00:00:00 2001 From: David Harris Date: Sat, 11 Nov 2023 05:58:53 -0800 Subject: [PATCH] Bug fixes related to size of fpdivsqrt bit count and number of cycles --- config/shared/config-shared.vh | 6 ++++-- src/fpu/fdivsqrt/fdivsqrtcycles.sv | 2 +- testbench/testbench-fp.sv | 3 +++ 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/config/shared/config-shared.vh b/config/shared/config-shared.vh index 61bf461eb..cc230ef3e 100644 --- a/config/shared/config-shared.vh +++ b/config/shared/config-shared.vh @@ -93,6 +93,7 @@ localparam NF2 = ((F_SUPPORTED & (LEN1 != S_LEN)) ? S_NF : H_NF); localparam FMT2 = ((F_SUPPORTED & (LEN1 != S_LEN)) ? 2'd0 : 2'd2); localparam BIAS2 = ((F_SUPPORTED & (LEN1 != S_LEN)) ? S_BIAS : H_BIAS); + // intermediate division parameters not directly used in Divider localparam FPDIVN = NF+3; // length of floating-point inputs: Ns + 2 = Nf + 3 for 1 integer bit, Nf fracitonal bits, 2 extra bits to shift sqrt into [1/4, 1)] localparam DIVN = ((FPDIVN