coverage-analysis

Identify unexercised code paths during fuzzing campaigns using LLVM coverage tools.

Updated Jan 17, 2026
One-click install
npx skills add https://github.com/mejango/juicy-vision --skill coverage-analysis-mejango
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: coverage-analysis
Source: https://github.com/mejango/juicy-vision/tree/main/.claude/plugins/testing-handbook-skills/skills/coverage-analysis
Command: npx skills add https://github.com/mejango/juicy-vision --skill coverage-analysis-mejango

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Coverage analysis helps fuzzing teams understand exactly which parts of the code are exercised by their harnesses, enabling targeted improvements and faster debugging.

Core Features & Use Cases

  • Coverage instrumentation: Attach instrumentation to identify executed code paths during fuzzing campaigns.
  • Progress tracking: Compare coverage across harness iterations to measure improvement.
  • Harness optimization: Guide dictionary entries and seed selection by revealing uncovered branches.
  • Use Case: When fuzzing a C/C++ project, run with LLVM/Clang coverage tools and generate reports to identify dead or unreachable code.

Quick Start

Build with coverage instrumentation: LLVM: clang++ -fprofile-instr-generate -fcoverage-mapping -O2 main.cc harness.cc execute-rt.cc -o fuzz_exec Run the fuzzer to generate coverage data: LLVM_PROFILE_FILE=fuzz.profraw ./fuzz_exec corpus/ Create and inspect coverage reports: llvm-profdata merge -sparse fuzz.profraw -o fuzz.profdata llvm-cov show ./fuzz_exec -instr-profile=fuzz.profdata -format=html -output-dir html/

Frequently Asked Questions about coverage-analysis

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I measure fuzzing coverage to identify unexercised code paths?

To measure fuzzing coverage, build your project with instrumentation flags like -fprofile-instr-generate -fcoverage-mapping, run the fuzzer to generate a .profraw file, then merge and analyze it using llvm-profdata and llvm-cov to identify unexercised code paths.

How do I generate an HTML coverage report from fuzzing profraw data?

You generate an HTML coverage report by first merging raw profile data with llvm-profdata merge, then running llvm-cov show with the -format=html flag and specifying the output directory to visualize executed and missed code paths.

Does coverage analysis work with Rust and C++ fuzzing campaigns?

Coverage analysis is applicable to C/C++, Rust, and multi-language fuzzing campaigns, requiring instrumentation builds and LLVM tooling to generate reports that reveal exactly which parts of the code are exercised by your harnesses.

Why does my fuzzing harness have low code coverage and how can I improve it?

Low code coverage indicates your harness is not reaching deep code paths, which you can improve by tuning harness inputs, expanding the corpus, and adding dictionary entries based on uncovered branches revealed in the coverage report.

What LLVM compiler flags are required for fuzzing coverage instrumentation?

The required LLVM compiler flags for fuzzing coverage instrumentation are -fprofile-instr-generate and -fcoverage-mapping, which attach the necessary instrumentation to identify executed code paths during your fuzzing campaigns.