gunnarmorling / 1brc

1️⃣🐝🏎️ The One Billion Row Challenge -- A fun exploration of how quickly 1B rows from a text file can be aggregated with Java
https://www.morling.dev/blog/one-billion-row-challenge/
Apache License 2.0
6.08k stars 1.83k forks source link

Use native type, remove lots of type conversions #618

Closed abeobk closed 7 months ago

abeobk commented 7 months ago

Check List:

STANDARD Benchmark 1: ./calculate_average_abeobk.sh Time (mean ± σ): 560.5 ms ± 2.9 ms [User: 2.6 ms, System: 1.6 ms] Range (min … max): 557.2 ms … 567.1 ms 10 runs

10K STATION Benchmark 1: ./calculate_average_abeobk.sh Time (mean ± σ): 2.100 s ± 0.007 s [User: 0.002 s, System: 0.003 s] Range (min … max): 2.089 s … 2.108 s 10 runs

gunnarmorling commented 7 months ago

00:02.091 now, nice!

Benchmark 1: timeout -v 300 ./calculate_average_abeobk.sh 2>&1
  Time (mean ± σ):      2.087 s ±  0.014 s    [User: 0.002 s, System: 0.004 s]
  Range (min … max):    2.063 s …  2.099 s    5 runs

Summary
  abeobk: trimmed mean 2.09120156588, raw times 2.06283919988,2.08849347488,2.09662411088,2.08848711188,2.09894213488

Leaderboard

| # | Result (m:s.ms) | Implementation     | JDK | Submitter     | Notes     |
|---|-----------------|--------------------|-----|---------------|-----------|
|   | 00:02.091 | [link](https://github.com/gunnarmorling/1brc/blob/main/src/main/java/dev/morling/onebrc/CalculateAverage_abeobk.java)| 21.0.2-graal | [Van Phu DO](https://github.com/abeobk) | GraalVM native binary, uses Unsafe |