Tae's attempt at the 1 Billion Row Challenge in Bun/Typescript
Current Best Run (Macbook Pro M4 48GB RAM) - 9.22s:
🟢 COMPLETE! 🟢
- Total rows processed: 1,000,000,000
- Total time: 9.22s
- Average throughput: 108,511,229 rows/second
- Clone the repo: https://github.com/gunnarmorling/1brc
- Install jdk (make sure it's v21):
brew install openjdk@21
- Add jdk is in your rc path, either .zshrc or .bashrc (instructions in installation output)
- Run
./mvnw clean verify
- Run
./create_measurements_fast.sh 1000000000
NOTE: file is 13.8GB, make sure you have enough space - (optional) download one of the answers by running
./calculate_average_jerrinot.sh > result.txt
- Install deps with
npm install
- Run the parser, either bun or nodejs:
You can run it on a test file which only has 500 rows:
npm run bun test.txt
OR
npm run node test.txt
npm run bun measurements.txt
OR
npm run node measurements.txt