summaryrefslogtreecommitdiff
path: root/tests/liberty/semicolextra.lib
blob: 6a7fa77cc96b1f3b76d47ad1dbb33ebebfff829e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
/*

	Test case for https://www.reddit.com/r/yosys/comments/b5texg/yosys_fails_to_parse_apparentlycorrect_liberty/

	fall_constraint (SETUP_HOLD) formatting.

*/

library(supergate) {
  technology (cmos);
  revision : 1.0;

    cell (DFF) {
        cell_footprint : dff;
        area : 50;
        pin(D) {
            direction : input;
            capacitance : 0.002;
            timing() {
                related_pin : "CK";
                timing_type : setup_rising;

                fall_constraint (SETUP_HOLD) { values ("0.4000, 0.3000, 0.2000, 0.1000, 0.0000", \
                    "0.4000, 0.3000, 0.2000, 0.1000, 0.000", \
                    "0.5000, 0.4000, 0.3000, 0.2000, 0.0000", \
                    "0.7000, 0.6000, 0.5000, 0.4000, 0.2000", \
                    "1.0000, 1.0000, 0.9000, 0.8000, 0.6000"); };
            }
        }	

        pin(CK) {
            direction : input;
            clock : true;
            capacitance : 0.00290;
        }

        ff(IQ,IQN) {
            clocked_on : "CK";
            next_state : "D";
        }
        pin(Q) {
            direction : output;
            capacitance : 0.003;
            max_capacitance : 0.3;
        }
        cell_leakage_power : 0.3;
    }
}