Module Definition
dashboard | hierarchy | modlist | groups | tests | asserts



Module Instance : tb.dut.u_lc_ctrl_fsm.u_lc_ctrl_state_transition

Instance :
SCORELINECONDTOGGLEFSMBRANCHASSERT
87.14 98.46 66.67 96.30


Instance's subtree :
SCORELINECONDTOGGLEFSMBRANCHASSERT
87.14 98.46 66.67 96.30


Parent :
SCORELINECONDTOGGLEFSMBRANCHASSERTNAME
97.67 98.17 91.67 100.00 98.53 100.00 u_lc_ctrl_fsm


Subtrees :
NAMESCORELINECONDTOGGLEFSMBRANCHASSERT
no children

Line Coverage for Module : lc_ctrl_state_transition
Line No.TotalCoveredPercent
TOTAL666496.97
CONT_ASSIGN4511100.00
ALWAYS52656396.92

44 logic unused_trans_cmd; 45 1/1 assign unused_trans_cmd = trans_cmd_i; Tests: T1 T2 T3  46 end 47 48 // The decoder logic below checks whether a given transition edge 49 // is valid and computes the next lc counter ans state vectors. 50 always_comb begin : p_lc_state_transition 51 // Decoded state defaults 52 1/1 next_lc_cnt_o = lc_cnt_i; Tests: T1 T2 T3  53 1/1 next_lc_state_o = lc_state_i; Tests: T1 T2 T3  54 1/1 trans_cnt_oflw_error_o = 1'b0; Tests: T1 T2 T3  55 1/1 trans_invalid_error_o = 1'b0; Tests: T1 T2 T3  56 57 // ---------- VOLATILE_TEST_UNLOCKED CODE SECTION START ---------- 58 // NOTE THAT THIS IS A FEATURE FOR TEST CHIPS ONLY TO MITIGATE 59 // THE RISK OF A BROKEN OTP MACRO. THIS WILL BE DISABLED VIA 60 // SecVolatileRawUnlockEn AT COMPILETIME FOR PRODUCTION DEVICES. 61 // --------------------------------------------------------------- 62 // Only enter here if volatile RAW unlock is available and enabled. 63 1/1 if (SecVolatileRawUnlockEn && volatile_raw_unlock_i && trans_cmd_i && fsm_state_i == IdleSt) Tests: T1 T2 T3  64 begin 65 // We only allow transitions from RAW -> TEST_UNLOCKED0 66 unreachable if (dec_lc_state_i != {DecLcStateNumRep{DecLcStRaw}} || 67 trans_target_i != {DecLcStateNumRep{DecLcStTestUnlocked0}}) begin 68 unreachable trans_invalid_error_o = 1'b1; 69 end ==> MISSING_ELSE 70 end MISSING_ELSE 71 // ----------- VOLATILE_TEST_UNLOCKED CODE SECTION END ----------- 72 73 1/1 if (fsm_state_i inside {CntIncrSt, Tests: T1 T2 T3  74 CntProgSt, 75 // Since OTP programming is incremental, we have to keep the next 76 // counter state assigned when performing the actual state transition 77 // in the second programming pass to prevent OTP programming errors. 78 TransCheckSt, 79 TokenCheck0St, 80 TokenCheck1St, 81 TransProgSt}) begin 82 // In this state, the life cycle counter is incremented. 83 // Throw an error if the counter is already maxed out. 84 1/1 unique case (lc_cnt_i) Tests: T1 T3 T4  85 1/1 LcCnt0: next_lc_cnt_o = LcCnt1; Tests: T16 T18 T19  86 1/1 LcCnt1: next_lc_cnt_o = LcCnt2; Tests: T4 T14 T16  87 1/1 LcCnt2: next_lc_cnt_o = LcCnt3; Tests: T3 T14 T16  88 1/1 LcCnt3: next_lc_cnt_o = LcCnt4; Tests: T14 T16 T20  89 1/1 LcCnt4: next_lc_cnt_o = LcCnt5; Tests: T13 T14 T16  90 1/1 LcCnt5: next_lc_cnt_o = LcCnt6; Tests: T4 T5 T14  91 1/1 LcCnt6: next_lc_cnt_o = LcCnt7; Tests: T4 T14 T8  92 1/1 LcCnt7: next_lc_cnt_o = LcCnt8; Tests: T3 T4 T14  93 1/1 LcCnt8: next_lc_cnt_o = LcCnt9; Tests: T4 T13 T14  94 1/1 LcCnt9: next_lc_cnt_o = LcCnt10; Tests: T4 T14 T16  95 1/1 LcCnt10: next_lc_cnt_o = LcCnt11; Tests: T4 T5 T14  96 1/1 LcCnt11: next_lc_cnt_o = LcCnt12; Tests: T3 T13 T14  97 1/1 LcCnt12: next_lc_cnt_o = LcCnt13; Tests: T4 T14 T16  98 1/1 LcCnt13: next_lc_cnt_o = LcCnt14; Tests: T4 T16 T21  99 1/1 LcCnt14: next_lc_cnt_o = LcCnt15; Tests: T1 T14 T16  100 1/1 LcCnt15: next_lc_cnt_o = LcCnt16; Tests: T3 T4 T13  101 1/1 LcCnt16: next_lc_cnt_o = LcCnt17; Tests: T3 T14 T16  102 1/1 LcCnt17: next_lc_cnt_o = LcCnt18; Tests: T4 T13 T14  103 1/1 LcCnt18: next_lc_cnt_o = LcCnt19; Tests: T13 T14 T16  104 1/1 LcCnt19: next_lc_cnt_o = LcCnt20; Tests: T3 T4 T14  105 1/1 LcCnt20: next_lc_cnt_o = LcCnt21; Tests: T14 T16 T22  106 1/1 LcCnt21: next_lc_cnt_o = LcCnt22; Tests: T5 T14 T16  107 1/1 LcCnt22: next_lc_cnt_o = LcCnt23; Tests: T5 T13 T14  108 1/1 LcCnt23: next_lc_cnt_o = LcCnt24; Tests: T14 T16 T7  109 1/1 LcCnt24: trans_cnt_oflw_error_o = 1'b1; Tests: T13 T16 T21  110 default: trans_cnt_oflw_error_o = 1'b1; 111 endcase // lc_cnt_i 112 113 // We always allow transitions into the SCRAP state, so the overflow error is silenced in that 114 // particular case. In that case we max out the transition counter and force the 115 // next_lc_state already into SCRAP so that the error silencing above cannot be abused. This 116 // means that when moving to SCRAP state, we program LcStScrap twice: once during the counter 117 // increment phase, and once during the actual state programming phase. 118 1/1 if (trans_target_i == {DecLcStateNumRep{DecLcStScrap}}) begin Tests: T1 T3 T4  119 1/1 next_lc_cnt_o = LcCnt24; Tests: T3 T4 T5  120 1/1 next_lc_state_o = LcStScrap; Tests: T3 T4 T5  121 1/1 trans_cnt_oflw_error_o = 1'b0; Tests: T3 T4 T5  122 end MISSING_ELSE 123 end MISSING_ELSE 124 125 1/1 if (fsm_state_i inside {TransCheckSt, Tests: T1 T2 T3  126 TokenCheck0St, 127 TokenCheck1St, 128 TransProgSt}) begin 129 // SEC_CM: STATE.CONFIG.SPARSE 130 // Check that the decoded transition indexes are valid before indexing the state transition 131 // matrix. We perform the check twice with different indices into the replicated state 132 // enumeration. 133 1/1 if (dec_lc_state_i[0] <= DecLcStScrap && Tests: T1 T3 T5  134 trans_target_i[0] <= DecLcStScrap && 135 dec_lc_state_i[1] <= DecLcStScrap && 136 trans_target_i[1] <= DecLcStScrap) begin 137 // Check the state transition token matrix in order to see whether this transition is valid. 138 // All transitions have a token index value different from InvalidTokenIdx. We perform the 139 // check twice with different indices into the replicated state enumeration. 140 1/1 if (TransTokenIdxMatrix[dec_lc_state_i[0]][trans_target_i[0]] != InvalidTokenIdx || Tests: T1 T3 T5  141 TransTokenIdxMatrix[dec_lc_state_i[1]][trans_target_i[1]] != InvalidTokenIdx) begin 142 // Encode the target state. 143 // Note that the life cycle encoding itself also ensures that only certain transitions are 144 // possible. So even if this logic here is tampered with, the encoding values won't allow 145 // an invalid transition (instead, the programming operation will fail and leave the life 146 // cycle state corrupted/invalid). 147 1/1 unique case (trans_target_i) Tests: T1 T3 T5  148 0/1 ==> {DecLcStateNumRep{DecLcStRaw}}: next_lc_state_o = LcStRaw; 149 1/1 {DecLcStateNumRep{DecLcStTestUnlocked0}}: next_lc_state_o = LcStTestUnlocked0; Tests: T1 T14 T17  150 1/1 {DecLcStateNumRep{DecLcStTestLocked0}}: next_lc_state_o = LcStTestLocked0; Tests: T14 T23 T24  151 1/1 {DecLcStateNumRep{DecLcStTestUnlocked1}}: next_lc_state_o = LcStTestUnlocked1; Tests: T14 T20 T23  152 1/1 {DecLcStateNumRep{DecLcStTestLocked1}}: next_lc_state_o = LcStTestLocked1; Tests: T20 T25 T24  153 1/1 {DecLcStateNumRep{DecLcStTestUnlocked2}}: next_lc_state_o = LcStTestUnlocked2; Tests: T22 T20 T26  154 1/1 {DecLcStateNumRep{DecLcStTestLocked2}}: next_lc_state_o = LcStTestLocked2; Tests: T16 T20 T23  155 1/1 {DecLcStateNumRep{DecLcStTestUnlocked3}}: next_lc_state_o = LcStTestUnlocked3; Tests: T14 T16 T20  156 1/1 {DecLcStateNumRep{DecLcStTestLocked3}}: next_lc_state_o = LcStTestLocked3; Tests: T14 T16 T23  157 1/1 {DecLcStateNumRep{DecLcStTestUnlocked4}}: next_lc_state_o = LcStTestUnlocked4; Tests: T14 T16 T7  158 1/1 {DecLcStateNumRep{DecLcStTestLocked4}}: next_lc_state_o = LcStTestLocked4; Tests: T14 T16 T20  159 1/1 {DecLcStateNumRep{DecLcStTestUnlocked5}}: next_lc_state_o = LcStTestUnlocked5; Tests: T14 T16 T20  160 1/1 {DecLcStateNumRep{DecLcStTestLocked5}}: next_lc_state_o = LcStTestLocked5; Tests: T14 T16 T20  161 1/1 {DecLcStateNumRep{DecLcStTestUnlocked6}}: next_lc_state_o = LcStTestUnlocked6; Tests: T13 T16 T22  162 1/1 {DecLcStateNumRep{DecLcStTestLocked6}}: next_lc_state_o = LcStTestLocked6; Tests: T5 T14 T21  163 1/1 {DecLcStateNumRep{DecLcStTestUnlocked7}}: next_lc_state_o = LcStTestUnlocked7; Tests: T13 T14 T16  164 1/1 {DecLcStateNumRep{DecLcStDev}}: next_lc_state_o = LcStDev; Tests: T3 T5 T16  165 1/1 {DecLcStateNumRep{DecLcStProd}}: next_lc_state_o = LcStProd; Tests: T3 T5 T13  166 1/1 {DecLcStateNumRep{DecLcStProdEnd}}: next_lc_state_o = LcStProdEnd; Tests: T14 T16 T21  167 1/1 {DecLcStateNumRep{DecLcStRma}}: next_lc_state_o = LcStRma; Tests: T3 T13 T14  168 1/1 {DecLcStateNumRep{DecLcStScrap}}: next_lc_state_o = LcStScrap; Tests: T3 T5 T13  169 default: trans_invalid_error_o = 1'b1; 170 endcase // trans_target_i 171 end else begin 172 1/1 trans_invalid_error_o = 1'b1; Tests: T16 T25 T27  173 end 174 end else begin 175 0/1 ==> trans_invalid_error_o = 1'b1; 176 end 177 178 // SEC_CM: STATE.CONFIG.SPARSE 179 // Check that the internally re-encoded life cycle state has a correct encoding. 180 1/1 unique case (dec_lc_state_i) Tests: T1 T3 T5  181 {DecLcStateNumRep{DecLcStRaw}}, 182 {DecLcStateNumRep{DecLcStTestUnlocked0}}, 183 {DecLcStateNumRep{DecLcStTestLocked0}}, 184 {DecLcStateNumRep{DecLcStTestUnlocked1}}, 185 {DecLcStateNumRep{DecLcStTestLocked1}}, 186 {DecLcStateNumRep{DecLcStTestUnlocked2}}, 187 {DecLcStateNumRep{DecLcStTestLocked2}}, 188 {DecLcStateNumRep{DecLcStTestUnlocked3}}, 189 {DecLcStateNumRep{DecLcStTestLocked3}}, 190 {DecLcStateNumRep{DecLcStTestUnlocked4}}, 191 {DecLcStateNumRep{DecLcStTestLocked4}}, 192 {DecLcStateNumRep{DecLcStTestUnlocked5}}, 193 {DecLcStateNumRep{DecLcStTestLocked5}}, 194 {DecLcStateNumRep{DecLcStTestUnlocked6}}, 195 {DecLcStateNumRep{DecLcStTestLocked6}}, 196 {DecLcStateNumRep{DecLcStTestUnlocked7}}, 197 {DecLcStateNumRep{DecLcStDev}}, 198 {DecLcStateNumRep{DecLcStProd}}, 199 {DecLcStateNumRep{DecLcStProdEnd}}, 200 {DecLcStateNumRep{DecLcStRma}}, 201 1/1 {DecLcStateNumRep{DecLcStScrap}}: ; Tests: T1 T3 T5  202 default: trans_invalid_error_o = 1'b1; 203 endcase // trans_target_i 204 end MISSING_ELSE

