Branch Coverage
ConceptBranch coverage is a code-coverage metric that measures the fraction of decision-point edges (branches) in a program that are exercised by a test suite. It is one of the main code-coverage types alongside statement and path coverage, is widely used as a basic test criterion in pre-silicon unit-level validation, is collected together with other code-based metrics by processor/hardware fuzzers (such as TheHuzz, FuSS, and GoldenFuzz) during RTL simulation, and is one of the optimization objectives targeted by coverage-directed test-generation tools such as uGP and FireDrill.
WIKI
Overview
Branch coverage is a code-coverage metric that measures the fraction of decision-point edges (branches) in a program that are exercised by a test suite. Specifically, branch coverage indicates whether all possible branches of a conditional statement — including if-else-if, case, and for-loop constructs — have been executed; execution of only the "True branch" of a conditional yields 50% branch coverage.[1] Branch coverage of source code is a very widely used test criterion and is similar in nature to line coverage, MC/DC, and other test objectives such as assertion-violation coverage, since all of these reduce to the question of whether many test objectives are reachable by some test input.[2]
Formally, for a set of test inputs (\mathcal{S}), a set of branches (\mathcal{B}), and a branch (b) that can be evaluated to a Boolean value (v), branch coverage can be expressed as[6]
NEIGHBORHOOD
No graph connections found for this entity yet. It may appear in future ingestion runs.
explore full graph →