chore: Add SELECT benchmark coverage for read-path overhead (#45)

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Marcelo Soares <marcelo.me.soares@gmail.com>
This commit is contained in:
Copilot 2026-05-09 23:05:12 -03:00 • committed by GitHub
commit 83fbef8d2c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -4,16 +4,16 @@ import 'benchmark.dart';
import 'conversion.dart';
void printPerformanceImpact(
BenchmarkResults benchmarkResults, {
BenchmarkResults results, {
required int rowCount,
bool runningInCI = false,
}) {
print(
'${runningInCI ? '```' : ''}'
'\n📊 ${benchmarkResults.operation.name.toUpperCase()} performance impact:',
'\n📊 ${results.operation.name.toUpperCase()} performance impact:',
);
final baselineTime = benchmarkResults.baseline;
final crdtTime = benchmarkResults.crdt;
final baselineTime = results.baseline;
final crdtTime = results.crdt;
final runDelayUs = crdtTime - baselineTime;
final slowdown = runDelayUs / baselineTime * 100;
@ -25,9 +25,9 @@ void printPerformanceImpact(
print(' Time: $baselineDelay --> $crdtDelay ($runDelay)');
print(' CRDT overhead: ${formatter2.format(slowdown)}% slower');
print(
' Delay per ${benchmarkResults.operation.name}: $runDelayPerOperation',
);
if (results.operation != Operation.select) {
print(' Delay per ${results.operation.name}: $runDelayPerOperation');
}
if (runningInCI) print('```');
}