ParetoStack-chip 1.5.8: five FPGA samples to judge before installing
Ces pages d’exemples sont en anglais.
All designs are small samples that ship in the release. All samples were written for the product, so they do not predict gains on your design. Target: Lattice iCE40 HX8K (sample 5: ECP5-25k), open-source tools (Yosys 0.70, nextpnr). The measure is the highest clock frequency. A rewrite here adds latency: results come out one or more clocks later. Whether that is acceptable depends on your system.
Two kinds of figures, kept apart. "Tool estimate" is the timing model of the place-and-route tool. "Board" is the highest clock at which a placed design passed every test on one physical board, measured by a separate test setup of ours. The product itself does not program or measure hardware.
Limits of the board figures
- One board (Lattice iCE40-HX8K breakout), one chip, one room, 2026-11-28 and 29; temperature and supply voltage neither controlled nor recorded.
- The design sits inside a test circuit with its own stimulus, pins and constraints, so it is not placed as in the tool runs. Outputs were compared with simulation of the original design.
- A passing clock covers only the paths the test inputs exercise. It is not a guaranteed maximum or a timing signoff. Pass rule: 20 runs in a row; in repeats of 200 runs, 4 of 48 reported maxima failed (including one placement each of samples 2 and 3).
- Clock steps are about 3 to 4.5 % apart. Power was not measured. No other chip, board or vendor tool was tried.
1. 8-tap FIR filter: adder chain pipelined
gain on tool and board+3 samples latencyOn a narrow screen, scroll the listing sideways: the optimized version is on the right.
| Original: fir8.v | Optimized by the product | ||
|---|---|---|---|
| unchanged lines not shown | |||
| 17 | wire signed [W+7:0] p5 = d5 * 23; | 17 | wire signed [W+7:0] p5 = d5 * 23; |
| 18 | wire signed [W+7:0] p6 = d6 * -11; | 18 | wire signed [W+7:0] p6 = d6 * -11; |
| 19 | wire signed [W+7:0] p7 = d7 * 5; | 19 | wire signed [W+7:0] p7 = d7 * 5; |
| 20 | wire signed [W+7:0] sum = p0 + p1 + p2 + p3 + p4 + p5 + p6 + p7; | 20 | reg signed [W+7:0] sum_p0_0, sum_p0_1, sum_p0_2, sum_p0_3, sum_p0_4, sum_p0_5, sum_p0_6, sum_p0_7, sum_p1_0, sum_p1_1, sum_p1_2, sum_p1_3, sum_p2_0, sum_p2_1; |
| 21 | 21 | ||
| 22 | always @(posedge clk) begin | 22 | always @(posedge clk) begin |
| 23 | if (rst) begin | 23 | if (rst) begin |
| 24 | {d0, d1, d2, d3, d4, d5, d6, d7} <= 0; | 24 | {d0, d1, d2, d3, d4, d5, d6, d7} <= 0; |
| 25 | y <= 0; | 25 | y <= 0; sum_p0_0 <= 0; sum_p0_1 <= 0; sum_p0_2 <= 0; sum_p0_3 <= 0; sum_p0_4 <= 0; sum_p0_5 <= 0; sum_p0_6 <= 0; sum_p0_7 <= 0; sum_p1_0 <= 0; sum_p1_1 <= 0; sum_p1_2 <= 0; sum_p1_3 <= 0; sum_p2_0 <= 0; sum_p2_1 <= 0; |
| 26 | yv <= 0; | 26 | yv <= 0; |
| 27 | end else begin | 27 | end else begin |
| 28 | yv <= valid; | 28 | yv <= valid; |
| 29 | if (valid) begin | 29 | if (valid) begin |
| 30 | d0 <= x; d1 <= d0; d2 <= d1; d3 <= d2; d4 <= d3; d5 <= d4; d6 <= d5; d7 <= d6; | 30 | d0 <= x; d1 <= d0; d2 <= d1; d3 <= d2; d4 <= d3; d5 <= d4; d6 <= d5; d7 <= d6; |
| 31 | y <= sum; | 31 | sum_p0_0 <= p0; |
| 32 | sum_p0_1 <= p1; | ||
| 33 | sum_p0_2 <= p2; | ||
| 34 | sum_p0_3 <= p3; | ||
| 35 | sum_p0_4 <= p4; | ||
| 36 | sum_p0_5 <= p5; | ||
| 37 | sum_p0_6 <= p6; | ||
| 38 | sum_p0_7 <= p7; | ||
| 39 | sum_p1_0 <= sum_p0_0 + sum_p0_1; | ||
| 40 | sum_p1_1 <= sum_p0_2 + sum_p0_3; | ||
| 41 | sum_p1_2 <= sum_p0_4 + sum_p0_5; | ||
| 42 | sum_p1_3 <= sum_p0_6 + sum_p0_7; | ||
| 43 | sum_p2_0 <= sum_p1_0 + sum_p1_1; | ||
| 44 | sum_p2_1 <= sum_p1_2 + sum_p1_3; | ||
| 45 | y <= sum_p2_0 + sum_p2_1; | ||
| 32 | end | 46 | end |
| 33 | end | 47 | end |
| 34 | end | 48 | end |
| unchanged lines not shown | |||
The rewrite shown is what release 1.5.8 writes. It is byte for byte the file of the 1.5.5 run and the file that ran on the board.
Tool estimate (place-and-route timing model, not hardware)
| Run | Original | Rewrite | Ratio | Logic cells | Added latency |
|---|---|---|---|---|---|
| Release 1.5.5, 2026-11-21, 2 seeds | 59.5 MHz | 135.9 MHz | 2.28x | 929 to 723 | 3 |
| Development version, 2026-11-13, 10 seeds | 66.3 MHz | 133.5 MHz | 2.01x | 929 to 723 | 3 |
Measured on one FPGA board (highest clock that passed)
| Placements (seeds) | Original | Rewrite | Board ratio | Tool ratio on the same placements |
|---|---|---|---|---|
| 3 | 76.5 MHz | 162 MHz | 2.12x | 2.04x |
| 10 | 75 MHz | 162 MHz | 2.16x | 2.06x |
Checked by: simulation: the rewrite's output stream equals the original's, delayed by the added latency, under the sample's testbench; the synthesized netlist matches at gate level; and both designs were driven with the same random inputs (19,999 cycles). This is simulation, not a formal proof.
A rejection seen on this design: in an early development run (2026-10-26) two synthesis settings gave netlists that did not compute the design (one stuck at zero, one almost empty). The gate-level simulation rejected both. Their speed was irrelevant; the settings were corrected afterwards.
2. 16 x 16 multiply-accumulate: multiplier split
gain on tool and board+1 clock latencyOn a narrow screen, scroll the listing sideways: the optimized version is on the right.
| Original: mul16.v | Optimized by the product | ||
|---|---|---|---|
| unchanged lines not shown | |||
| 8 | ); | 8 | ); |
| 9 | reg [15:0] a_r, b_r; | 9 | reg [15:0] a_r, b_r; |
| 10 | reg [31:0] p_r; | 10 | reg [31:0] p_r; |
| 11 | wire [31:0] prod = a_r * b_r; | 11 | reg [31:0] prod_m0, prod_m1, prod_m2, prod_m3; |
| 12 | always @(posedge clk) begin | 12 | always @(posedge clk) begin |
| 13 | if (rst) begin | 13 | if (rst) begin |
| 14 | a_r <= 0; b_r <= 0; p_r <= 0; acc <= 0; | 14 | a_r <= 0; b_r <= 0; p_r <= 0; prod_m0 <= 0; prod_m1 <= 0; prod_m2 <= 0; prod_m3 <= 0; acc <= 0; |
| 15 | end else begin | 15 | end else begin |
| 16 | a_r <= a; | 16 | a_r <= a; |
| 17 | b_r <= b; | 17 | b_r <= b; |
| 18 | p_r <= prod; | 18 | prod_m0 <= a_r * b_r[3:0]; |
| 19 | prod_m1 <= a_r * b_r[7:4]; | ||
| 20 | prod_m2 <= a_r * b_r[11:8]; | ||
| 21 | prod_m3 <= a_r * b_r[15:12]; | ||
| 22 | p_r <= prod_m0 + (prod_m1 << 4) + (prod_m2 << 8) + (prod_m3 << 12); | ||
| 19 | acc <= acc + p_r; | 23 | acc <= acc + p_r; |
| 20 | end | 24 | end |
| 21 | end | 25 | end |
| unchanged lines not shown | |||
The rewrite shown is what release 1.5.8 writes. It is byte for byte the file of the 1.5.5 run and the file that ran on the board.
Tool estimate (place-and-route timing model, not hardware)
| Run | Original | Rewrite | Ratio | Logic cells | Added latency |
|---|---|---|---|---|---|
| Release 1.5.5, 2026-11-21, 2 seeds | 69.4 MHz | 103.2 MHz | 1.49x | 730 to 626 | 1 |
| Development version, 2026-11-13, 10 seeds | 70.2 MHz | 104.2 MHz | 1.48x | 730 to 626 | 1 |
Measured on one FPGA board (highest clock that passed)
| Placements (seeds) | Original | Rewrite | Board ratio | Tool ratio on the same placements |
|---|---|---|---|---|
| 3 | 81 MHz | 126 MHz | 1.56x | 1.45x |
| 10 | 84 MHz | 126 MHz | 1.50x | 1.47x |
Checked by: simulation: the rewrite's output stream equals the original's, delayed by the added latency, under the sample's testbench; the synthesized netlist matches at gate level; and both designs were driven with the same random inputs (19,999 cycles). This is simulation, not a formal proof.
3. 8-bit ALU: the estimated gain mostly did not hold on the board
gain size not confirmed+1 clock latencyThe rewrite is functionally correct and passed every check. Its size of gain did not survive on the board.
On a narrow screen, scroll the listing sideways: the optimized version is on the right.
| Original: alu8.v | Optimized by the product | ||
|---|---|---|---|
| unchanged lines not shown | |||
| 10 | ); | 10 | ); |
| 11 | reg [2:0] op_r; reg [7:0] a_r, b_r; | 11 | reg [2:0] op_r; reg [7:0] a_r, b_r; |
| 12 | reg [15:0] r; | 12 | reg [15:0] r; |
| 13 | reg [2:0] op_r_dly; | ||
| 14 | reg [7:0] a_r_dly; | ||
| 15 | reg [7:0] b_r_dly; | ||
| 16 | reg [15:0] r_m0, r_m1; | ||
| 13 | always @* begin | 17 | always @* begin |
| 14 | case (op_r) | 18 | case (op_r_dly) |
| 15 | 3'd0: r = a_r + b_r; | 19 | 3'd0: r = a_r_dly + b_r_dly; |
| 16 | 3'd1: r = a_r - b_r; | 20 | 3'd1: r = a_r_dly - b_r_dly; |
| 17 | 3'd2: r = a_r & b_r; | 21 | 3'd2: r = a_r_dly & b_r_dly; |
| 18 | 3'd3: r = a_r | b_r; | 22 | 3'd3: r = a_r_dly | b_r_dly; |
| 19 | 3'd4: r = a_r ^ b_r; | 23 | 3'd4: r = a_r_dly ^ b_r_dly; |
| 20 | 3'd5: r = a_r << b_r[2:0]; | 24 | 3'd5: r = a_r_dly << b_r_dly[2:0]; |
| 21 | 3'd6: r = a_r * b_r; | 25 | 3'd6: r = r_m0 + (r_m1 << 4); |
| 22 | default: r = {8'b0, a_r} + {8'b0, b_r} + 16'd1; | 26 | default: r = {8'b0, a_r_dly} + {8'b0, b_r_dly} + 16'd1; |
| 23 | endcase | 27 | endcase |
| 24 | end | 28 | end |
| 25 | always @(posedge clk) begin | 29 | always @(posedge clk) begin |
| 26 | if (rst) begin op_r <= 0; a_r <= 0; b_r <= 0; y <= 0; zero <= 1; end | 30 | if (rst) begin op_r <= 0; a_r <= 0; b_r <= 0; y <= 0; op_r_dly <= 0; a_r_dly <= 0; b_r_dly <= 0; r_m0 <= 0; r_m1 <= 0; zero <= 1; end |
| 27 | else begin op_r <= op; a_r <= a; b_r <= b; y <= r; zero <= (r == 0); end | 31 | else begin op_r <= op; a_r <= a; b_r <= b; op_r_dly <= op_r; a_r_dly <= a_r; b_r_dly <= b_r; r_m0 <= a_r * b_r[3:0]; r_m1 <= a_r * b_r[7:4]; y <= r; zero <= (r == 0); end |
| 28 | end | 32 | end |
| 29 | endmodule | 33 | endmodule |
The rewrite shown is what release 1.5.8 writes. It is byte for byte the file of the 1.5.5 run and the file that ran on the board.
Tool estimate (place-and-route timing model, not hardware)
| Run | Original | Rewrite | Ratio | Logic cells | Added latency |
|---|---|---|---|---|---|
| Release 1.5.5, 2026-11-21, 2 seeds | 76.1 MHz | 124.7 MHz | 1.64x | 309 to 314 | 1 |
| Development version, 2026-11-13, 10 seeds | 76.5 MHz | 118.2 MHz | 1.55x | 309 to 314 | 1 |
Measured on one FPGA board (highest clock that passed)
| Placements (seeds) | Original | Rewrite | Board ratio | Tool ratio on the same placements |
|---|---|---|---|---|
| 3 | 94.5 MHz | 102 MHz | 1.08x | 1.16x |
| 10 | 93 MHz | 102 MHz | 1.10x | 1.16x |
Checked by: simulation: the rewrite's output stream equals the original's, delayed by the added latency, under the sample's testbench; the synthesized netlist matches at gate level; and both designs were driven with the same random inputs (19,999 cycles). This is simulation, not a formal proof.
Reason, as far as it is established: inside the larger test circuit the tool's own estimate for the same placements was only 1.16x, and the board agreed with that. A further analysis made after the results were known (tool only, not run on the board) indicates that most of the loss comes from how the synthesis tool mapped the rewritten ALU once it was merged into the larger circuit. A gain estimated on a design alone may not survive inside the design that contains it. With the same seed numbers the rewrite was still higher in all 10 pairs, by 1.03x to 1.22x; over all 10 placements the two sets of results touch at 99 MHz.
4. CRC-32: no gain
no gain: keep the originalShow the original (crc32.v); there is no optimized version
| // CRC-32 (IEEE 802.3) of a byte stream, 8 bits per clock, written the straightforward way: a loop that updates the CRC bit by bit, all eight steps in ONE clock cycle (a long XOR chain between registers). module crc32 ( input clk, input rst, input valid, input [7:0] data, output reg [31:0] crc ); reg [31:0] c; integer i; always @* begin c = crc ^ {24'b0, data}; for (i = 0; i < 8; i = i + 1) c = c[0] ? (c >> 1) ^ 32'hEDB88320 : (c >> 1); end always @(posedge clk) begin if (rst) crc <= 32'hFFFFFFFF; else if (valid) crc <= c; end endmodule |
Tool estimate (release 1.5.5, 2026-11-21, 2 seeds)
| Row | Fmax | Logic cells |
|---|---|---|
| Original (baseline) | 294.6 MHz | 51 |
| Best other synthesis or place-and-route setting | 294.6 MHz (equal), the others slower | 51 or more |
| Source rewrite | none offered |
The recorded reasons: no sum of four or more terms to pipeline; no multiplication in the file. Release 1.5.8 gives the same two notes. The design was not run on the board.
5. SystemVerilog ALU on ECP5: measured but not counted
not counted: could not be checkedShow the original (alu_sv.sv); there is no optimized version
| // The same 8-bit ALU as hw_alu8, in SystemVerilog: package types, always_comb, always_ff, a unique case. module alu_sv import alu_pkg::*; ( input logic clk, input logic rst, input cmd_t cmd, output logic [15:0] y, output logic zero ); cmd_t c_r; logic [15:0] r; always_comb begin unique case (c_r.op) ADD: r = 16'(c_r.a) + 16'(c_r.b); SUB: r = 16'(c_r.a) - 16'(c_r.b); AND_: r = 16'(c_r.a & c_r.b); OR_: r = 16'(c_r.a | c_r.b); XOR_: r = 16'(c_r.a ^ c_r.b); SHL: r = 16'(c_r.a) << c_r.b[2:0]; MUL: r = 16'(c_r.a) * 16'(c_r.b); INC: r = 16'(c_r.a) + 16'(c_r.b) + 16'd1; endcase end always_ff @(posedge clk) begin if (rst) begin c_r <= '0; y <= '0; zero <= 1'b1; end else begin c_r <= cmd; y <= r; zero <= (r == 16'd0); end end endmodule |
Tool estimate (release 1.5.5, 2026-11-21, 2 seeds)
| Row | Fmax median | Logic cells | Verdict |
|---|---|---|---|
| Default synthesis (uses a hard multiplier block) | 88.8 MHz | 229 | unverified: measured, not counted |
| Without the hard multiplier block | 89.5 MHz | 441 | checked: becomes the reference |
The recorded reason: "measured but NOT counted: no check of the netlist could run. Gate-level simulation with the testbench: no simulation model for a block the netlist uses: 'MULT18X18D'." The random simulation could not build the netlist either. No source rewrite is offered for this file. Not run on the board.