Class VmBranchCoverageRecorder
java.lang.Object
org.impulsegraph.vm.VmBranchCoverageRecorder
Bytecode-Level Branch Coverage Recorder for ImpulseVM (SQLite VdbeCoverage /
test_vdbecov.c pattern). Tracks 2-way (0x03) and 3-way (0x07) branch
decisions per PC and enforces COVERAGE_BOTH, COVERAGE_ALWAYS_TAKEN, and
COVERAGE_NEVER_TAKEN constraints.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic enumstatic final classstatic final record -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidrecordBranch(int pc, int opcode, int siteId, VmBranchCoverageRecorder.BranchKind kind, VmBranchCoverageRecorder.BranchExpectation expectation, int branchIndex) Records a branch decision at(pc, opcode, siteId):branchIndex == 0(bit 0 = 0x01, taken / primary path),branchIndex == 1(bit 1 = 0x02, fall-through / secondary path),branchIndex == 2(bit 2 = 0x04, tertiary path for 3-way branches).static voidrecordGlobalBranch(int pc, int opcode, int siteId, VmBranchCoverageRecorder.BranchKind kind, VmBranchCoverageRecorder.BranchExpectation expectation, int branchIndex) static voidvoid
-
Constructor Details
-
VmBranchCoverageRecorder
public VmBranchCoverageRecorder()
-
-
Method Details
-
resetGlobal
public static void resetGlobal() -
resetLocal
public void resetLocal() -
recordBranch
public void recordBranch(int pc, int opcode, int siteId, VmBranchCoverageRecorder.BranchKind kind, VmBranchCoverageRecorder.BranchExpectation expectation, int branchIndex) Records a branch decision at(pc, opcode, siteId):branchIndex == 0(bit 0 = 0x01, taken / primary path),branchIndex == 1(bit 1 = 0x02, fall-through / secondary path),branchIndex == 2(bit 2 = 0x04, tertiary path for 3-way branches). -
recordGlobalBranch
public static void recordGlobalBranch(int pc, int opcode, int siteId, VmBranchCoverageRecorder.BranchKind kind, VmBranchCoverageRecorder.BranchExpectation expectation, int branchIndex) -
snapshotLocal
-
snapshotGlobal
public static Map<VmBranchCoverageRecorder.SiteKey, VmBranchCoverageRecorder.SiteEntry> snapshotGlobal()
-