Skip to content

Commit 51f99f6

Browse files
Merge pull request #24 from Minchan-Kwon/master
[Docs] Added Image Description of Benchmark Suite
2 parents 1041d08 + 37007a7 commit 51f99f6

File tree

11 files changed

+144
-68
lines changed

11 files changed

+144
-68
lines changed

auto_generated/README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Auto Generated Suite
2+
3+
This is a benchmark suite automatically generated to test a CAD tool's ability to parse Synopsys Design Constraints.
4+
It is a collection of all valid combinations of SDCs and their corresponding RTL files written in Verilog.
5+
The specific commands included in this benchmark are listed in the [syntax document](../docs/syntax/README.md).
6+
7+
![Syntax-Suite.png](./images/Syntax-Suite.png)
8+
9+
All of the SDCs in this suite have been generated using generate_sdc.py included in the repository.
10+
This Python script will exhaustively generate SDCs that fit the syntax description.
11+
We then pass the SDCs through OpenSTA to filter out any invalid SDCs that may have been generated.
12+
This suite is made up of the valid SDCs and the RTL files that go along with them in the CAD flow.
13+
47.4 KB
Loading
38.6 KB
Loading
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
/*
2+
Command: get_clocks
3+
Description:
4+
-Returns a list of clocks matching patterns
5+
6+
SDC Example:
7+
get_clocks clk1
8+
get_clocks -quiet clk1098
9+
*/
10+
11+
//Main module
12+
module get_clocks(
13+
input wire clk1,
14+
input wire clk2,
15+
input wire clk_gen,
16+
input wire clock,
17+
output reg dummy_out
18+
);
19+
initial dummy_out = 1'b1;
20+
21+
always @(posedge clk1 or posedge clk2 or posedge clk_gen or posedge clock) begin
22+
dummy_out <= ~dummy_out;
23+
end
24+
25+
endmodule
26+
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
/*
2+
Command: get_pins
3+
Description:
4+
-Returns a list of all instance pins matching patterns
5+
6+
SDC Example:
7+
get_pins -regexp u1/D
8+
get_pins u1/D
9+
*/
10+
11+
//Main module
12+
module get_pins(
13+
input wire clk,
14+
input wire data_in,
15+
output reg [1:0] data_out
16+
);
17+
wire u1_out, u2_out;
18+
19+
//Datapath
20+
DFF u1(.clk(clk), .D(data_in), .Q(u1_out));
21+
DFF u2(.clk(clk), .D(~data_in), .Q(u2_out));
22+
23+
assign data_out = {u1_out, u2_out};
24+
25+
endmodule
26+
27+
module DFF(
28+
input wire clk,
29+
input wire D,
30+
output reg Q
31+
);
32+
always @(posedge clk) begin
33+
Q <= D;
34+
end
35+
endmodule
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
/*
2+
Command: get_ports
3+
Description:
4+
-Returns a list of all top level ports that match patterns
5+
6+
SDC Example:
7+
get_ports data*
8+
get_ports -regexp rst
9+
*/
10+
11+
module get_ports(
12+
input wire clk,
13+
input wire rst,
14+
input wire data1_in,
15+
input wire data2_in,
16+
input wire valid_in,
17+
output reg result_out,
18+
output wire ready_out
19+
);
20+
//ready_out is always 1 for this simple module
21+
assign ready_out = 1'b1;
22+
23+
always @(posedge clk or posedge rst) begin
24+
if (rst) begin
25+
result_out <= 1'b0;
26+
end
27+
else if (valid_in) begin
28+
result_out <= data1_in + data2_in;
29+
end
30+
end
31+
32+
endmodule
157 KB
Loading

docs/images/Syntax-Suite.png

47.4 KB
Loading

docs/images/Timing-Suite.png

38.6 KB
Loading

docs/syntax/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# SDC Syntax
22

3+
![SDC_Syntax.png](./docs/images/Synopsys-Design-Constraints.png)
4+
35
## Timing Constraints
46

57
### create_clock

0 commit comments

Comments
 (0)