Cond Coverage for Module : lc_ctrl_state_transition
TotalCoveredPercent
Conditions14857.14
Logical14857.14
Non-Logical00
Event00

 LINE       66
 EXPRESSION 
 Number  Term
      1  (dec_lc_state_i != {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRaw}}) || 
      2  (trans_target_i != {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked0}}))
-1--2-StatusTests
00Unreachable
01Unreachable
10Unreachable

 LINE       66
 SUB-EXPRESSION (dec_lc_state_i != {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRaw}})
                -----------------------------------1----------------------------------
-1-StatusTests
0Unreachable
1Unreachable

 LINE       66
 SUB-EXPRESSION (trans_target_i != {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked0}})
                ----------------------------------------1---------------------------------------
-1-StatusTests
0Unreachable
1Unreachable

 LINE       118
 EXPRESSION (trans_target_i == {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStScrap}})
            ------------------------------------1-----------------------------------
-1-StatusTests
0CoveredT1,T3,T4
1CoveredT3,T4,T5

 LINE       133
 EXPRESSION 
 Number  Term
      1  (dec_lc_state_i[0] <= DecLcStScrap) && 
      2  (trans_target_i[0] <= DecLcStScrap) && 
      3  (dec_lc_state_i[1] <= DecLcStScrap) && 
      4  (trans_target_i[1] <= DecLcStScrap))
