-
Notifications
You must be signed in to change notification settings - Fork 302
/
verif.fir
55 lines (43 loc) · 1.17 KB
/
verif.fir
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
49
50
51
52
53
54
; RUN: firtool %s | FileCheck %s
circuit Foo:
intmodule LTLDelay:
input in: UInt<1>
output out: UInt<1>
intrinsic = circt_ltl_delay
parameter delay = 1
parameter length = 0
intmodule LTLConcat:
input lhs: UInt<1>
input rhs: UInt<1>
output out: UInt<1>
intrinsic = circt_ltl_concat
intmodule LTLImplication:
input lhs: UInt<1>
input rhs: UInt<1>
output out: UInt<1>
intrinsic = circt_ltl_implication
intmodule LTLEventually:
input in: UInt<1>
output out: UInt<1>
intrinsic = circt_ltl_eventually
intmodule VerifAssert:
input property: UInt<1>
intrinsic = circt_verif_assert
parameter label = "hello"
module Foo:
input clk: Clock
input a: UInt<1>
input b: UInt<1>
inst delay of LTLDelay
delay.in <= b
inst concat of LTLConcat
concat.lhs <= a
concat.rhs <= delay.out
inst implication of LTLImplication
implication.lhs <= a
implication.rhs <= concat.out
inst eventually of LTLEventually
eventually.in <= implication.out
; CHECK: hello: assert property (s_eventually a |-> a ##1 b);
inst assert of VerifAssert
assert.property <= eventually.out