Skip to main content

A CLI tool for programming language speed benchmarks

Project description

Velocicode 🚀

Velocicode is a high-performance command-line tool for benchmarking programming language speeds. It allows you to run standard algorithms across multiple languages and compare their execution time with professional, interactive reports.

Features ✨

  • Multi-Language Support: Benchmarks Python, C++, Rust, Go, JavaScript (Node.js), Java, and C# (.NET).
  • Standard Algorithms:
    • fibonacci (Recursion intensity)
    • matrix_mul (Floating point & Cache)
    • quicksort (Memory & Sorting)
    • primes (Sieve of Eratosthenes)
    • string_concat (String Optimization) 🧵
    • json_parse (Data Processing) 📄
    • regex_redact (Text Processing) 🔍
    • New in v0.9.0:
      • async_io (Async Task Overhead) ⏱️
      • sqlite_ops (Database Insert/Select) 💾
      • http_server (HTTP Throughput) 🌐
  • Smart Execution:
    • System Info: Auto-detects your CPU, RAM, and OS.
    • Memory Benchmarking (New): Tracks Peak RAM usage for every run. 🧠
    • Dependency Check: Automatically checks for compilers and skips missing languages.
  • Premium UI:
    • Beautiful terminal output using the Rich library.
    • Rankings with Medals (🥇 🥈 🥉).
    • Relative Speed comparisons (e.g., 1.00x vs 45.9x).
  • Data Export:
    • JSON: Raw data export for analysis.
    • HTML: Interactive reports with Charts for presentations.

Installation

pip install velocicode

To install compilers for all supported languages (Python, C++, Rust, Go, Node.js, Java, .NET), run:

velocicode deps

This will print the exact install command for your OS (Ubuntu, Fedora, macOS, Windows).

Usage

1. Run Benchmarks

Run all benchmarks with default settings:

velocicode run

The tool will display your system information and check if you have the necessary compilers. If some are missing, it will ask if you want to proceed with the available ones.

Filter by specific algorithm or language:

# Run only Matrix Multiplication in Rust and Go
velocicode run --filter-algo matrix_mul --filter-lang rust,go

2. Generate Reports 📊

Export results to JSON or generate a visual HTML report:

velocicode run --html report.html --json results.json

Open report.html in your browser to see interactive bar charts!

3. Check Compilers

Velocicode relies on system compilers. Check what you have installed:

velocicode check

Requirements

[!IMPORTANT] This tool requires external compilers. pip installs the runner, but you need the languages installed:

  • Python 3.7+
  • g++ (for C++)
  • rustc (for Rust)
  • go (for Go)
  • node (for JavaScript)
  • javac (for Java - JDK required, e.g. java-latest-openjdk-devel)
  • dotnet (for C#)

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

velocicode-0.9.1.tar.gz (6.2 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

velocicode-0.9.1-py3-none-any.whl (6.5 MB view details)

Uploaded Python 3

File details

Details for the file velocicode-0.9.1.tar.gz.

File metadata

  • Download URL: velocicode-0.9.1.tar.gz
  • Upload date:
  • Size: 6.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for velocicode-0.9.1.tar.gz
Algorithm Hash digest
SHA256 10bdcc05c71d10578e8c63a07d5c25e9161825abad7a5f6bb28a35322c7f04d0
MD5 d738fd9da5fff02606caa1ed90ad0d63
BLAKE2b-256 d02c07da6cfd3d7097905508f4fe53d184554e56f3817017eb112c8fcd7c7194

See more details on using hashes here.

File details

Details for the file velocicode-0.9.1-py3-none-any.whl.

File metadata

  • Download URL: velocicode-0.9.1-py3-none-any.whl
  • Upload date:
  • Size: 6.5 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for velocicode-0.9.1-py3-none-any.whl
Algorithm Hash digest
SHA256 00803712bf755ac5220269be00482980b889eac4dbf77fbe243059eef4c0b563
MD5 7740b7c282f2b9e56f8a55dcf9a9fa8a
BLAKE2b-256 fb2e266d6a6dd13d2b7e72150be4786ba1c4db1fb517dc1137d782a787a6dc7a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page