-1--2--3--4-StatusTests
0111Not Covered
1011Not Covered
1101Not Covered
1110Not Covered
1111CoveredT1,T3,T5

 LINE       140
 EXPRESSION 
 Number  Term
      1  (lc_ctrl_pkg::TransTokenIdxMatrix[dec_lc_state_i[0]][trans_target_i[0]] != InvalidTokenIdx) || 
      2  (lc_ctrl_pkg::TransTokenIdxMatrix[dec_lc_state_i[1]][trans_target_i[1]] != InvalidTokenIdx))
-1--2-StatusTests
00CoveredT16,T25,T27
01Not Covered
10Not Covered

 LINE       140
 SUB-EXPRESSION (lc_ctrl_pkg::TransTokenIdxMatrix[dec_lc_state_i[0]][trans_target_i[0]] != InvalidTokenIdx)
                ---------------------------------------------1---------------------------------------------
-1-StatusTests
0CoveredT16,T25,T27
1CoveredT1,T3,T5

 LINE       140
 SUB-EXPRESSION (lc_ctrl_pkg::TransTokenIdxMatrix[dec_lc_state_i[1]][trans_target_i[1]] != InvalidTokenIdx)
                ---------------------------------------------1---------------------------------------------
-1-StatusTests
0CoveredT16,T25,T27
1CoveredT1,T3,T5

Branch Coverage for Module : lc_ctrl_state_transition
Line No.TotalCoveredPercent
Branches 58 52 89.66
IF 63 2 1 50.00
IF 73 29 28 96.55
IF 125 27 23 85.19


63 if (SecVolatileRawUnlockEn && volatile_raw_unlock_i && trans_cmd_i && fsm_state_i == IdleSt) -1- 64 begin 65 // We only allow transitions from RAW -> TEST_UNLOCKED0 66 if (dec_lc_state_i != {DecLcStateNumRep{DecLcStRaw}} || -2- 67 trans_target_i != {DecLcStateNumRep{DecLcStTestUnlocked0}}) begin 68 trans_invalid_error_o = 1'b1; ==> (Unreachable) 69 end MISSING_ELSE ==> 70 end MISSING_ELSE ==>

Branches:
-1--2-StatusTests
1 1 Unreachable
1 0 Not Covered
0 - Covered T1,T2,T3


