Skip to content

Conversation

klauspost
Copy link
Collaborator

Usage: warp cmp before.jzon.zst after.json.zst`.

Example...

λ warp cmp warp-mixed-2025-04-22[151603]-BTJN.json.zst warp-mixed-2025-04-22[135713]-6t7p.json.zst

-------------------
Operation: DELETE
Operations: 812 -> 2232
Duration: 31s -> 1m34s
* Average: -8.93% (-2.3) obj/s
* Requests: Avg: +31.2ms (+9%), P50: +15.9ms (+12%), P99: +37.6ms (+10%), Best: -12.3ms (-79%), Worst: +58.8ms (+12%) StdDev: +5.5ms (+6%)
-------------------
Operation: GET
Operations: 3651 -> 10024
Duration: 31s -> 1m34s
* Average: -9.00% (-105.3 MiB/s) throughput, -9.00% (-10.5) obj/s
* Requests: Avg: +2.5ms (+5%), P50: +900µs (+3%), P99: +1.1ms (+2%), Best: -2.2ms (-22%), Worst: +81.1ms (+51%) StdDev: +1.9ms (+21%)
* TTFB: Avg: +1.5ms (+20%), P50: +415.655µs (+7%), P99: +2.007334ms (+4%), Best: -499.8µs (-24%), Worst: +78.9896ms (+54%) StdDev: +2.069452ms (+27%)
-------------------
Operation: PUT
Operations: 1219 -> 3351
Duration: 31s -> 1m34s
* Average: -8.84% (-34.5 MiB/s) throughput, -8.84% (-3.4) obj/s
* Requests: Avg: +44.3ms (+13%), P50: +43.2ms (+13%), P99: +65.5ms (+11%), Best: +4.6ms (+7%), Worst: +107.2ms (+16%) StdDev: +13.1ms (+12%)
-------------------
Operation: STAT
Operations: 2442 -> 6685
Duration: 31s -> 1m34s
* Average: -9.31% (-7.3) obj/s
* Requests: Avg: +1.3ms (+3%), P50: -100µs (-4%), P99: -200µs (-1%), Best: 0s (0%), Worst: +26.4ms (+35%) StdDev: +100µs (+2%)

λ

Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces aggregated format comparison features for benchmark data, with modifications to percentile metrics handling and conversion routines for aggregated input. Key changes include:

  • Removal of P25 and P75 percentile comparisons in the benchmark comparison functions.
  • Addition of the AsBench converter in ttfb.go and a new LongSeg method in throughput.go.
  • Updates in the CLI to support aggregated input and enhanced JSON decoding.

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
pkg/bench/compare.go Removed P25/P75 percentile fields from comparison logic
pkg/aggregate/ttfb.go Added AsBench conversion with scaling adjustments
pkg/aggregate/throughput.go Introduced LongSeg for converting segment data
pkg/aggregate/compare.go Added aggregated comparison function
cli/cmp.go Updated CLI input handling for aggregated and legacy files
cli/analyze.go Removed check limiting benchmark files to a single input

Usage: warp cmp before.jzon.zst after.json.zst`.

Example...

```
λ warp cmp warp-mixed-2025-04-22[151603]-BTJN.json.zst warp-mixed-2025-04-22[135713]-6t7p.json.zst

-------------------
Operation: DELETE
Operations: 812 -> 2232
Duration: 31s -> 1m34s
* Average: -8.93% (-2.3) obj/s
* Requests: Avg: +31.2ms (+9%), P50: +15.9ms (+12%), P99: +37.6ms (+10%), Best: -12.3ms (-79%), Worst: +58.8ms (+12%) StdDev: +5.5ms (+6%)
-------------------
Operation: GET
Operations: 3651 -> 10024
Duration: 31s -> 1m34s
* Average: -9.00% (-105.3 MiB/s) throughput, -9.00% (-10.5) obj/s
* Requests: Avg: +2.5ms (+5%), P50: +900µs (+3%), P99: +1.1ms (+2%), Best: -2.2ms (-22%), Worst: +81.1ms (+51%) StdDev: +1.9ms (+21%)
* TTFB: Avg: +1.5ms (+20%), P50: +415.655µs (+7%), P99: +2.007334ms (+4%), Best: -499.8µs (-24%), Worst: +78.9896ms (+54%) StdDev: +2.069452ms (+27%)
-------------------
Operation: PUT
Operations: 1219 -> 3351
Duration: 31s -> 1m34s
* Average: -8.84% (-34.5 MiB/s) throughput, -8.84% (-3.4) obj/s
* Requests: Avg: +44.3ms (+13%), P50: +43.2ms (+13%), P99: +65.5ms (+11%), Best: +4.6ms (+7%), Worst: +107.2ms (+16%) StdDev: +13.1ms (+12%)
-------------------
Operation: STAT
Operations: 2442 -> 6685
Duration: 31s -> 1m34s
* Average: -9.31% (-7.3) obj/s
* Requests: Avg: +1.3ms (+3%), P50: -100µs (-4%), P99: -200µs (-1%), Best: 0s (0%), Worst: +26.4ms (+35%) StdDev: +100µs (+2%)

λ
```
@harshavardhana harshavardhana merged commit 27b021d into minio:master Apr 25, 2025
6 checks passed
@harshavardhana
Copy link
Member

Looks like there is a crash here when results are empty

Operation: PUT
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x58 pc=0x970808]

goroutine 1 [running]:
github.com/minio/warp/pkg/aggregate.Compare(0xc0004af2c0, 0xc0001ed400, {0xc0004db190, 0x3})
	/home/harsha/go/src/github.com/minio/warp/pkg/aggregate/compare.go:33 +0x108
github.com/minio/warp/cli.printCompare(_, {0x2, {0xc000188600, 0x100}, 0x0, {0x0, 0x0}, {0x0, 0x0}, {0x0, ...}, ...}, ...)
	/home/harsha/go/src/github.com/minio/warp/cli/cmp.go:122 +0x3df
github.com/minio/warp/cli.mainCmp(0xc00043fa00)
	/home/harsha/go/src/github.com/minio/warp/cli/cmp.go:83 +0x4c5
github.com/minio/cli.HandleAction({0xd9f840?, 0xf5b260?}, 0x3?)
	/home/harsha/go/pkg/mod/github.com/minio/[email protected]/app.go:490 +0x50
github.com/minio/cli.Command.Run({{0xefe98f, 0x3}, {0x0, 0x0}, {0x0, 0x0, 0x0}, {0xf1832e, 0x1f}, {0x0, ...}, ...}, ...)
	/home/harsha/go/pkg/mod/github.com/minio/[email protected]/command.go:242 +0x935
github.com/minio/cli.(*App).Run(0xc000513dc0, {0xc000032100, 0x4, 0x4})
	/home/harsha/go/pkg/mod/github.com/minio/[email protected]/app.go:260 +0xa3b
github.com/minio/warp/cli.Main({0xc000032100, 0x4, 0x4})
	/home/harsha/go/src/github.com/minio/warp/cli/cli.go:83 +0x1bc
main.main()
	/home/harsha/go/src/github.com/minio/warp/main.go:36 +0xd6

@klauspost klauspost deleted the cmp-new-format branch April 28, 2025 07:55
klauspost added a commit to klauspost/warp that referenced this pull request Apr 28, 2025
Fixes crash mentioned on minio#389
harshavardhana pushed a commit that referenced this pull request Apr 28, 2025
Fixes crash mentioned on #389
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants