| doc_id | DBS-PERF-008 |
|---|---|
| doc_title | Static Analysis Baseline - database_system |
| doc_version | 1.0.0 |
| doc_date | 2026-04-04 |
| doc_status | Released |
| project | database_system |
| category | PERF |
SSOT: This document is the single source of truth for Static Analysis Baseline - database_system.
Language: English | 한국어
Date: 2025-10-03
Version: 0.1.0.0
Tool Versions:
- clang-tidy: 18.x
- cppcheck: 2.x
This document establishes the baseline for static analysis warnings in database_system. The goal is to track improvements over time and prevent regression.
- Checks enabled: modernize-, concurrency-, performance-, bugprone-, cert-, cppcoreguidelines-
- Standard: C++20
- Configuration file: .clang-tidy
Total Warnings: TBD
Run: clang-tidy -p build/compile_commands.json <source_files>
Warning Distribution:
- modernize-*: TBD
- performance-*: TBD
- concurrency-*: TBD
- readability-*: TBD
- bugprone-*: TBD
See .clang-tidy for full list of suppressed checks.
- Project file: .cppcheck
- Enable: all checks
- Standard: C++20
Total Issues: TBD
Run: cppcheck --project=.cppcheck --enable=all
Issue Distribution:
- Error: TBD
- Warning: TBD
- Style: TBD
- Performance: TBD
See .cppcheck for full list of suppressions.
Phase 1 Goals (By 2025-11-01):
- clang-tidy: 0 errors, < 20 warnings
- cppcheck: 0 errors, < 10 warnings
Phase 2 Goals (By 2025-12-01):
- clang-tidy: < 10 warnings
- cppcheck: < 5 warnings
Phase 3 Goals (By 2026-01-01):
- All warnings resolved or explicitly documented
# Generate compile commands
cmake -B build -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
# Run clang-tidy
clang-tidy -p build <source_files>
# Or check all files
find src include -name "*.cpp" -o -name "*.h" | xargs clang-tidy -p build# Using project configuration
cppcheck --project=.cppcheck --enable=all --xml 2> cppcheck.xml
# Generate HTML report
cppcheck-htmlreport --file=cppcheck.xml --report-dir=build/cppcheck-reportAny increase in warnings should be documented here with justification:
| Date | Tool | Change | Reason | Resolved |
|---|---|---|---|---|
| 2025-10-03 | clang-tidy | Initial baseline | Phase 0 setup | N/A |
| 2025-10-03 | cppcheck | Initial baseline | Phase 0 setup | N/A |
- Baseline will be updated after fixing initial warnings in Phase 1
- Goal is continuous improvement and zero regression
- All new code must pass static analysis checks
Last Updated: 2025-10-20