73 if (fsm_state_i inside {CntIncrSt, -1- 74 CntProgSt, 75 // Since OTP programming is incremental, we have to keep the next 76 // counter state assigned when performing the actual state transition 77 // in the second programming pass to prevent OTP programming errors. 78 TransCheckSt, 79 TokenCheck0St, 80 TokenCheck1St, 81 TransProgSt}) begin 82 // In this state, the life cycle counter is incremented. 83 // Throw an error if the counter is already maxed out. 84 unique case (lc_cnt_i) -2- 85 LcCnt0: next_lc_cnt_o = LcCnt1; ==> 86 LcCnt1: next_lc_cnt_o = LcCnt2; ==> 87 LcCnt2: next_lc_cnt_o = LcCnt3; ==> 88 LcCnt3: next_lc_cnt_o = LcCnt4; ==> 89 LcCnt4: next_lc_cnt_o = LcCnt5; ==> 90 LcCnt5: next_lc_cnt_o = LcCnt6; ==> 91 LcCnt6: next_lc_cnt_o = LcCnt7; ==> 92 LcCnt7: next_lc_cnt_o = LcCnt8; ==> 93 LcCnt8: next_lc_cnt_o = LcCnt9; ==> 94 LcCnt9: next_lc_cnt_o = LcCnt10; ==> 95 LcCnt10: next_lc_cnt_o = LcCnt11; ==> 96 LcCnt11: next_lc_cnt_o = LcCnt12; ==> 97 LcCnt12: next_lc_cnt_o = LcCnt13; ==> 98 LcCnt13: next_lc_cnt_o = LcCnt14; ==> 99 LcCnt14: next_lc_cnt_o = LcCnt15; ==> 100 LcCnt15: next_lc_cnt_o = LcCnt16; ==> 101 LcCnt16: next_lc_cnt_o = LcCnt17; ==> 102 LcCnt17: next_lc_cnt_o = LcCnt18; ==> 103 LcCnt18: next_lc_cnt_o = LcCnt19; ==> 104 LcCnt19: next_lc_cnt_o = LcCnt20; ==> 105 LcCnt20: next_lc_cnt_o = LcCnt21; ==> 106 LcCnt21: next_lc_cnt_o = LcCnt22; ==> 107 LcCnt22: next_lc_cnt_o = LcCnt23; ==> 108 LcCnt23: next_lc_cnt_o = LcCnt24; ==> 109 LcCnt24: trans_cnt_oflw_error_o = 1'b1; ==> 110 default: trans_cnt_oflw_error_o = 1'b1; ==> 111 endcase // lc_cnt_i 112 113 // We always allow transitions into the SCRAP state, so the overflow error is silenced in that 114 // particular case. In that case we max out the transition counter and force the 115 // next_lc_state already into SCRAP so that the error silencing above cannot be abused. This 116 // means that when moving to SCRAP state, we program LcStScrap twice: once during the counter 117 // increment phase, and once during the actual state programming phase. 118 if (trans_target_i == {DecLcStateNumRep{DecLcStScrap}}) begin -3- 119 next_lc_cnt_o = LcCnt24; ==> 120 next_lc_state_o = LcStScrap; 121 trans_cnt_oflw_error_o = 1'b0; 122 end MISSING_ELSE ==> 123 end MISSING_ELSE ==>

Branches:
-1--2--3-StatusTests
1 LcCnt0 - Covered T16,T18,T19
1 LcCnt1 - Covered T4,T14,T16
1 LcCnt2 - Covered T3,T14,T16
1 LcCnt3 - Covered T14,T16,T20
1 LcCnt4 - Covered T13,T14,T16
1 LcCnt5 - Covered T4,T5,T14
1 LcCnt6 - Covered T4,T14,T8
1 LcCnt7 - Covered T3,T4,T14
1 LcCnt8 - Covered T4,T13,T14
1 LcCnt9 - Covered T4,T14,T16
1 LcCnt10 - Covered T4,T5,T14
1 LcCnt11 - Covered T3,T13,T14
1 LcCnt12 - Covered T4,T14,T16
1 LcCnt13 - Covered T4,T16,T21
1 LcCnt14 - Covered T1,T14,T16
1 LcCnt15 - Covered T3,T4,T13
1 LcCnt16 - Covered T3,T14,T16
1 LcCnt17 - Covered T4,T13,T14
1 LcCnt18 - Covered T13,T14,T16
1 LcCnt19 - Covered T3,T4,T14
1 LcCnt20 - Covered T14,T16,T22
1 LcCnt21 - Covered T5,T14,T16
1 LcCnt22 - Covered T5,T13,T14
1 LcCnt23 - Covered T14,T16,T7
1 LcCnt24 - Covered T13,T16,T21
1 default - Not Covered
1 - 1 Covered T3,T4,T5
1 - 0 Covered T1,T3,T4
0 - - Covered T1,T2,T3


125 if (fsm_state_i inside {TransCheckSt, -1- 126 TokenCheck0St, 127 TokenCheck1St, 128 TransProgSt}) begin 129 // SEC_CM: STATE.CONFIG.SPARSE 130 // Check that the decoded transition indexes are valid before indexing the state transition 131 // matrix. We perform the check twice with different indices into the replicated state 132 // enumeration. 133 if (dec_lc_state_i[0] <= DecLcStScrap && -2- 134 trans_target_i[0] <= DecLcStScrap && 135 dec_lc_state_i[1] <= DecLcStScrap && 136 trans_target_i[1] <= DecLcStScrap) begin 137 // Check the state transition token matrix in order to see whether this transition is valid. 138 // All transitions have a token index value different from InvalidTokenIdx. We perform the 139 // check twice with different indices into the replicated state enumeration. 140 if (TransTokenIdxMatrix[dec_lc_state_i[0]][trans_target_i[0]] != InvalidTokenIdx || -3- 141 TransTokenIdxMatrix[dec_lc_state_i[1]][trans_target_i[1]] != InvalidTokenIdx) begin 142 // Encode the target state. 143 // Note that the life cycle encoding itself also ensures that only certain transitions are 144 // possible. So even if this logic here is tampered with, the encoding values won't allow 145 // an invalid transition (instead, the programming operation will fail and leave the life 146 // cycle state corrupted/invalid). 147 unique case (trans_target_i) -4- 148 {DecLcStateNumRep{DecLcStRaw}}: next_lc_state_o = LcStRaw; ==> 149 {DecLcStateNumRep{DecLcStTestUnlocked0}}: next_lc_state_o = LcStTestUnlocked0; ==> 150 {DecLcStateNumRep{DecLcStTestLocked0}}: next_lc_state_o = LcStTestLocked0; ==> 151 {DecLcStateNumRep{DecLcStTestUnlocked1}}: next_lc_state_o = LcStTestUnlocked1; ==> 152 {DecLcStateNumRep{DecLcStTestLocked1}}: next_lc_state_o = LcStTestLocked1; ==> 153 {DecLcStateNumRep{DecLcStTestUnlocked2}}: next_lc_state_o = LcStTestUnlocked2; ==> 154 {DecLcStateNumRep{DecLcStTestLocked2}}: next_lc_state_o = LcStTestLocked2; ==> 155 {DecLcStateNumRep{DecLcStTestUnlocked3}}: next_lc_state_o = LcStTestUnlocked3; ==> 156 {DecLcStateNumRep{DecLcStTestLocked3}}: next_lc_state_o = LcStTestLocked3; ==> 157 {DecLcStateNumRep{DecLcStTestUnlocked4}}: next_lc_state_o = LcStTestUnlocked4; ==> 158 {DecLcStateNumRep{DecLcStTestLocked4}}: next_lc_state_o = LcStTestLocked4; ==> 159 {DecLcStateNumRep{DecLcStTestUnlocked5}}: next_lc_state_o = LcStTestUnlocked5; ==> 160 {DecLcStateNumRep{DecLcStTestLocked5}}: next_lc_state_o = LcStTestLocked5; ==> 161 {DecLcStateNumRep{DecLcStTestUnlocked6}}: next_lc_state_o = LcStTestUnlocked6; ==> 162 {DecLcStateNumRep{DecLcStTestLocked6}}: next_lc_state_o = LcStTestLocked6; ==> 163 {DecLcStateNumRep{DecLcStTestUnlocked7}}: next_lc_state_o = LcStTestUnlocked7; ==> 164 {DecLcStateNumRep{DecLcStDev}}: next_lc_state_o = LcStDev; ==> 165 {DecLcStateNumRep{DecLcStProd}}: next_lc_state_o = LcStProd; ==> 166 {DecLcStateNumRep{DecLcStProdEnd}}: next_lc_state_o = LcStProdEnd; ==> 167 {DecLcStateNumRep{DecLcStRma}}: next_lc_state_o = LcStRma; ==> 168 {DecLcStateNumRep{DecLcStScrap}}: next_lc_state_o = LcStScrap; ==> 169 default: trans_invalid_error_o = 1'b1; ==> 170 endcase // trans_target_i 171 end else begin 172 trans_invalid_error_o = 1'b1; ==> 173 end 174 end else begin 175 trans_invalid_error_o = 1'b1; ==> 176 end 177 178 // SEC_CM: STATE.CONFIG.SPARSE 179 // Check that the internally re-encoded life cycle state has a correct encoding. 180 unique case (dec_lc_state_i) -5- 181 {DecLcStateNumRep{DecLcStRaw}}, 182 {DecLcStateNumRep{DecLcStTestUnlocked0}}, 183 {DecLcStateNumRep{DecLcStTestLocked0}}, 184 {DecLcStateNumRep{DecLcStTestUnlocked1}}, 185 {DecLcStateNumRep{DecLcStTestLocked1}}, 186 {DecLcStateNumRep{DecLcStTestUnlocked2}}, 187 {DecLcStateNumRep{DecLcStTestLocked2}}, 188 {DecLcStateNumRep{DecLcStTestUnlocked3}}, 189 {DecLcStateNumRep{DecLcStTestLocked3}}, 190 {DecLcStateNumRep{DecLcStTestUnlocked4}}, 191 {DecLcStateNumRep{DecLcStTestLocked4}}, 192 {DecLcStateNumRep{DecLcStTestUnlocked5}}, 193 {DecLcStateNumRep{DecLcStTestLocked5}}, 194 {DecLcStateNumRep{DecLcStTestUnlocked6}}, 195 {DecLcStateNumRep{DecLcStTestLocked6}}, 196 {DecLcStateNumRep{DecLcStTestUnlocked7}}, 197 {DecLcStateNumRep{DecLcStDev}}, 198 {DecLcStateNumRep{DecLcStProd}}, 199 {DecLcStateNumRep{DecLcStProdEnd}}, 200 {DecLcStateNumRep{DecLcStRma}}, 201 {DecLcStateNumRep{DecLcStScrap}}: ; ==> 202 default: trans_invalid_error_o = 1'b1; ==> 203 endcase // trans_target_i 204 end MISSING_ELSE ==>

Branches:
-1--2--3--4--5-StatusTests
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRaw}} - Not Covered
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked0}} - Covered T1,T14,T17
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked0}} - Covered T14,T23,T24
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked1}} - Covered T14,T20,T23
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked1}} - Covered T20,T25,T24
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked2}} - Covered T22,T20,T26
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked2}} - Covered T16,T20,T23
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked3}} - Covered T14,T16,T20
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked3}} - Covered T14,T16,T23
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked4}} - Covered T14,T16,T7
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked4}} - Covered T14,T16,T20
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked5}} - Covered T14,T16,T20
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked5}} - Covered T14,T16,T20
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked6}} - Covered T13,T16,T22
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked6}} - Covered T5,T14,T21
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked7}} - Covered T13,T14,T16
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStDev}} - Covered T3,T5,T16
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStProd}} - Covered T3,T5,T13
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStProdEnd}} - Covered T14,T16,T21
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRma}} - Covered T3,T13,T14
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStScrap}} - Covered T3,T5,T13
1 1 1 default - Not Covered
1 1 0 - - Covered T16,T25,T27
1 0 - - - Not Covered
1 - - - CASEITEM-1: {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRaw}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked0}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked0}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked1}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked1}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked2}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked2}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked3}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked3}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked4}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked4}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked5}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked5}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked6}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked6}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked7}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStDev}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStProd}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStProdEnd}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRma}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStScrap}} Covered T1,T3,T5
1 - - - default Not Covered
0 - - - - Covered T1,T2,T3

Line Coverage for Instance : tb.dut.u_lc_ctrl_fsm.u_lc_ctrl_state_transition
Line No.TotalCoveredPercent
TOTAL656498.46
CONT_ASSIGN4511100.00
ALWAYS52646398.44

44 logic unused_trans_cmd; 45 1/1 assign unused_trans_cmd = trans_cmd_i; Tests: T1 T2 T3  46 end 47 48 // The decoder logic below checks whether a given transition edge 49 // is valid and computes the next lc counter ans state vectors. 50 always_comb begin : p_lc_state_transition 51 // Decoded state defaults 52 1/1 next_lc_cnt_o = lc_cnt_i; Tests: T1 T2 T3  53 1/1 next_lc_state_o = lc_state_i; Tests: T1 T2 T3  54 1/1 trans_cnt_oflw_error_o = 1'b0; Tests: T1 T2 T3  55 1/1 trans_invalid_error_o = 1'b0; Tests: T1 T2 T3  56 57 // ---------- VOLATILE_TEST_UNLOCKED CODE SECTION START ---------- 58 // NOTE THAT THIS IS A FEATURE FOR TEST CHIPS ONLY TO MITIGATE 59 // THE RISK OF A BROKEN OTP MACRO. THIS WILL BE DISABLED VIA 60 // SecVolatileRawUnlockEn AT COMPILETIME FOR PRODUCTION DEVICES. 61 // --------------------------------------------------------------- 62 // Only enter here if volatile RAW unlock is available and enabled. 63 1/1 if (SecVolatileRawUnlockEn && volatile_raw_unlock_i && trans_cmd_i && fsm_state_i == IdleSt) Tests: T1 T2 T3  64 begin 65 // We only allow transitions from RAW -> TEST_UNLOCKED0 66 unreachable if (dec_lc_state_i != {DecLcStateNumRep{DecLcStRaw}} || 67 trans_target_i != {DecLcStateNumRep{DecLcStTestUnlocked0}}) begin 68 unreachable trans_invalid_error_o = 1'b1; 69 end ==> MISSING_ELSE 70 end MISSING_ELSE 71 // ----------- VOLATILE_TEST_UNLOCKED CODE SECTION END ----------- 72 73 1/1 if (fsm_state_i inside {CntIncrSt, Tests: T1 T2 T3  74 CntProgSt, 75 // Since OTP programming is incremental, we have to keep the next 76 // counter state assigned when performing the actual state transition 77 // in the second programming pass to prevent OTP programming errors. 78 TransCheckSt, 79 TokenCheck0St, 80 TokenCheck1St, 81 TransProgSt}) begin 82 // In this state, the life cycle counter is incremented. 83 // Throw an error if the counter is already maxed out. 84 1/1 unique case (lc_cnt_i) Tests: T1 T3 T4  85 1/1 LcCnt0: next_lc_cnt_o = LcCnt1; Tests: T16 T18 T19  86 1/1 LcCnt1: next_lc_cnt_o = LcCnt2; Tests: T4 T14 T16  87 1/1 LcCnt2: next_lc_cnt_o = LcCnt3; Tests: T3 T14 T16  88 1/1 LcCnt3: next_lc_cnt_o = LcCnt4; Tests: T14 T16 T20  89 1/1 LcCnt4: next_lc_cnt_o = LcCnt5; Tests: T13 T14 T16  90 1/1 LcCnt5: next_lc_cnt_o = LcCnt6; Tests: T4 T5 T14  91 1/1 LcCnt6: next_lc_cnt_o = LcCnt7; Tests: T4 T14 T8  92 1/1 LcCnt7: next_lc_cnt_o = LcCnt8; Tests: T3 T4 T14  93 1/1 LcCnt8: next_lc_cnt_o = LcCnt9; Tests: T4 T13 T14  94 1/1 LcCnt9: next_lc_cnt_o = LcCnt10; Tests: T4 T14 T16  95 1/1 LcCnt10: next_lc_cnt_o = LcCnt11; Tests: T4 T5 T14  96 1/1 LcCnt11: next_lc_cnt_o = LcCnt12; Tests: T3 T13 T14  97 1/1 LcCnt12: next_lc_cnt_o = LcCnt13; Tests: T4 T14 T16  98 1/1 LcCnt13: next_lc_cnt_o = LcCnt14; Tests: T4 T16 T21  99 1/1 LcCnt14: next_lc_cnt_o = LcCnt15; Tests: T1 T14 T16  100 1/1 LcCnt15: next_lc_cnt_o = LcCnt16; Tests: T3 T4 T13  101 1/1 LcCnt16: next_lc_cnt_o = LcCnt17; Tests: T3 T14 T16  102 1/1 LcCnt17: next_lc_cnt_o = LcCnt18; Tests: T4 T13 T14  103 1/1 LcCnt18: next_lc_cnt_o = LcCnt19; Tests: T13 T14 T16  104 1/1 LcCnt19: next_lc_cnt_o = LcCnt20; Tests: T3 T4 T14  105 1/1 LcCnt20: next_lc_cnt_o = LcCnt21; Tests: T14 T16 T22  106 1/1 LcCnt21: next_lc_cnt_o = LcCnt22; Tests: T5 T14 T16  107 1/1 LcCnt22: next_lc_cnt_o = LcCnt23; Tests: T5 T13 T14  108 1/1 LcCnt23: next_lc_cnt_o = LcCnt24; Tests: T14 T16 T7  109 1/1 LcCnt24: trans_cnt_oflw_error_o = 1'b1; Tests: T13 T16 T21  110 default: trans_cnt_oflw_error_o = 1'b1; Exclude Annotation: VC_COV_UNR 111 endcase // lc_cnt_i 112 113 // We always allow transitions into the SCRAP state, so the overflow error is silenced in that 114 // particular case. In that case we max out the transition counter and force the 115 // next_lc_state already into SCRAP so that the error silencing above cannot be abused. This 116 // means that when moving to SCRAP state, we program LcStScrap twice: once during the counter 117 // increment phase, and once during the actual state programming phase. 118 1/1 if (trans_target_i == {DecLcStateNumRep{DecLcStScrap}}) begin Tests: T1 T3 T4  119 1/1 next_lc_cnt_o = LcCnt24; Tests: T3 T4 T5  120 1/1 next_lc_state_o = LcStScrap; Tests: T3 T4 T5  121 1/1 trans_cnt_oflw_error_o = 1'b0; Tests: T3 T4 T5  122 end MISSING_ELSE 123 end MISSING_ELSE 124 125 1/1 if (fsm_state_i inside {TransCheckSt, Tests: T1 T2 T3  126 TokenCheck0St, 127 TokenCheck1St, 128 TransProgSt}) begin 129 // SEC_CM: STATE.CONFIG.SPARSE 130 // Check that the decoded transition indexes are valid before indexing the state transition 131 // matrix. We perform the check twice with different indices into the replicated state 132 // enumeration. 133 1/1 if (dec_lc_state_i[0] <= DecLcStScrap && Tests: T1 T3 T5  134 trans_target_i[0] <= DecLcStScrap && 135 dec_lc_state_i[1] <= DecLcStScrap && 136 trans_target_i[1] <= DecLcStScrap) begin 137 // Check the state transition token matrix in order to see whether this transition is valid. 138 // All transitions have a token index value different from InvalidTokenIdx. We perform the 139 // check twice with different indices into the replicated state enumeration. 140 1/1 if (TransTokenIdxMatrix[dec_lc_state_i[0]][trans_target_i[0]] != InvalidTokenIdx || Tests: T1 T3 T5  141 TransTokenIdxMatrix[dec_lc_state_i[1]][trans_target_i[1]] != InvalidTokenIdx) begin 142 // Encode the target state. 143 // Note that the life cycle encoding itself also ensures that only certain transitions are 144 // possible. So even if this logic here is tampered with, the encoding values won't allow 145 // an invalid transition (instead, the programming operation will fail and leave the life 146 // cycle state corrupted/invalid). 147 1/1 unique case (trans_target_i) Tests: T1 T3 T5  148 excluded {DecLcStateNumRep{DecLcStRaw}}: next_lc_state_o = LcStRaw; Exclude Annotation: VC_COV_UNR 149 1/1 {DecLcStateNumRep{DecLcStTestUnlocked0}}: next_lc_state_o = LcStTestUnlocked0; Tests: T1 T14 T17  150 1/1 {DecLcStateNumRep{DecLcStTestLocked0}}: next_lc_state_o = LcStTestLocked0; Tests: T14 T23 T24  151 1/1 {DecLcStateNumRep{DecLcStTestUnlocked1}}: next_lc_state_o = LcStTestUnlocked1; Tests: T14 T20 T23  152 1/1 {DecLcStateNumRep{DecLcStTestLocked1}}: next_lc_state_o = LcStTestLocked1; Tests: T20 T25 T24  153 1/1 {DecLcStateNumRep{DecLcStTestUnlocked2}}: next_lc_state_o = LcStTestUnlocked2; Tests: T22 T20 T26  154 1/1 {DecLcStateNumRep{DecLcStTestLocked2}}: next_lc_state_o = LcStTestLocked2; Tests: T16 T20 T23  155 1/1 {DecLcStateNumRep{DecLcStTestUnlocked3}}: next_lc_state_o = LcStTestUnlocked3; Tests: T14 T16 T20  156 1/1 {DecLcStateNumRep{DecLcStTestLocked3}}: next_lc_state_o = LcStTestLocked3; Tests: T14 T16 T23  157 1/1 {DecLcStateNumRep{DecLcStTestUnlocked4}}: next_lc_state_o = LcStTestUnlocked4; Tests: T14 T16 T7  158 1/1 {DecLcStateNumRep{DecLcStTestLocked4}}: next_lc_state_o = LcStTestLocked4; Tests: T14 T16 T20  159 1/1 {DecLcStateNumRep{DecLcStTestUnlocked5}}: next_lc_state_o = LcStTestUnlocked5; Tests: T14 T16 T20  160 1/1 {DecLcStateNumRep{DecLcStTestLocked5}}: next_lc_state_o = LcStTestLocked5; Tests: T14 T16 T20  161 1/1 {DecLcStateNumRep{DecLcStTestUnlocked6}}: next_lc_state_o = LcStTestUnlocked6; Tests: T13 T16 T22  162 1/1 {DecLcStateNumRep{DecLcStTestLocked6}}: next_lc_state_o = LcStTestLocked6; Tests: T5 T14 T21  163 1/1 {DecLcStateNumRep{DecLcStTestUnlocked7}}: next_lc_state_o = LcStTestUnlocked7; Tests: T13 T14 T16  164 1/1 {DecLcStateNumRep{DecLcStDev}}: next_lc_state_o = LcStDev; Tests: T3 T5 T16  165 1/1 {DecLcStateNumRep{DecLcStProd}}: next_lc_state_o = LcStProd; Tests: T3 T5 T13  166 1/1 {DecLcStateNumRep{DecLcStProdEnd}}: next_lc_state_o = LcStProdEnd; Tests: T14 T16 T21  167 1/1 {DecLcStateNumRep{DecLcStRma}}: next_lc_state_o = LcStRma; Tests: T3 T13 T14  168 1/1 {DecLcStateNumRep{DecLcStScrap}}: next_lc_state_o = LcStScrap; Tests: T3 T5 T13  169 default: trans_invalid_error_o = 1'b1; 170 endcase // trans_target_i 171 end else begin 172 1/1 trans_invalid_error_o = 1'b1; Tests: T16 T25 T27  173 end 174 end else begin 175 0/1 ==> trans_invalid_error_o = 1'b1; 176 end 177 178 // SEC_CM: STATE.CONFIG.SPARSE 179 // Check that the internally re-encoded life cycle state has a correct encoding. 180 1/1 unique case (dec_lc_state_i) Tests: T1 T3 T5  181 {DecLcStateNumRep{DecLcStRaw}}, 182 {DecLcStateNumRep{DecLcStTestUnlocked0}}, 183 {DecLcStateNumRep{DecLcStTestLocked0}}, 184 {DecLcStateNumRep{DecLcStTestUnlocked1}}, 185 {DecLcStateNumRep{DecLcStTestLocked1}}, 186 {DecLcStateNumRep{DecLcStTestUnlocked2}}, 187 {DecLcStateNumRep{DecLcStTestLocked2}}, 188 {DecLcStateNumRep{DecLcStTestUnlocked3}}, 189 {DecLcStateNumRep{DecLcStTestLocked3}}, 190 {DecLcStateNumRep{DecLcStTestUnlocked4}}, 191 {DecLcStateNumRep{DecLcStTestLocked4}}, 192 {DecLcStateNumRep{DecLcStTestUnlocked5}}, 193 {DecLcStateNumRep{DecLcStTestLocked5}}, 194 {DecLcStateNumRep{DecLcStTestUnlocked6}}, 195 {DecLcStateNumRep{DecLcStTestLocked6}}, 196 {DecLcStateNumRep{DecLcStTestUnlocked7}}, 197 {DecLcStateNumRep{DecLcStDev}}, 198 {DecLcStateNumRep{DecLcStProd}}, 199 {DecLcStateNumRep{DecLcStProdEnd}}, 200 {DecLcStateNumRep{DecLcStRma}}, 201 1/1 {DecLcStateNumRep{DecLcStScrap}}: ; Tests: T1 T3 T5  202 default: trans_invalid_error_o = 1'b1; Exclude Annotation: VC_COV_UNR 203 endcase // trans_target_i 204 end MISSING_ELSE

