aboutsummaryrefslogtreecommitdiff
path: root/src/rtl/pe/modexpa7_pe_add.v
diff options
context:
space:
mode:
Diffstat (limited to 'src/rtl/pe/modexpa7_pe_add.v')
-rw-r--r--src/rtl/pe/modexpa7_pe_add.v27
1 files changed, 20 insertions, 7 deletions
diff --git a/src/rtl/pe/modexpa7_pe_add.v b/src/rtl/pe/modexpa7_pe_add.v
index 9cde591..467be5d 100644
--- a/src/rtl/pe/modexpa7_pe_add.v
+++ b/src/rtl/pe/modexpa7_pe_add.v
@@ -47,14 +47,27 @@ module modexpa7_pe_add
output c_out
);
- reg [32: 0] s_reg;
- assign s = s_reg[31: 0];
- assign c_out = s_reg[32];
-
- always @(posedge clk)
- //
- if (ce) s_reg <= {1'b0, a} + {1'b0, b} + {32'd0, c_in};
+ //
+ // Include Primitive Selector
+ //
+ `include "modexpa7_pe_settings.v"
+
+
+ //
+ // Instantiate Vendor/Generic Primitive
+ //
+ `ADDER32_PRIMITIVE adder32_inst
+ (
+ .clk(clk),
+ .ce(ce),
+ .a(a),
+ .b(b),
+ .s(s),
+ .c_in(c_in),
+ .c_out(c_out)
+ );
+
endmodule