diff --git a/aws/cl_zcash/ip/axi_fifo_mm_s_0.xci b/aws/cl_zcash/ip/axi_fifo_mm_s_0.xci
index 886231f..a4ccd3e 100644
--- a/aws/cl_zcash/ip/axi_fifo_mm_s_0.xci
+++ b/aws/cl_zcash/ip/axi_fifo_mm_s_0.xci
@@ -17,7 +17,7 @@
0.000
100000000
- 0
+ 1
1
1
0
@@ -43,7 +43,7 @@
0
100000000
- 0
+ 1
1
1
0
@@ -122,19 +122,19 @@
0
0
0x00000000
- 0x00002FFF
+ 0x80002FFF
4
4
64
- 0x00000000
+ 0x80000000
1
virtexuplus
0
0
- 0
+ 1
0
0
- 0x00000FFF
+ 0x80000FFF
512
5
507
@@ -151,7 +151,7 @@
0
1
0x00000000
- 0x00002FFF
+ 0x80002FFF
4
4
64
@@ -161,11 +161,11 @@
32
XIL_AXI_STREAM_ETH_DATA
32
- 0x00000000
+ 0x80000000
1
false
false
- false
+ true
false
false
0x80000FFF
@@ -212,10 +212,12 @@
+
+
@@ -242,6 +244,7 @@
+
diff --git a/ip_cores/ec/src/rtl/ec_point_add.sv b/ip_cores/ec/src/rtl/ec_point_add.sv
index 65d2bae..2fefb46 100644
--- a/ip_cores/ec/src/rtl/ec_point_add.sv
+++ b/ip_cores/ec/src/rtl/ec_point_add.sv
@@ -44,7 +44,7 @@ module ec_point_add
if_axi_stream.sink i_sub_if
);
-
+localparam CHK_INPUT = 1;
/*
These are the equations that need to be computed, they are issued as variables
become valid. We have a bitmask to track what equation results are valid which
@@ -96,6 +96,7 @@ logic [23:0] eq_val, eq_wait;
FE_TYPE A, B, C, D;
FP_TYPE i_p1_l, i_p2_l;
+
enum {IDLE, START, FINISHED} state;
always_ff @ (posedge i_clk) begin
if (i_rst) begin
@@ -142,23 +143,25 @@ always_ff @ (posedge i_clk) begin
if (i_val && o_rdy) begin
state <= START;
o_rdy <= 0;
- // If one point is at infinity
- if (i_p1.z == 0 || i_p2.z == 0) begin
- state <= FINISHED;
- o_val <= 1;
- o_p <= (i_p1.z == 0 ? i_p2 : i_p1);
- end else
- // If the points are opposite each other
- if ((i_p1.x == i_p2.x) && (i_p1.y != i_p2.y)) begin
- state <= FINISHED;
- o_val <= 1;
- o_p <= 0; // Return infinity
- end else
- // If the points are the same this module cannot be used
- if ((i_p1.x == i_p2.x) && (i_p1.y == i_p2.y)) begin
- state <= FINISHED;
- o_err <= 1;
- o_val <= 1;
+ if (CHK_INPUT == 1) begin
+ // If one point is at infinity
+ if (i_p1.z == 0 || i_p2.z == 0) begin
+ state <= FINISHED;
+ o_val <= 1;
+ o_p <= (i_p1.z == 0 ? i_p2 : i_p1);
+ end else
+ // If the points are opposite each other
+ if ((i_p1.x == i_p2.x) && (i_p1.y != i_p2.y)) begin
+ state <= FINISHED;
+ o_val <= 1;
+ o_p <= 0; // Return infinity
+ end else
+ // If the points are the same this module cannot be used
+ if ((i_p1.x == i_p2.x) && (i_p1.y == i_p2.y)) begin
+ state <= FINISHED;
+ o_err <= 1;
+ o_val <= 1;
+ end
end
end
end
diff --git a/ip_cores/ec/src/rtl/ec_point_dbl.sv b/ip_cores/ec/src/rtl/ec_point_dbl.sv
index 822e802..1bdf9d8 100644
--- a/ip_cores/ec/src/rtl/ec_point_dbl.sv
+++ b/ip_cores/ec/src/rtl/ec_point_dbl.sv
@@ -41,6 +41,7 @@ module ec_point_dbl
if_axi_stream.sink i_sub_if
);
+localparam CHK_INPUT = 0;
/*
* These are the equations that need to be computed, they are issued as variables
* become valid. We have a bitmask to track what equation results are valid which
@@ -116,10 +117,12 @@ always_ff @ (posedge i_clk) begin
if (i_val && o_rdy) begin
state <= START;
o_rdy <= 0;
- if (i_p.z == 0) begin
- o_p <= i_p;
- o_val <= 1;
- state <= FINISHED;
+ if (CHK_INPUT == 1) begin
+ if (i_p.z == 0) begin
+ o_p <= i_p;
+ o_val <= 1;
+ state <= FINISHED;
+ end
end
end
end