Cond Coverage for Instance : tb.dut.u_lc_ctrl_fsm.u_lc_ctrl_state_transition
TotalCoveredPercent
Conditions12866.67
Logical12866.67
Non-Logical00
Event00

 LINE       66
 EXPRESSION 
 Number  Term
      1  (dec_lc_state_i != {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRaw}}) || 
      2  (trans_target_i != {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked0}}))
-1--2-StatusTests
00Unreachable
01Unreachable
10Unreachable

 LINE       66
 SUB-EXPRESSION (dec_lc_state_i != {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRaw}})
                -----------------------------------1----------------------------------
-1-StatusTests
0Unreachable
1Unreachable

 LINE       66
 SUB-EXPRESSION (trans_target_i != {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked0}})
                ----------------------------------------1---------------------------------------
-1-StatusTests
0Unreachable
1Unreachable

 LINE       118
 EXPRESSION (trans_target_i == {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStScrap}})
            ------------------------------------1-----------------------------------
-1-StatusTests
0CoveredT1,T3,T4
1CoveredT3,T4,T5

 LINE       133
 EXPRESSION 
 Number  Term
      1  (dec_lc_state_i[0] <= DecLcStScrap) && 
      2  (trans_target_i[0] <= DecLcStScrap) && 
      3  (dec_lc_state_i[1] <= DecLcStScrap) && 
      4  (trans_target_i[1] <= DecLcStScrap))
-1--2--3--4-StatusTestsExclude Annotation
0111Excluded VC_COV_UNR
1011Not Covered
1101Excluded VC_COV_UNR
1110Not Covered
1111CoveredT1,T3,T5

 LINE       140
 EXPRESSION 
 Number  Term
      1  (lc_ctrl_pkg::TransTokenIdxMatrix[dec_lc_state_i[0]][trans_target_i[0]] != InvalidTokenIdx) || 
      2  (lc_ctrl_pkg::TransTokenIdxMatrix[dec_lc_state_i[1]][trans_target_i[1]] != InvalidTokenIdx))
