Skip to main content

benchmarks

To the greatest extent possible, performance is optimized to be competitive with the standard library. It's not uncommon for ribs to outperform the standard library in certain scenarios but the best way to determine if ribs is right for your use-case is to test and measure yourself.

Running

There are a number of benchmarks in packages/bench that compare the performance of the different libraries.

# Install benchmark_harness
dart pub global activate benchmark_harness

# Compare Future and IO
dart run benchmark_harness:bench --flavor aot --target packages/bench/bin/io.dart

# Compare Stream and Rill
dart run benchmark_harness:bench --flavor aot --target packages/bench/bin/rill.dart

# Compare Collections
dart run benchmark_harness:bench --flavor aot --target packages/bench/bin/collection/map.dart
dart run benchmark_harness:bench --flavor aot --target packages/bench/bin/collection/seq.dart
dart run benchmark_harness:bench --flavor aot --target packages/bench/bin/collection/set.dart