Add new benchmark and modify go.sh to use it
This commit is contained in:
parent
c506e16d33
commit
7ff245448b
|
@ -0,0 +1,40 @@
|
|||
clk 0.511800 0.202800
|
||||
rst 0.00001 0.198000
|
||||
a0 0.465000 0.196200
|
||||
a1 0.476000 0.196200
|
||||
a2 0.480800 0.203200
|
||||
a3 0.523200 0.203400
|
||||
b0 0.502800 0.211200
|
||||
b1 0.479200 0.208400
|
||||
b2 0.495200 0.197000
|
||||
b3 0.521000 0.204800
|
||||
cin 0.490400 0.194600
|
||||
reg_b[3] 0.250800 0.189200
|
||||
reg_cin 0.241600 0.168200
|
||||
cout 0.197600 0.171000
|
||||
sumout0 0.197400 0.197200
|
||||
sumout1 0.195200 0.205800
|
||||
sumout2 0.202000 0.213000
|
||||
sumout3 0.191600 0.207600
|
||||
reg_a[0] 0.229800 0.171000
|
||||
reg_a[1] 0.236000 0.170200
|
||||
reg_a[2] 0.230000 0.174400
|
||||
reg_a[3] 0.258400 0.179800
|
||||
reg_b[0] 0.250600 0.180400
|
||||
reg_b[1] 0.238600 0.177800
|
||||
reg_b[2] 0.248000 0.177400
|
||||
n83 0.250600 0.044471
|
||||
n88 0.238600 0.047498
|
||||
n93 0.248000 0.044135
|
||||
n33 0.250800 0.041399
|
||||
n38 0.241600 0.044556
|
||||
n43 0.197600 0.011311
|
||||
n67 0.767600 0.013393
|
||||
n47 0.197400 0.040388
|
||||
n51 0.195200 0.019975
|
||||
n55 0.202000 0.042318
|
||||
n59 0.191600 0.007901
|
||||
n63 0.229800 0.048269
|
||||
n68 0.236000 0.046714
|
||||
n73 0.230000 0.046748
|
||||
n78 0.258400 0.040977
|
|
@ -0,0 +1,91 @@
|
|||
# Benchmark "sync_4bits_add" written by ABC on Sat Dec 22 05:55:54 2018
|
||||
.model sync_4bits_add
|
||||
.inputs clk rst a0 a1 a2 a3 b0 b1 b2 b3 cin
|
||||
.outputs sumout0 sumout1 sumout2 sumout3 cout
|
||||
|
||||
.latch n33 reg_b[3] re clk 0
|
||||
.latch n38 reg_cin re clk 0
|
||||
.latch n43 cout re clk 0
|
||||
.latch n47 sumout0 re clk 0
|
||||
.latch n51 sumout1 re clk 0
|
||||
.latch n55 sumout2 re clk 0
|
||||
.latch n59 sumout3 re clk 0
|
||||
.latch n63 reg_a[0] re clk 0
|
||||
.latch n68 reg_a[1] re clk 0
|
||||
.latch n73 reg_a[2] re clk 0
|
||||
.latch n78 reg_a[3] re clk 0
|
||||
.latch n83 reg_b[0] re clk 0
|
||||
.latch n88 reg_b[1] re clk 0
|
||||
.latch n93 reg_b[2] re clk 0
|
||||
|
||||
.names b0 rst n83
|
||||
10 1
|
||||
.names b1 rst n88
|
||||
10 1
|
||||
.names b2 rst n93
|
||||
10 1
|
||||
.names b3 rst n33
|
||||
10 1
|
||||
.names cin rst n38
|
||||
10 1
|
||||
.names rst reg_b[2] reg_a[2] reg_b[3] reg_a[3] n67 n43
|
||||
0111-- 1
|
||||
011-1- 1
|
||||
01-1-0 1
|
||||
01--10 1
|
||||
0-11-0 1
|
||||
0-1-10 1
|
||||
0--11- 1
|
||||
.names reg_b[1] reg_cin reg_b[0] reg_a[0] reg_a[1] n67
|
||||
000-- 1
|
||||
00-0- 1
|
||||
0-00- 1
|
||||
0---0 1
|
||||
-00-0 1
|
||||
-0-00 1
|
||||
--000 1
|
||||
.names reg_cin reg_b[0] reg_a[0] rst n47
|
||||
0010 1
|
||||
0100 1
|
||||
1000 1
|
||||
1110 1
|
||||
.names reg_b[1] reg_a[1] rst reg_cin reg_b[0] reg_a[0] n51
|
||||
00011- 1
|
||||
0001-1 1
|
||||
000-11 1
|
||||
01000- 1
|
||||
0100-0 1
|
||||
010-00 1
|
||||
10000- 1
|
||||
1000-0 1
|
||||
100-00 1
|
||||
11011- 1
|
||||
1101-1 1
|
||||
110-11 1
|
||||
.names reg_b[2] reg_a[2] n67 rst n55
|
||||
0000 1
|
||||
0110 1
|
||||
1010 1
|
||||
1100 1
|
||||
.names reg_b[3] reg_a[3] rst reg_b[2] reg_a[2] n67 n59
|
||||
00011- 1
|
||||
0001-0 1
|
||||
000-10 1
|
||||
01000- 1
|
||||
0100-1 1
|
||||
010-01 1
|
||||
10000- 1
|
||||
1000-1 1
|
||||
100-01 1
|
||||
11011- 1
|
||||
1101-0 1
|
||||
110-10 1
|
||||
.names a0 rst n63
|
||||
10 1
|
||||
.names a1 rst n68
|
||||
10 1
|
||||
.names a2 rst n73
|
||||
10 1
|
||||
.names a3 rst n78
|
||||
10 1
|
||||
.end
|
|
@ -0,0 +1,90 @@
|
|||
////////////////////////////////////////
|
||||
// //
|
||||
// Synchronized adder benchmark //
|
||||
// //
|
||||
////////////////////////////////////////
|
||||
|
||||
module sync_4bits_add(
|
||||
clk,
|
||||
rst,
|
||||
a0,
|
||||
a1,
|
||||
a2,
|
||||
a3,
|
||||
b0,
|
||||
b1,
|
||||
b2,
|
||||
b3,
|
||||
cin,
|
||||
sumout0,
|
||||
sumout1,
|
||||
sumout2,
|
||||
sumout3,
|
||||
cout);
|
||||
|
||||
input clk;
|
||||
input rst;
|
||||
input a0;
|
||||
input a1;
|
||||
input a2;
|
||||
input a3;
|
||||
input b0;
|
||||
input b1;
|
||||
input b2;
|
||||
input b3;
|
||||
input cin;
|
||||
output sumout0;
|
||||
output sumout1;
|
||||
output sumout2;
|
||||
output sumout3;
|
||||
output reg cout;
|
||||
|
||||
wire[3:0] a;
|
||||
wire[3:0] b;
|
||||
reg[3:0] sumout;
|
||||
|
||||
reg[3:0] reg_a;
|
||||
reg[3:0] reg_b;
|
||||
reg reg_cin;
|
||||
wire[4:0] int_sum;
|
||||
|
||||
assign a[3] = a3;
|
||||
assign a[2] = a2;
|
||||
assign a[1] = a1;
|
||||
assign a[0] = a0;
|
||||
assign b[3] = b3;
|
||||
assign b[2] = b2;
|
||||
assign b[1] = b1;
|
||||
assign b[0] = b0;
|
||||
assign sumout3 = sumout[3];
|
||||
assign sumout2 = sumout[2];
|
||||
assign sumout1 = sumout[1];
|
||||
assign sumout0 = sumout[0];
|
||||
|
||||
assign int_sum = reg_a + reg_b + reg_cin;
|
||||
|
||||
always@(posedge clk or posedge rst) begin
|
||||
if(rst) begin
|
||||
reg_a <= 4'h0;
|
||||
reg_b <= 4'h0;
|
||||
reg_cin <= 1'h0;
|
||||
end
|
||||
else begin
|
||||
reg_a <= a;
|
||||
reg_b <= b;
|
||||
reg_cin <= cin;
|
||||
end
|
||||
end
|
||||
|
||||
always@(posedge clk or posedge rst) begin
|
||||
if(rst) begin
|
||||
sumout <= 4'h0;
|
||||
cout <= 1'h0;
|
||||
end
|
||||
else begin
|
||||
sumout <= int_sum[3:0];
|
||||
cout <= int_sum[4];
|
||||
end
|
||||
end
|
||||
|
||||
endmodule
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/sh
|
||||
# Example of how to run vprset circuit_name = pip_add
|
||||
#set circuit_name = pip_add
|
||||
set circuit_name = fifo_1bit
|
||||
set circuit_name = sync_4bits_add
|
||||
set arch_file = ${PWD}/ARCH/k6_N10_scan_chain_tsmc40nm_TT.xml
|
||||
set circuit_blif = ${PWD}/Circuits/${circuit_name}.blif
|
||||
set circuit_act = ${PWD}/Circuits/${circuit_name}.act
|
||||
|
|
Loading…
Reference in New Issue