-1--2-StatusTests
00CoveredT16,T25,T27
01Not Covered
10Not Covered

 LINE       140
 SUB-EXPRESSION (lc_ctrl_pkg::TransTokenIdxMatrix[dec_lc_state_i[0]][trans_target_i[0]] != InvalidTokenIdx)
                ---------------------------------------------1---------------------------------------------
-1-StatusTests
0CoveredT16,T25,T27
1CoveredT1,T3,T5

 LINE       140
 SUB-EXPRESSION (lc_ctrl_pkg::TransTokenIdxMatrix[dec_lc_state_i[1]][trans_target_i[1]] != InvalidTokenIdx)
                ---------------------------------------------1---------------------------------------------
-1-StatusTests
0CoveredT16,T25,T27
1CoveredT1,T3,T5

Branch Coverage for Instance : tb.dut.u_lc_ctrl_fsm.u_lc_ctrl_state_transition
Line No.TotalCoveredPercent
Branches 54 52 96.30
IF 63 1 1 100.00
IF 73 28 28 100.00
IF 125 25 23 92.00


63 if (SecVolatileRawUnlockEn && volatile_raw_unlock_i && trans_cmd_i && fsm_state_i == IdleSt) -1- 64 begin 65 // We only allow transitions from RAW -> TEST_UNLOCKED0 66 if (dec_lc_state_i != {DecLcStateNumRep{DecLcStRaw}} || -2- 67 trans_target_i != {DecLcStateNumRep{DecLcStTestUnlocked0}}) begin 68 trans_invalid_error_o = 1'b1; ==> (Unreachable) 69 end MISSING_ELSE ==> (Excluded) Exclude Annotation: VC_COV_UNR 70 end MISSING_ELSE ==>

Branches:
-1--2-StatusTestsExclude Annotation
1 1 Unreachable
1 0 Excluded VC_COV_UNR
0 - Covered T1,T2,T3


