Line Coverage for Module :
prim_pulse_sync
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Module :
prim_pulse_sync
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Module :
prim_pulse_sync
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Module :
prim_pulse_sync
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
1498976793 |
529663 |
0 |
0 |
T1 |
106913 |
100 |
0 |
0 |
T2 |
973978 |
452 |
0 |
0 |
T3 |
889950 |
922 |
0 |
0 |
T9 |
0 |
583 |
0 |
0 |
T10 |
0 |
374 |
0 |
0 |
T11 |
0 |
130 |
0 |
0 |
T12 |
0 |
400 |
0 |
0 |
T19 |
162775 |
0 |
0 |
0 |
T20 |
12886 |
0 |
0 |
0 |
T21 |
8114 |
0 |
0 |
0 |
T22 |
14340 |
0 |
0 |
0 |
T23 |
4345 |
0 |
0 |
0 |
T24 |
24506 |
0 |
0 |
0 |
T25 |
3258 |
0 |
0 |
0 |
T26 |
7811 |
0 |
0 |
0 |
T36 |
0 |
574 |
0 |
0 |
T37 |
0 |
196 |
0 |
0 |
T38 |
0 |
80 |
0 |
0 |
T39 |
0 |
456 |
0 |
0 |
T40 |
0 |
48 |
0 |
0 |
T41 |
0 |
744 |
0 |
0 |
T42 |
2914 |
0 |
0 |
0 |
T43 |
7928 |
0 |
0 |
0 |
T44 |
5011 |
0 |
0 |
0 |
T62 |
10370 |
1 |
0 |
0 |
T64 |
8460 |
1 |
0 |
0 |
T68 |
7223 |
1 |
0 |
0 |
T69 |
6501 |
1 |
0 |
0 |
T127 |
11930 |
1 |
0 |
0 |
T128 |
8205 |
2 |
0 |
0 |
T129 |
16122 |
1 |
0 |
0 |
T130 |
0 |
1 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
1317446610 |
525633 |
0 |
0 |
T1 |
158488 |
100 |
0 |
0 |
T2 |
346283 |
452 |
0 |
0 |
T3 |
542627 |
922 |
0 |
0 |
T9 |
0 |
583 |
0 |
0 |
T10 |
0 |
374 |
0 |
0 |
T11 |
0 |
130 |
0 |
0 |
T12 |
0 |
400 |
0 |
0 |
T19 |
69206 |
0 |
0 |
0 |
T20 |
5360 |
0 |
0 |
0 |
T21 |
3724 |
0 |
0 |
0 |
T22 |
4590 |
0 |
0 |
0 |
T23 |
460 |
0 |
0 |
0 |
T24 |
2508 |
0 |
0 |
0 |
T25 |
348 |
0 |
0 |
0 |
T26 |
804 |
0 |
0 |
0 |
T36 |
0 |
574 |
0 |
0 |
T37 |
0 |
196 |
0 |
0 |
T38 |
0 |
80 |
0 |
0 |
T39 |
0 |
456 |
0 |
0 |
T40 |
0 |
48 |
0 |
0 |
T41 |
0 |
744 |
0 |
0 |
T42 |
2954 |
0 |
0 |
0 |
T43 |
6424 |
0 |
0 |
0 |
T44 |
5099 |
0 |
0 |
0 |
T62 |
4362 |
1 |
0 |
0 |
T64 |
3675 |
1 |
0 |
0 |
T68 |
5565 |
1 |
0 |
0 |
T69 |
3001 |
1 |
0 |
0 |
T127 |
11180 |
1 |
0 |
0 |
T128 |
14764 |
2 |
0 |
0 |
T129 |
6886 |
1 |
0 |
0 |
T130 |
0 |
1 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_en_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_en_cdc.u_src_to_dst_req
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_en_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_en_cdc.u_src_to_dst_req
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
90664409 |
13298 |
0 |
0 |
T1 |
67219 |
20 |
0 |
0 |
T2 |
226443 |
40 |
0 |
0 |
T3 |
163030 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
26 |
0 |
0 |
T19 |
41459 |
0 |
0 |
0 |
T20 |
2974 |
0 |
0 |
0 |
T21 |
1953 |
0 |
0 |
0 |
T22 |
3606 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
16 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
1954 |
0 |
0 |
0 |
T43 |
5621 |
0 |
0 |
0 |
T44 |
3321 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
13298 |
0 |
0 |
T1 |
70021 |
20 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
26 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
16 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_cdc.u_src_to_dst_req
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
90664409 |
18745 |
0 |
0 |
T1 |
67219 |
40 |
0 |
0 |
T2 |
226443 |
40 |
0 |
0 |
T3 |
163030 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
41459 |
0 |
0 |
0 |
T20 |
2974 |
0 |
0 |
0 |
T21 |
1953 |
0 |
0 |
0 |
T22 |
3606 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
1954 |
0 |
0 |
0 |
T43 |
5621 |
0 |
0 |
0 |
T44 |
3321 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
18758 |
0 |
0 |
T1 |
70021 |
40 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
18740 |
0 |
0 |
T1 |
70021 |
40 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
90664409 |
18748 |
0 |
0 |
T1 |
67219 |
40 |
0 |
0 |
T2 |
226443 |
40 |
0 |
0 |
T3 |
163030 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
41459 |
0 |
0 |
0 |
T20 |
2974 |
0 |
0 |
0 |
T21 |
1953 |
0 |
0 |
0 |
T22 |
3606 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
1954 |
0 |
0 |
0 |
T43 |
5621 |
0 |
0 |
0 |
T44 |
3321 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_en_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_en_cdc.u_src_to_dst_req
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_en_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_en_cdc.u_src_to_dst_req
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
44445125 |
13298 |
0 |
0 |
T1 |
18446 |
20 |
0 |
0 |
T2 |
113161 |
40 |
0 |
0 |
T3 |
81503 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
26 |
0 |
0 |
T19 |
16524 |
0 |
0 |
0 |
T20 |
1522 |
0 |
0 |
0 |
T21 |
916 |
0 |
0 |
0 |
T22 |
1736 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
16 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
958 |
0 |
0 |
0 |
T43 |
3144 |
0 |
0 |
0 |
T44 |
1641 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
13298 |
0 |
0 |
T1 |
70021 |
20 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
26 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
16 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_cdc.u_src_to_dst_req
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
44445125 |
18716 |
0 |
0 |
T1 |
18446 |
40 |
0 |
0 |
T2 |
113161 |
40 |
0 |
0 |
T3 |
81503 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
16524 |
0 |
0 |
0 |
T20 |
1522 |
0 |
0 |
0 |
T21 |
916 |
0 |
0 |
0 |
T22 |
1736 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
958 |
0 |
0 |
0 |
T43 |
3144 |
0 |
0 |
0 |
T44 |
1641 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
18740 |
0 |
0 |
T1 |
70021 |
40 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
18705 |
0 |
0 |
T1 |
70021 |
40 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
44445125 |
18718 |
0 |
0 |
T1 |
18446 |
40 |
0 |
0 |
T2 |
113161 |
40 |
0 |
0 |
T3 |
81503 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
16524 |
0 |
0 |
0 |
T20 |
1522 |
0 |
0 |
0 |
T21 |
916 |
0 |
0 |
0 |
T22 |
1736 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
958 |
0 |
0 |
0 |
T43 |
3144 |
0 |
0 |
0 |
T44 |
1641 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_en_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_en_cdc.u_src_to_dst_req
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_en_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_en_cdc.u_src_to_dst_req
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
22222096 |
13298 |
0 |
0 |
T1 |
9223 |
20 |
0 |
0 |
T2 |
56581 |
40 |
0 |
0 |
T3 |
40751 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
26 |
0 |
0 |
T19 |
8260 |
0 |
0 |
0 |
T20 |
760 |
0 |
0 |
0 |
T21 |
458 |
0 |
0 |
0 |
T22 |
868 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
16 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
479 |
0 |
0 |
0 |
T43 |
1571 |
0 |
0 |
0 |
T44 |
821 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
13298 |
0 |
0 |
T1 |
70021 |
20 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
26 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
16 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_cdc.u_src_to_dst_req
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
22222096 |
18706 |
0 |
0 |
T1 |
9223 |
40 |
0 |
0 |
T2 |
56581 |
40 |
0 |
0 |
T3 |
40751 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
8260 |
0 |
0 |
0 |
T20 |
760 |
0 |
0 |
0 |
T21 |
458 |
0 |
0 |
0 |
T22 |
868 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
479 |
0 |
0 |
0 |
T43 |
1571 |
0 |
0 |
0 |
T44 |
821 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
18745 |
0 |
0 |
T1 |
70021 |
40 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
18706 |
0 |
0 |
T1 |
70021 |
40 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
22222096 |
18710 |
0 |
0 |
T1 |
9223 |
40 |
0 |
0 |
T2 |
56581 |
40 |
0 |
0 |
T3 |
40751 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
8260 |
0 |
0 |
0 |
T20 |
760 |
0 |
0 |
0 |
T21 |
458 |
0 |
0 |
0 |
T22 |
868 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
479 |
0 |
0 |
0 |
T43 |
1571 |
0 |
0 |
0 |
T44 |
821 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_en_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_en_cdc.u_src_to_dst_req
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_en_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_en_cdc.u_src_to_dst_req
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
100614428 |
13298 |
0 |
0 |
T1 |
70021 |
20 |
0 |
0 |
T2 |
235886 |
40 |
0 |
0 |
T3 |
211830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
26 |
0 |
0 |
T19 |
43187 |
0 |
0 |
0 |
T20 |
3099 |
0 |
0 |
0 |
T21 |
1857 |
0 |
0 |
0 |
T22 |
3757 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
16 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
2036 |
0 |
0 |
0 |
T43 |
5855 |
0 |
0 |
0 |
T44 |
3459 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
13298 |
0 |
0 |
T1 |
70021 |
20 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
26 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
16 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_cdc.u_src_to_dst_req
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
100614428 |
18648 |
0 |
0 |
T1 |
70021 |
40 |
0 |
0 |
T2 |
235886 |
40 |
0 |
0 |
T3 |
211830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
43187 |
0 |
0 |
0 |
T20 |
3099 |
0 |
0 |
0 |
T21 |
1857 |
0 |
0 |
0 |
T22 |
3757 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
2036 |
0 |
0 |
0 |
T43 |
5855 |
0 |
0 |
0 |
T44 |
3459 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
18667 |
0 |
0 |
T1 |
70021 |
40 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
18635 |
0 |
0 |
T1 |
70021 |
40 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
100614428 |
18651 |
0 |
0 |
T1 |
70021 |
40 |
0 |
0 |
T2 |
235886 |
40 |
0 |
0 |
T3 |
211830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
43187 |
0 |
0 |
0 |
T20 |
3099 |
0 |
0 |
0 |
T21 |
1857 |
0 |
0 |
0 |
T22 |
3757 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
2036 |
0 |
0 |
0 |
T43 |
5855 |
0 |
0 |
0 |
T44 |
3459 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_en_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_en_cdc.u_src_to_dst_req
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T2,T3,T36 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_en_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_en_cdc.u_src_to_dst_req
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
48251280 |
12880 |
0 |
0 |
T1 |
33611 |
10 |
0 |
0 |
T2 |
113227 |
40 |
0 |
0 |
T3 |
101680 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
13 |
0 |
0 |
T19 |
20730 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
922 |
0 |
0 |
0 |
T22 |
1803 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
8 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
978 |
0 |
0 |
0 |
T43 |
2811 |
0 |
0 |
0 |
T44 |
1660 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
13298 |
0 |
0 |
T1 |
70021 |
20 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
26 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
16 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_cdc.u_src_to_dst_req
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_cdc.u_src_to_dst_req
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
48251280 |
18614 |
0 |
0 |
T1 |
33611 |
30 |
0 |
0 |
T2 |
113227 |
40 |
0 |
0 |
T3 |
101680 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
44 |
0 |
0 |
T19 |
20730 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
922 |
0 |
0 |
0 |
T22 |
1803 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
24 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
978 |
0 |
0 |
0 |
T43 |
2811 |
0 |
0 |
0 |
T44 |
1660 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
18799 |
0 |
0 |
T1 |
70021 |
40 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
52 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
32 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T1 T2 T3
Cond Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T1,T2,T3 |
1 | 0 | Covered | T1,T2,T3 |
1 | 1 | Covered | T1,T2,T3 |
Branch Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_cdc.u_arb.gen_passthru.u_dst_to_src_ack
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
18469 |
0 |
0 |
T1 |
70021 |
30 |
0 |
0 |
T2 |
115585 |
40 |
0 |
0 |
T3 |
229830 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
42 |
0 |
0 |
T19 |
20297 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
1098 |
0 |
0 |
0 |
T22 |
901 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
24 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
998 |
0 |
0 |
0 |
T43 |
1640 |
0 |
0 |
0 |
T44 |
1729 |
0 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
48251280 |
18654 |
0 |
0 |
T1 |
33611 |
30 |
0 |
0 |
T2 |
113227 |
40 |
0 |
0 |
T3 |
101680 |
38 |
0 |
0 |
T9 |
0 |
38 |
0 |
0 |
T10 |
0 |
26 |
0 |
0 |
T11 |
0 |
46 |
0 |
0 |
T19 |
20730 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
922 |
0 |
0 |
0 |
T22 |
1803 |
0 |
0 |
0 |
T36 |
0 |
22 |
0 |
0 |
T37 |
0 |
8 |
0 |
0 |
T38 |
0 |
29 |
0 |
0 |
T39 |
0 |
20 |
0 |
0 |
T42 |
978 |
0 |
0 |
0 |
T43 |
2811 |
0 |
0 |
0 |
T44 |
1660 |
0 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_hi_err_update_sync
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T63 T64 T65
Cond Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_hi_err_update_sync
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T63,T64,T65 |
1 | 0 | Covered | T63,T64,T65 |
1 | 1 | Covered | T67,T130,T131 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T63,T64,T65 |
1 | 0 | Covered | T67,T130,T131 |
1 | 1 | Covered | T63,T64,T65 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_hi_err_update_sync
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_hi_err_update_sync
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
40 |
0 |
0 |
T63 |
9780 |
1 |
0 |
0 |
T64 |
8460 |
1 |
0 |
0 |
T65 |
6018 |
1 |
0 |
0 |
T66 |
4577 |
1 |
0 |
0 |
T67 |
3943 |
2 |
0 |
0 |
T68 |
7223 |
1 |
0 |
0 |
T127 |
11930 |
1 |
0 |
0 |
T128 |
8205 |
2 |
0 |
0 |
T129 |
16122 |
1 |
0 |
0 |
T130 |
6784 |
2 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
90664409 |
40 |
0 |
0 |
T63 |
9579 |
1 |
0 |
0 |
T64 |
8460 |
1 |
0 |
0 |
T65 |
24074 |
1 |
0 |
0 |
T66 |
5424 |
1 |
0 |
0 |
T67 |
8228 |
2 |
0 |
0 |
T68 |
12840 |
1 |
0 |
0 |
T127 |
23859 |
1 |
0 |
0 |
T128 |
31506 |
2 |
0 |
0 |
T129 |
15476 |
1 |
0 |
0 |
T130 |
43418 |
2 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_lo_err_update_sync
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T63 T67 T66
Cond Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_lo_err_update_sync
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T63,T67,T66 |
1 | 0 | Covered | T63,T67,T66 |
1 | 1 | Covered | T67,T130,T131 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T63,T67,T66 |
1 | 0 | Covered | T67,T130,T131 |
1 | 1 | Covered | T63,T67,T66 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_lo_err_update_sync
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_meas_ctrl_shadowed_lo_err_update_sync
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
40 |
0 |
0 |
T63 |
9780 |
1 |
0 |
0 |
T66 |
4577 |
1 |
0 |
0 |
T67 |
3943 |
2 |
0 |
0 |
T68 |
7223 |
1 |
0 |
0 |
T69 |
6501 |
1 |
0 |
0 |
T128 |
8205 |
2 |
0 |
0 |
T129 |
16122 |
1 |
0 |
0 |
T130 |
6784 |
3 |
0 |
0 |
T131 |
6441 |
2 |
0 |
0 |
T132 |
10603 |
3 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
90664409 |
40 |
0 |
0 |
T63 |
9579 |
1 |
0 |
0 |
T66 |
5424 |
1 |
0 |
0 |
T67 |
8228 |
2 |
0 |
0 |
T68 |
12840 |
1 |
0 |
0 |
T69 |
6568 |
1 |
0 |
0 |
T128 |
31506 |
2 |
0 |
0 |
T129 |
15476 |
1 |
0 |
0 |
T130 |
43418 |
3 |
0 |
0 |
T131 |
56212 |
2 |
0 |
0 |
T132 |
11436 |
3 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_hi_err_update_sync
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T62 T64 T68
Cond Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_hi_err_update_sync
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T64,T68 |
1 | 0 | Covered | T62,T64,T68 |
1 | 1 | Covered | T128,T133,T134 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T64,T68 |
1 | 0 | Covered | T128,T133,T134 |
1 | 1 | Covered | T62,T64,T68 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_hi_err_update_sync
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_hi_err_update_sync
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
29 |
0 |
0 |
T62 |
10370 |
1 |
0 |
0 |
T64 |
8460 |
1 |
0 |
0 |
T68 |
7223 |
1 |
0 |
0 |
T69 |
6501 |
1 |
0 |
0 |
T127 |
11930 |
1 |
0 |
0 |
T128 |
8205 |
2 |
0 |
0 |
T129 |
16122 |
1 |
0 |
0 |
T130 |
6784 |
1 |
0 |
0 |
T131 |
6441 |
1 |
0 |
0 |
T135 |
8771 |
1 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
44445125 |
29 |
0 |
0 |
T62 |
4362 |
1 |
0 |
0 |
T64 |
3675 |
1 |
0 |
0 |
T68 |
5565 |
1 |
0 |
0 |
T69 |
3001 |
1 |
0 |
0 |
T127 |
11180 |
1 |
0 |
0 |
T128 |
14764 |
2 |
0 |
0 |
T129 |
6886 |
1 |
0 |
0 |
T130 |
20938 |
1 |
0 |
0 |
T131 |
27358 |
1 |
0 |
0 |
T135 |
3765 |
1 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_lo_err_update_sync
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T62 T63 T64
Cond Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_lo_err_update_sync
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T63,T64 |
1 | 0 | Covered | T62,T63,T64 |
1 | 1 | Covered | T134 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T63,T64 |
1 | 0 | Covered | T134 |
1 | 1 | Covered | T62,T63,T64 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_lo_err_update_sync
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_div2_meas_ctrl_shadowed_lo_err_update_sync
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
27 |
0 |
0 |
T62 |
10370 |
1 |
0 |
0 |
T63 |
9780 |
2 |
0 |
0 |
T64 |
8460 |
1 |
0 |
0 |
T67 |
3943 |
1 |
0 |
0 |
T68 |
7223 |
1 |
0 |
0 |
T69 |
6501 |
1 |
0 |
0 |
T128 |
8205 |
2 |
0 |
0 |
T129 |
16122 |
1 |
0 |
0 |
T130 |
6784 |
1 |
0 |
0 |
T135 |
8771 |
1 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
44445125 |
27 |
0 |
0 |
T62 |
4362 |
1 |
0 |
0 |
T63 |
4075 |
2 |
0 |
0 |
T64 |
3675 |
1 |
0 |
0 |
T67 |
3611 |
1 |
0 |
0 |
T68 |
5565 |
1 |
0 |
0 |
T69 |
3001 |
1 |
0 |
0 |
T128 |
14764 |
2 |
0 |
0 |
T129 |
6886 |
1 |
0 |
0 |
T130 |
20938 |
1 |
0 |
0 |
T135 |
3765 |
1 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_hi_err_update_sync
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T62 T63 T65
Cond Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_hi_err_update_sync
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T63,T65 |
1 | 0 | Covered | T62,T63,T65 |
1 | 1 | Covered | T66,T69,T130 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T63,T65 |
1 | 0 | Covered | T66,T69,T130 |
1 | 1 | Covered | T62,T63,T65 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_hi_err_update_sync
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_hi_err_update_sync
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
41 |
0 |
0 |
T62 |
10370 |
3 |
0 |
0 |
T63 |
9780 |
2 |
0 |
0 |
T65 |
6018 |
1 |
0 |
0 |
T66 |
4577 |
3 |
0 |
0 |
T68 |
7223 |
1 |
0 |
0 |
T69 |
6501 |
2 |
0 |
0 |
T127 |
11930 |
2 |
0 |
0 |
T130 |
6784 |
3 |
0 |
0 |
T131 |
6441 |
3 |
0 |
0 |
T136 |
3803 |
1 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
22222096 |
41 |
0 |
0 |
T62 |
2181 |
3 |
0 |
0 |
T63 |
2035 |
2 |
0 |
0 |
T65 |
5864 |
1 |
0 |
0 |
T66 |
1193 |
3 |
0 |
0 |
T68 |
2785 |
1 |
0 |
0 |
T69 |
1501 |
2 |
0 |
0 |
T127 |
5587 |
2 |
0 |
0 |
T130 |
10472 |
3 |
0 |
0 |
T131 |
13677 |
3 |
0 |
0 |
T136 |
3620 |
1 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_lo_err_update_sync
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T62 T63 T65
Cond Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_lo_err_update_sync
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T63,T65 |
1 | 0 | Covered | T62,T63,T65 |
1 | 1 | Covered | T69,T136,T130 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T63,T65 |
1 | 0 | Covered | T69,T136,T130 |
1 | 1 | Covered | T62,T63,T65 |
Branch Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_lo_err_update_sync
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_io_div4_meas_ctrl_shadowed_lo_err_update_sync
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
38 |
0 |
0 |
T62 |
10370 |
3 |
0 |
0 |
T63 |
9780 |
1 |
0 |
0 |
T65 |
6018 |
1 |
0 |
0 |
T66 |
4577 |
1 |
0 |
0 |
T68 |
7223 |
1 |
0 |
0 |
T69 |
6501 |
2 |
0 |
0 |
T127 |
11930 |
2 |
0 |
0 |
T130 |
6784 |
4 |
0 |
0 |
T136 |
3803 |
2 |
0 |
0 |
T137 |
9761 |
1 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
22222096 |
38 |
0 |
0 |
T62 |
2181 |
3 |
0 |
0 |
T63 |
2035 |
1 |
0 |
0 |
T65 |
5864 |
1 |
0 |
0 |
T66 |
1193 |
1 |
0 |
0 |
T68 |
2785 |
1 |
0 |
0 |
T69 |
1501 |
2 |
0 |
0 |
T127 |
5587 |
2 |
0 |
0 |
T130 |
10472 |
4 |
0 |
0 |
T136 |
3620 |
2 |
0 |
0 |
T137 |
9440 |
1 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_hi_err_update_sync
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T62 T64 T65
Cond Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_hi_err_update_sync
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T64,T65 |
1 | 0 | Covered | T62,T64,T65 |
1 | 1 | Covered | T66,T69,T137 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T64,T65 |
1 | 0 | Covered | T66,T69,T137 |
1 | 1 | Covered | T62,T64,T65 |
Branch Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_hi_err_update_sync
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_hi_err_update_sync
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
38 |
0 |
0 |
T62 |
10370 |
1 |
0 |
0 |
T64 |
8460 |
2 |
0 |
0 |
T65 |
6018 |
1 |
0 |
0 |
T66 |
4577 |
3 |
0 |
0 |
T69 |
6501 |
2 |
0 |
0 |
T70 |
7079 |
1 |
0 |
0 |
T127 |
11930 |
2 |
0 |
0 |
T136 |
3803 |
1 |
0 |
0 |
T137 |
9761 |
2 |
0 |
0 |
T138 |
3945 |
1 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
100614428 |
38 |
0 |
0 |
T62 |
10916 |
1 |
0 |
0 |
T64 |
8813 |
2 |
0 |
0 |
T65 |
25078 |
1 |
0 |
0 |
T66 |
5650 |
3 |
0 |
0 |
T69 |
6842 |
2 |
0 |
0 |
T70 |
13614 |
1 |
0 |
0 |
T127 |
24854 |
2 |
0 |
0 |
T136 |
15848 |
1 |
0 |
0 |
T137 |
40674 |
2 |
0 |
0 |
T138 |
15783 |
1 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_lo_err_update_sync
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T64 T65 T70
Cond Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_lo_err_update_sync
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T64,T65,T70 |
1 | 0 | Covered | T64,T65,T70 |
1 | 1 | Covered | T129 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T64,T65,T70 |
1 | 0 | Covered | T129 |
1 | 1 | Covered | T64,T65,T70 |
Branch Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_lo_err_update_sync
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_main_meas_ctrl_shadowed_lo_err_update_sync
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
30 |
0 |
0 |
T64 |
8460 |
2 |
0 |
0 |
T65 |
6018 |
1 |
0 |
0 |
T66 |
4577 |
2 |
0 |
0 |
T68 |
7223 |
1 |
0 |
0 |
T70 |
7079 |
1 |
0 |
0 |
T127 |
11930 |
3 |
0 |
0 |
T128 |
8205 |
2 |
0 |
0 |
T129 |
16122 |
3 |
0 |
0 |
T135 |
8771 |
1 |
0 |
0 |
T136 |
3803 |
1 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
100614428 |
30 |
0 |
0 |
T64 |
8813 |
2 |
0 |
0 |
T65 |
25078 |
1 |
0 |
0 |
T66 |
5650 |
2 |
0 |
0 |
T68 |
13375 |
1 |
0 |
0 |
T70 |
13614 |
1 |
0 |
0 |
T127 |
24854 |
3 |
0 |
0 |
T128 |
32820 |
2 |
0 |
0 |
T129 |
16122 |
3 |
0 |
0 |
T135 |
8950 |
1 |
0 |
0 |
T136 |
15848 |
1 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_hi_err_update_sync
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T62 T67 T68
Cond Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_hi_err_update_sync
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T67,T68 |
1 | 0 | Covered | T62,T67,T68 |
1 | 1 | Covered | T137 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T67,T68 |
1 | 0 | Covered | T137 |
1 | 1 | Covered | T62,T67,T68 |
Branch Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_hi_err_update_sync
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_hi_err_update_sync
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
23 |
0 |
0 |
T62 |
10370 |
2 |
0 |
0 |
T67 |
3943 |
1 |
0 |
0 |
T68 |
7223 |
1 |
0 |
0 |
T129 |
16122 |
1 |
0 |
0 |
T135 |
8771 |
1 |
0 |
0 |
T136 |
3803 |
1 |
0 |
0 |
T137 |
9761 |
2 |
0 |
0 |
T139 |
7364 |
1 |
0 |
0 |
T140 |
8251 |
1 |
0 |
0 |
T141 |
5506 |
1 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
48251280 |
23 |
0 |
0 |
T62 |
5240 |
2 |
0 |
0 |
T67 |
4114 |
1 |
0 |
0 |
T68 |
6420 |
1 |
0 |
0 |
T129 |
7738 |
1 |
0 |
0 |
T135 |
4296 |
1 |
0 |
0 |
T136 |
7607 |
1 |
0 |
0 |
T137 |
19523 |
2 |
0 |
0 |
T139 |
14729 |
1 |
0 |
0 |
T140 |
3960 |
1 |
0 |
0 |
T141 |
10572 |
1 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_lo_err_update_sync
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T62 T64 T66
Cond Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_lo_err_update_sync
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T64,T66 |
1 | 0 | Covered | T62,T64,T66 |
1 | 1 | Covered | T137,T142 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T62,T64,T66 |
1 | 0 | Covered | T137,T142 |
1 | 1 | Covered | T62,T64,T66 |
Branch Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_lo_err_update_sync
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_reg.u_usb_meas_ctrl_shadowed_lo_err_update_sync
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
39205114 |
31 |
0 |
0 |
T62 |
10370 |
2 |
0 |
0 |
T64 |
8460 |
1 |
0 |
0 |
T66 |
4577 |
1 |
0 |
0 |
T68 |
7223 |
1 |
0 |
0 |
T129 |
16122 |
1 |
0 |
0 |
T130 |
6784 |
1 |
0 |
0 |
T136 |
3803 |
1 |
0 |
0 |
T137 |
9761 |
3 |
0 |
0 |
T139 |
7364 |
1 |
0 |
0 |
T143 |
5078 |
1 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
48251280 |
31 |
0 |
0 |
T62 |
5240 |
2 |
0 |
0 |
T64 |
4231 |
1 |
0 |
0 |
T66 |
2712 |
1 |
0 |
0 |
T68 |
6420 |
1 |
0 |
0 |
T129 |
7738 |
1 |
0 |
0 |
T130 |
21710 |
1 |
0 |
0 |
T136 |
7607 |
1 |
0 |
0 |
T137 |
19523 |
3 |
0 |
0 |
T139 |
14729 |
1 |
0 |
0 |
T143 |
9751 |
1 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_io_meas.u_meas.u_sync_ref
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T2 T3 T36
Cond Coverage for Instance : tb.dut.u_io_meas.u_meas.u_sync_ref
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T2,T3,T36 |
1 | 0 | Covered | T2,T3,T36 |
1 | 1 | Covered | T2,T3,T36 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T2,T3,T36 |
1 | 0 | Covered | T2,T3,T36 |
1 | 1 | Covered | T2,T3,T36 |
Branch Coverage for Instance : tb.dut.u_io_meas.u_meas.u_sync_ref
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_io_meas.u_meas.u_sync_ref
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
88307846 |
52094 |
0 |
0 |
T2 |
226443 |
83 |
0 |
0 |
T3 |
163030 |
181 |
0 |
0 |
T9 |
0 |
120 |
0 |
0 |
T10 |
0 |
74 |
0 |
0 |
T12 |
0 |
100 |
0 |
0 |
T19 |
41459 |
0 |
0 |
0 |
T20 |
2974 |
0 |
0 |
0 |
T21 |
1953 |
0 |
0 |
0 |
T22 |
3606 |
0 |
0 |
0 |
T23 |
1578 |
0 |
0 |
0 |
T24 |
8602 |
0 |
0 |
0 |
T25 |
1199 |
0 |
0 |
0 |
T26 |
2763 |
0 |
0 |
0 |
T36 |
0 |
118 |
0 |
0 |
T37 |
0 |
40 |
0 |
0 |
T39 |
0 |
81 |
0 |
0 |
T40 |
0 |
12 |
0 |
0 |
T41 |
0 |
168 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
1351700 |
50895 |
0 |
0 |
T2 |
488 |
83 |
0 |
0 |
T3 |
345 |
181 |
0 |
0 |
T9 |
0 |
120 |
0 |
0 |
T10 |
0 |
74 |
0 |
0 |
T12 |
0 |
100 |
0 |
0 |
T19 |
3022 |
0 |
0 |
0 |
T20 |
216 |
0 |
0 |
0 |
T21 |
153 |
0 |
0 |
0 |
T22 |
263 |
0 |
0 |
0 |
T23 |
115 |
0 |
0 |
0 |
T24 |
627 |
0 |
0 |
0 |
T25 |
87 |
0 |
0 |
0 |
T26 |
201 |
0 |
0 |
0 |
T36 |
0 |
118 |
0 |
0 |
T37 |
0 |
40 |
0 |
0 |
T39 |
0 |
81 |
0 |
0 |
T40 |
0 |
12 |
0 |
0 |
T41 |
0 |
168 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_io_div2_meas.u_meas.u_sync_ref
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T2 T3 T36
Cond Coverage for Instance : tb.dut.u_io_div2_meas.u_meas.u_sync_ref
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T2,T3,T36 |
1 | 0 | Covered | T2,T3,T36 |
1 | 1 | Covered | T2,T3,T36 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T2,T3,T36 |
1 | 0 | Covered | T2,T3,T36 |
1 | 1 | Covered | T2,T3,T36 |
Branch Coverage for Instance : tb.dut.u_io_div2_meas.u_meas.u_sync_ref
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_io_div2_meas.u_meas.u_sync_ref
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
43310283 |
51502 |
0 |
0 |
T2 |
113161 |
83 |
0 |
0 |
T3 |
81503 |
181 |
0 |
0 |
T9 |
0 |
120 |
0 |
0 |
T10 |
0 |
74 |
0 |
0 |
T12 |
0 |
100 |
0 |
0 |
T19 |
16524 |
0 |
0 |
0 |
T20 |
1522 |
0 |
0 |
0 |
T21 |
916 |
0 |
0 |
0 |
T22 |
1736 |
0 |
0 |
0 |
T23 |
749 |
0 |
0 |
0 |
T24 |
4630 |
0 |
0 |
0 |
T25 |
541 |
0 |
0 |
0 |
T26 |
1447 |
0 |
0 |
0 |
T36 |
0 |
118 |
0 |
0 |
T37 |
0 |
40 |
0 |
0 |
T39 |
0 |
81 |
0 |
0 |
T40 |
0 |
12 |
0 |
0 |
T41 |
0 |
168 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
1351700 |
50303 |
0 |
0 |
T2 |
488 |
83 |
0 |
0 |
T3 |
345 |
181 |
0 |
0 |
T9 |
0 |
120 |
0 |
0 |
T10 |
0 |
74 |
0 |
0 |
T12 |
0 |
100 |
0 |
0 |
T19 |
3022 |
0 |
0 |
0 |
T20 |
216 |
0 |
0 |
0 |
T21 |
153 |
0 |
0 |
0 |
T22 |
263 |
0 |
0 |
0 |
T23 |
115 |
0 |
0 |
0 |
T24 |
627 |
0 |
0 |
0 |
T25 |
87 |
0 |
0 |
0 |
T26 |
201 |
0 |
0 |
0 |
T36 |
0 |
118 |
0 |
0 |
T37 |
0 |
40 |
0 |
0 |
T39 |
0 |
81 |
0 |
0 |
T40 |
0 |
12 |
0 |
0 |
T41 |
0 |
168 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_io_div4_meas.u_meas.u_sync_ref
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T2 T3 T36
Cond Coverage for Instance : tb.dut.u_io_div4_meas.u_meas.u_sync_ref
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T2,T3,T36 |
1 | 0 | Covered | T2,T3,T36 |
1 | 1 | Covered | T2,T3,T36 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T2,T3,T36 |
1 | 0 | Covered | T2,T3,T36 |
1 | 1 | Covered | T2,T3,T36 |
Branch Coverage for Instance : tb.dut.u_io_div4_meas.u_meas.u_sync_ref
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_io_div4_meas.u_meas.u_sync_ref
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
21654700 |
50644 |
0 |
0 |
T2 |
56581 |
83 |
0 |
0 |
T3 |
40751 |
181 |
0 |
0 |
T9 |
0 |
119 |
0 |
0 |
T10 |
0 |
74 |
0 |
0 |
T12 |
0 |
100 |
0 |
0 |
T19 |
8260 |
0 |
0 |
0 |
T20 |
760 |
0 |
0 |
0 |
T21 |
458 |
0 |
0 |
0 |
T22 |
868 |
0 |
0 |
0 |
T23 |
375 |
0 |
0 |
0 |
T24 |
2314 |
0 |
0 |
0 |
T25 |
270 |
0 |
0 |
0 |
T26 |
723 |
0 |
0 |
0 |
T36 |
0 |
118 |
0 |
0 |
T37 |
0 |
40 |
0 |
0 |
T39 |
0 |
81 |
0 |
0 |
T40 |
0 |
12 |
0 |
0 |
T41 |
0 |
168 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
1351700 |
49452 |
0 |
0 |
T2 |
488 |
83 |
0 |
0 |
T3 |
345 |
181 |
0 |
0 |
T9 |
0 |
119 |
0 |
0 |
T10 |
0 |
74 |
0 |
0 |
T12 |
0 |
100 |
0 |
0 |
T19 |
3022 |
0 |
0 |
0 |
T20 |
216 |
0 |
0 |
0 |
T21 |
153 |
0 |
0 |
0 |
T22 |
263 |
0 |
0 |
0 |
T23 |
115 |
0 |
0 |
0 |
T24 |
627 |
0 |
0 |
0 |
T25 |
87 |
0 |
0 |
0 |
T26 |
201 |
0 |
0 |
0 |
T36 |
0 |
118 |
0 |
0 |
T37 |
0 |
40 |
0 |
0 |
T39 |
0 |
81 |
0 |
0 |
T40 |
0 |
12 |
0 |
0 |
T41 |
0 |
168 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_main_meas.u_meas.u_sync_ref
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T2 T3 T36
Cond Coverage for Instance : tb.dut.u_main_meas.u_meas.u_sync_ref
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T2,T3,T36 |
1 | 0 | Covered | T2,T3,T36 |
1 | 1 | Covered | T2,T3,T36 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T2,T3,T36 |
1 | 0 | Covered | T2,T3,T36 |
1 | 1 | Covered | T2,T3,T36 |
Branch Coverage for Instance : tb.dut.u_main_meas.u_meas.u_sync_ref
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_main_meas.u_meas.u_sync_ref
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
98159591 |
61801 |
0 |
0 |
T2 |
235886 |
83 |
0 |
0 |
T3 |
211830 |
265 |
0 |
0 |
T9 |
0 |
110 |
0 |
0 |
T10 |
0 |
74 |
0 |
0 |
T12 |
0 |
100 |
0 |
0 |
T19 |
43187 |
0 |
0 |
0 |
T20 |
3099 |
0 |
0 |
0 |
T21 |
1857 |
0 |
0 |
0 |
T22 |
3757 |
0 |
0 |
0 |
T23 |
1643 |
0 |
0 |
0 |
T24 |
8960 |
0 |
0 |
0 |
T25 |
1248 |
0 |
0 |
0 |
T26 |
2878 |
0 |
0 |
0 |
T36 |
0 |
154 |
0 |
0 |
T37 |
0 |
52 |
0 |
0 |
T39 |
0 |
153 |
0 |
0 |
T40 |
0 |
12 |
0 |
0 |
T41 |
0 |
240 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
1383755 |
60933 |
0 |
0 |
T2 |
488 |
83 |
0 |
0 |
T3 |
429 |
265 |
0 |
0 |
T9 |
0 |
110 |
0 |
0 |
T10 |
0 |
74 |
0 |
0 |
T12 |
0 |
100 |
0 |
0 |
T19 |
3022 |
0 |
0 |
0 |
T20 |
216 |
0 |
0 |
0 |
T21 |
153 |
0 |
0 |
0 |
T22 |
263 |
0 |
0 |
0 |
T23 |
115 |
0 |
0 |
0 |
T24 |
627 |
0 |
0 |
0 |
T25 |
87 |
0 |
0 |
0 |
T26 |
201 |
0 |
0 |
0 |
T36 |
0 |
154 |
0 |
0 |
T37 |
0 |
52 |
0 |
0 |
T39 |
0 |
153 |
0 |
0 |
T40 |
0 |
12 |
0 |
0 |
T41 |
0 |
240 |
0 |
0 |
Line Coverage for Instance : tb.dut.u_usb_meas.u_meas.u_sync_ref
| Line No. | Total | Covered | Percent |
TOTAL | | 7 | 7 | 100.00 |
ALWAYS | 31 | 3 | 3 | 100.00 |
CONT_ASSIGN | 49 | 0 | 0 | |
CONT_ASSIGN | 52 | 0 | 0 | |
ALWAYS | 55 | 0 | 0 | |
ALWAYS | 89 | 3 | 3 | 100.00 |
CONT_ASSIGN | 97 | 1 | 1 | 100.00 |
30 always_ff @(posedge clk_src_i or negedge rst_src_ni) begin
31 1/1 if (!rst_src_ni) begin
Tests: T4 T5 T6
32 1/1 src_level <= 1'b0;
Tests: T4 T5 T6
33 end else begin
34 1/1 src_level <= src_level ^ src_pulse_i;
Tests: T4 T5 T6
35 end
36 end
37
38
39 // source active must come far enough such that the destination domain has time
40 // to create a valid pulse.
41 `ifdef INC_ASSERT
42 //VCS coverage off
43 // pragma coverage off
44
45 // source active flag tracks whether there is an ongoing "toggle" event.
46 // Until this toggle event is accepted by the destination domain (negative edge of
47 // of the pulse output), the source side cannot toggle again.
48 logic effective_rst_n;
49 unreachable assign effective_rst_n = rst_src_ni && dst_pulse_o;
50
51 logic src_active_flag_d, src_active_flag_q;
52 unreachable assign src_active_flag_d = src_pulse_i || src_active_flag_q;
53
54 always_ff @(posedge clk_src_i or negedge effective_rst_n) begin
55 unreachable if (!effective_rst_n) begin
56 unreachable src_active_flag_q <= '0;
57 end else begin
58 unreachable src_active_flag_q <= src_active_flag_d;
59 end
60 end
61
62 //VCS coverage on
63 // pragma coverage on
64
65 `ASSERT(SrcPulseCheck_M, src_pulse_i |-> !src_active_flag_q, clk_src_i, !rst_src_ni)
66 `endif
67
68 //////////////////////////////////////////////////////////
69 // synchronize level signal to destination clock domain //
70 //////////////////////////////////////////////////////////
71 logic dst_level;
72
73 prim_flop_2sync #(.Width(1)) prim_flop_2sync (
74 // source clock domain
75 .d_i (src_level),
76 // destination clock domain
77 .clk_i (clk_dst_i),
78 .rst_ni (rst_dst_ni),
79 .q_o (dst_level)
80 );
81
82 ////////////////////////////////////////
83 // convert level signal back to pulse //
84 ////////////////////////////////////////
85 logic dst_level_q;
86
87 // delay dst_level by 1 cycle
88 always_ff @(posedge clk_dst_i or negedge rst_dst_ni) begin
89 1/1 if (!rst_dst_ni) begin
Tests: T4 T5 T6
90 1/1 dst_level_q <= 1'b0;
Tests: T4 T5 T6
91 end else begin
92 1/1 dst_level_q <= dst_level;
Tests: T4 T5 T6
93 end
94 end
95
96 // edge detection
97 1/1 assign dst_pulse_o = dst_level_q ^ dst_level;
Tests: T2 T3 T36
Cond Coverage for Instance : tb.dut.u_usb_meas.u_meas.u_sync_ref
| Total | Covered | Percent |
Conditions | 8 | 8 | 100.00 |
Logical | 8 | 8 | 100.00 |
Non-Logical | 0 | 0 | |
Event | 0 | 0 | |
LINE 34
EXPRESSION (src_level ^ src_pulse_i)
----1---- -----2-----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T2,T3,T36 |
1 | 0 | Covered | T2,T3,T36 |
1 | 1 | Covered | T2,T3,T36 |
LINE 97
EXPRESSION (dst_level_q ^ dst_level)
-----1----- ----2----
-1- | -2- | Status | Tests |
0 | 0 | Covered | T4,T5,T6 |
0 | 1 | Covered | T2,T3,T36 |
1 | 0 | Covered | T2,T3,T36 |
1 | 1 | Covered | T2,T3,T36 |
Branch Coverage for Instance : tb.dut.u_usb_meas.u_meas.u_sync_ref
| Line No. | Total | Covered | Percent |
Branches |
|
4 |
4 |
100.00 |
IF |
31 |
2 |
2 |
100.00 |
IF |
89 |
2 |
2 |
100.00 |
31 if (!rst_src_ni) begin
-1-
32 src_level <= 1'b0;
==>
33 end else begin
34 src_level <= src_level ^ src_pulse_i;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
89 if (!rst_dst_ni) begin
-1-
90 dst_level_q <= 1'b0;
==>
91 end else begin
92 dst_level_q <= dst_level;
==>
Branches:
-1- | Status | Tests |
1 |
Covered |
T4,T5,T6 |
0 |
Covered |
T4,T5,T6 |
Assert Coverage for Instance : tb.dut.u_usb_meas.u_meas.u_sync_ref
Assertion Details
DstPulseCheck_A
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
47072987 |
60529 |
0 |
0 |
T2 |
113227 |
83 |
0 |
0 |
T3 |
101680 |
265 |
0 |
0 |
T9 |
0 |
103 |
0 |
0 |
T10 |
0 |
74 |
0 |
0 |
T12 |
0 |
100 |
0 |
0 |
T19 |
20730 |
0 |
0 |
0 |
T20 |
1487 |
0 |
0 |
0 |
T21 |
922 |
0 |
0 |
0 |
T22 |
1803 |
0 |
0 |
0 |
T23 |
789 |
0 |
0 |
0 |
T24 |
4301 |
0 |
0 |
0 |
T25 |
599 |
0 |
0 |
0 |
T26 |
1381 |
0 |
0 |
0 |
T36 |
0 |
178 |
0 |
0 |
T37 |
0 |
64 |
0 |
0 |
T39 |
0 |
165 |
0 |
0 |
T40 |
0 |
12 |
0 |
0 |
T41 |
0 |
204 |
0 |
0 |
SrcPulseCheck_M
Name | Attempts | Real Successes | Failures | Incomplete |
Total |
1364601 |
60033 |
0 |
0 |
T2 |
488 |
83 |
0 |
0 |
T3 |
429 |
265 |
0 |
0 |
T9 |
0 |
103 |
0 |
0 |
T10 |
0 |
74 |
0 |
0 |
T12 |
0 |
100 |
0 |
0 |
T19 |
3022 |
0 |
0 |
0 |
T20 |
216 |
0 |
0 |
0 |
T21 |
153 |
0 |
0 |
0 |
T22 |
263 |
0 |
0 |
0 |
T23 |
115 |
0 |
0 |
0 |
T24 |
627 |
0 |
0 |
0 |
T25 |
87 |
0 |
0 |
0 |
T26 |
201 |
0 |
0 |
0 |
T36 |
0 |
178 |
0 |
0 |
T37 |
0 |
64 |
0 |
0 |
T39 |
0 |
165 |
0 |
0 |
T40 |
0 |
12 |
0 |
0 |
T41 |
0 |
204 |
0 |
0 |