summaryrefslogtreecommitdiff
path: root/rtl/gfx/fp_add.sv
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--rtl/gfx/fp_add.sv17
1 files changed, 17 insertions, 0 deletions
diff --git a/rtl/gfx/fp_add.sv b/rtl/gfx/fp_add.sv
index fad4768..e8e0c5f 100644
--- a/rtl/gfx/fp_add.sv
+++ b/rtl/gfx/fp_add.sv
@@ -18,6 +18,23 @@ module fp_add
.areset(0),
.*
);
+`else
+ fp a_pipeline[`FP_ADD_STAGES - 1], b_pipeline[`FP_ADD_STAGES - 1];
+
+ integer i;
+
+ always @(posedge clk)
+ if (!stall) begin
+ a_pipeline[0] <= a;
+ b_pipeline[0] <= b;
+
+ for (i = 1; i < `FP_ADD_STAGES - 1; ++i) begin
+ a_pipeline[i] <= a_pipeline[i - 1];
+ b_pipeline[i] <= b_pipeline[i - 1];
+ end
+
+ q <= $c("taller::fp_add(", a_pipeline[`FP_ADD_STAGES - 2], ", ", b_pipeline[`FP_ADD_STAGES - 2], ")");
+ end
`endif
endmodule