From 41ec9cf2942edc7be58d78e49a050131bb2faf8c Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Wed, 25 Jun 2025 23:10:24 +0300 Subject: Add comprehensive benchmarking framework for DTail MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Create benchmark framework to measure performance of dcat, dgrep, and dmap - Generate test files of 10MB, 100MB, and 1GB with configurable patterns - Support benchmarking with gzip and zstd compressed files - Implement tool-specific benchmarks: * DCat: Simple reading, multiple files, compressed files * DGrep: Pattern matching, regex complexity, context lines, inverted grep * DMap: Aggregations, group by operations, complex queries, time intervals - Track performance metrics: throughput (MB/sec), lines/sec, memory usage - Save results in multiple formats: JSON, CSV, and Markdown reports - Add Makefile targets: benchmark, benchmark-quick, benchmark-full - Support environment variables for configuration (sizes, timeouts, etc.) - Automatically clean up temporary .tmp files after benchmarks The framework provides consistent performance testing across the DTail toolset and enables tracking performance regressions between commits. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- Makefile | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 71ae1ed..495abb3 100644 --- a/Makefile +++ b/Makefile @@ -47,3 +47,9 @@ test: ${GO} clean -testcache set -e; find . -name '*_test.go' | while read file; do dirname $$file; done | \ sort -u | while read dir; do ${GO} test -tags '${GO_TAGS}' --race -v -failfast $$dir || exit 2; done +benchmark: build + ${GO} test -bench=. ./benchmarks +benchmark-quick: build + ${GO} test -bench=BenchmarkQuick ./benchmarks +benchmark-full: build + ${GO} test -bench=. -benchtime=3x ./benchmarks -- cgit v1.2.3