73 if (fsm_state_i inside {CntIncrSt, -1- 74 CntProgSt, 75 // Since OTP programming is incremental, we have to keep the next 76 // counter state assigned when performing the actual state transition 77 // in the second programming pass to prevent OTP programming errors. 78 TransCheckSt, 79 TokenCheck0St, 80 TokenCheck1St, 81 TransProgSt}) begin 82 // In this state, the life cycle counter is incremented. 83 // Throw an error if the counter is already maxed out. 84 unique case (lc_cnt_i) -2- 85 LcCnt0: next_lc_cnt_o = LcCnt1; ==> 86 LcCnt1: next_lc_cnt_o = LcCnt2; ==> 87 LcCnt2: next_lc_cnt_o = LcCnt3; ==> 88 LcCnt3: next_lc_cnt_o = LcCnt4; ==> 89 LcCnt4: next_lc_cnt_o = LcCnt5; ==> 90 LcCnt5: next_lc_cnt_o = LcCnt6; ==> 91 LcCnt6: next_lc_cnt_o = LcCnt7; ==> 92 LcCnt7: next_lc_cnt_o = LcCnt8; ==> 93 LcCnt8: next_lc_cnt_o = LcCnt9; ==> 94 LcCnt9: next_lc_cnt_o = LcCnt10; ==> 95 LcCnt10: next_lc_cnt_o = LcCnt11; ==> 96 LcCnt11: next_lc_cnt_o = LcCnt12; ==> 97 LcCnt12: next_lc_cnt_o = LcCnt13; ==> 98 LcCnt13: next_lc_cnt_o = LcCnt14; ==> 99 LcCnt14: next_lc_cnt_o = LcCnt15; ==> 100 LcCnt15: next_lc_cnt_o = LcCnt16; ==> 101 LcCnt16: next_lc_cnt_o = LcCnt17; ==> 102 LcCnt17: next_lc_cnt_o = LcCnt18; ==> 103 LcCnt18: next_lc_cnt_o = LcCnt19; ==> 104 LcCnt19: next_lc_cnt_o = LcCnt20; ==> 105 LcCnt20: next_lc_cnt_o = LcCnt21; ==> 106 LcCnt21: next_lc_cnt_o = LcCnt22; ==> 107 LcCnt22: next_lc_cnt_o = LcCnt23; ==> 108 LcCnt23: next_lc_cnt_o = LcCnt24; ==> 109 LcCnt24: trans_cnt_oflw_error_o = 1'b1; ==> 110 default: trans_cnt_oflw_error_o = 1'b1; ==> (Excluded) Exclude Annotation: VC_COV_UNR 111 endcase // lc_cnt_i 112 113 // We always allow transitions into the SCRAP state, so the overflow error is silenced in that 114 // particular case. In that case we max out the transition counter and force the 115 // next_lc_state already into SCRAP so that the error silencing above cannot be abused. This 116 // means that when moving to SCRAP state, we program LcStScrap twice: once during the counter 117 // increment phase, and once during the actual state programming phase. 118 if (trans_target_i == {DecLcStateNumRep{DecLcStScrap}}) begin -3- 119 next_lc_cnt_o = LcCnt24; ==> 120 next_lc_state_o = LcStScrap; 121 trans_cnt_oflw_error_o = 1'b0; 122 end MISSING_ELSE ==> 123 end MISSING_ELSE ==>

Branches:
-1--2--3-StatusTestsExclude Annotation
1 LcCnt0 - Covered T16,T18,T19
1 LcCnt1 - Covered T4,T14,T16
1 LcCnt2 - Covered T3,T14,T16
1 LcCnt3 - Covered T14,T16,T20
1 LcCnt4 - Covered T13,T14,T16
1 LcCnt5 - Covered T4,T5,T14
1 LcCnt6 - Covered T4,T14,T8
1 LcCnt7 - Covered T3,T4,T14
1 LcCnt8 - Covered T4,T13,T14
1 LcCnt9 - Covered T4,T14,T16
1 LcCnt10 - Covered T4,T5,T14
1 LcCnt11 - Covered T3,T13,T14
1 LcCnt12 - Covered T4,T14,T16
1 LcCnt13 - Covered T4,T16,T21
1 LcCnt14 - Covered T1,T14,T16
1 LcCnt15 - Covered T3,T4,T13
1 LcCnt16 - Covered T3,T14,T16
1 LcCnt17 - Covered T4,T13,T14
1 LcCnt18 - Covered T13,T14,T16
1 LcCnt19 - Covered T3,T4,T14
1 LcCnt20 - Covered T14,T16,T22
1 LcCnt21 - Covered T5,T14,T16
1 LcCnt22 - Covered T5,T13,T14
1 LcCnt23 - Covered T14,T16,T7
1 LcCnt24 - Covered T13,T16,T21
1 default - Excluded VC_COV_UNR
1 - 1 Covered T3,T4,T5
1 - 0 Covered T1,T3,T4
0 - - Covered T1,T2,T3


125 if (fsm_state_i inside {TransCheckSt, -1- 126 TokenCheck0St, 127 TokenCheck1St, 128 TransProgSt}) begin 129 // SEC_CM: STATE.CONFIG.SPARSE 130 // Check that the decoded transition indexes are valid before indexing the state transition 131 // matrix. We perform the check twice with different indices into the replicated state 132 // enumeration. 133 if (dec_lc_state_i[0] <= DecLcStScrap && -2- 134 trans_target_i[0] <= DecLcStScrap && 135 dec_lc_state_i[1] <= DecLcStScrap && 136 trans_target_i[1] <= DecLcStScrap) begin 137 // Check the state transition token matrix in order to see whether this transition is valid. 138 // All transitions have a token index value different from InvalidTokenIdx. We perform the 139 // check twice with different indices into the replicated state enumeration. 140 if (TransTokenIdxMatrix[dec_lc_state_i[0]][trans_target_i[0]] != InvalidTokenIdx || -3- 141 TransTokenIdxMatrix[dec_lc_state_i[1]][trans_target_i[1]] != InvalidTokenIdx) begin 142 // Encode the target state. 143 // Note that the life cycle encoding itself also ensures that only certain transitions are 144 // possible. So even if this logic here is tampered with, the encoding values won't allow 145 // an invalid transition (instead, the programming operation will fail and leave the life 146 // cycle state corrupted/invalid). 147 unique case (trans_target_i) -4- 148 {DecLcStateNumRep{DecLcStRaw}}: next_lc_state_o = LcStRaw; ==> (Excluded) Exclude Annotation: VC_COV_UNR 149 {DecLcStateNumRep{DecLcStTestUnlocked0}}: next_lc_state_o = LcStTestUnlocked0; ==> 150 {DecLcStateNumRep{DecLcStTestLocked0}}: next_lc_state_o = LcStTestLocked0; ==> 151 {DecLcStateNumRep{DecLcStTestUnlocked1}}: next_lc_state_o = LcStTestUnlocked1; ==> 152 {DecLcStateNumRep{DecLcStTestLocked1}}: next_lc_state_o = LcStTestLocked1; ==> 153 {DecLcStateNumRep{DecLcStTestUnlocked2}}: next_lc_state_o = LcStTestUnlocked2; ==> 154 {DecLcStateNumRep{DecLcStTestLocked2}}: next_lc_state_o = LcStTestLocked2; ==> 155 {DecLcStateNumRep{DecLcStTestUnlocked3}}: next_lc_state_o = LcStTestUnlocked3; ==> 156 {DecLcStateNumRep{DecLcStTestLocked3}}: next_lc_state_o = LcStTestLocked3; ==> 157 {DecLcStateNumRep{DecLcStTestUnlocked4}}: next_lc_state_o = LcStTestUnlocked4; ==> 158 {DecLcStateNumRep{DecLcStTestLocked4}}: next_lc_state_o = LcStTestLocked4; ==> 159 {DecLcStateNumRep{DecLcStTestUnlocked5}}: next_lc_state_o = LcStTestUnlocked5; ==> 160 {DecLcStateNumRep{DecLcStTestLocked5}}: next_lc_state_o = LcStTestLocked5; ==> 161 {DecLcStateNumRep{DecLcStTestUnlocked6}}: next_lc_state_o = LcStTestUnlocked6; ==> 162 {DecLcStateNumRep{DecLcStTestLocked6}}: next_lc_state_o = LcStTestLocked6; ==> 163 {DecLcStateNumRep{DecLcStTestUnlocked7}}: next_lc_state_o = LcStTestUnlocked7; ==> 164 {DecLcStateNumRep{DecLcStDev}}: next_lc_state_o = LcStDev; ==> 165 {DecLcStateNumRep{DecLcStProd}}: next_lc_state_o = LcStProd; ==> 166 {DecLcStateNumRep{DecLcStProdEnd}}: next_lc_state_o = LcStProdEnd; ==> 167 {DecLcStateNumRep{DecLcStRma}}: next_lc_state_o = LcStRma; ==> 168 {DecLcStateNumRep{DecLcStScrap}}: next_lc_state_o = LcStScrap; ==> 169 default: trans_invalid_error_o = 1'b1; ==> 170 endcase // trans_target_i 171 end else begin 172 trans_invalid_error_o = 1'b1; ==> 173 end 174 end else begin 175 trans_invalid_error_o = 1'b1; ==> 176 end 177 178 // SEC_CM: STATE.CONFIG.SPARSE 179 // Check that the internally re-encoded life cycle state has a correct encoding. 180 unique case (dec_lc_state_i) -5- 181 {DecLcStateNumRep{DecLcStRaw}}, 182 {DecLcStateNumRep{DecLcStTestUnlocked0}}, 183 {DecLcStateNumRep{DecLcStTestLocked0}}, 184 {DecLcStateNumRep{DecLcStTestUnlocked1}}, 185 {DecLcStateNumRep{DecLcStTestLocked1}}, 186 {DecLcStateNumRep{DecLcStTestUnlocked2}}, 187 {DecLcStateNumRep{DecLcStTestLocked2}}, 188 {DecLcStateNumRep{DecLcStTestUnlocked3}}, 189 {DecLcStateNumRep{DecLcStTestLocked3}}, 190 {DecLcStateNumRep{DecLcStTestUnlocked4}}, 191 {DecLcStateNumRep{DecLcStTestLocked4}}, 192 {DecLcStateNumRep{DecLcStTestUnlocked5}}, 193 {DecLcStateNumRep{DecLcStTestLocked5}}, 194 {DecLcStateNumRep{DecLcStTestUnlocked6}}, 195 {DecLcStateNumRep{DecLcStTestLocked6}}, 196 {DecLcStateNumRep{DecLcStTestUnlocked7}}, 197 {DecLcStateNumRep{DecLcStDev}}, 198 {DecLcStateNumRep{DecLcStProd}}, 199 {DecLcStateNumRep{DecLcStProdEnd}}, 200 {DecLcStateNumRep{DecLcStRma}}, 201 {DecLcStateNumRep{DecLcStScrap}}: ; ==> 202 default: trans_invalid_error_o = 1'b1; ==> (Excluded) Exclude Annotation: VC_COV_UNR 203 endcase // trans_target_i 204 end MISSING_ELSE ==>

Branches:
-1--2--3--4--5-StatusTestsExclude Annotation
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRaw}} - Excluded VC_COV_UNR
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked0}} - Covered T1,T14,T17
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked0}} - Covered T14,T23,T24
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked1}} - Covered T14,T20,T23
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked1}} - Covered T20,T25,T24
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked2}} - Covered T22,T20,T26
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked2}} - Covered T16,T20,T23
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked3}} - Covered T14,T16,T20
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked3}} - Covered T14,T16,T23
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked4}} - Covered T14,T16,T7
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked4}} - Covered T14,T16,T20
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked5}} - Covered T14,T16,T20
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked5}} - Covered T14,T16,T20
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked6}} - Covered T13,T16,T22
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked6}} - Covered T5,T14,T21
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked7}} - Covered T13,T14,T16
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStDev}} - Covered T3,T5,T16
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStProd}} - Covered T3,T5,T13
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStProdEnd}} - Covered T14,T16,T21
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRma}} - Covered T3,T13,T14
1 1 1 {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStScrap}} - Covered T3,T5,T13
1 1 1 default - Not Covered
1 1 0 - - Covered T16,T25,T27
1 0 - - - Not Covered
1 - - - CASEITEM-1: {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRaw}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked0}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked0}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked1}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked1}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked2}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked2}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked3}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked3}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked4}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked4}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked5}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked5}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked6}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestLocked6}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStTestUnlocked7}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStDev}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStProd}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStProdEnd}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStRma}} {lc_ctrl_state_pkg::DecLcStateNumRep {DecLcStScrap}} Covered T1,T3,T5
1 - - - default Excluded VC_COV_UNR
0 - - - - Covered T1,T2,T3

0% 10% 20% 30% 40% 50% 60% 70% 80% 90% 100%