Skip to main content

Arx is a compiler built with llvm

Project description

ArxLang

Arx is a multi-purpose compiler that aims to provide native array abstractions with an Apache Arrow-backed runtime. It uses the power of LLVM to provide multi-architecture machine target code generation.

The language syntax is influenced by Python, C++, and YAML, featuring significant whitespace, static typing (planned), and a focus on data-oriented computing.

Quick Example

```
title: Quick average example
summary: Demonstrates a function with module and function docstrings.
```
fn average(x: f32, y: f32) -> f32:
  ```
  title: average
  summary: Returns the arithmetic mean of x and y.
  ```
  return (x + y) * 0.5
arx --show-llvm-ir examples/average.x

See the Getting Started guide for installation and more examples. For language details, see the Library Reference.

Architecture Boundary

Arx is the surface-language front end. It owns source syntax, lexing, parsing, CLI flow, tests, examples, and docs. IRx owns the AST model (irx.astx), semantic analysis, lowering, and backend code generation. When a new feature needs AST or lowering support, that support should be added in IRx first and then consumed from Arx.

Key Features

  • LLVM-powered -- compiles to native machine code via LLVM
  • Python-like syntax -- indentation-based blocks, familiar keywords
  • Native arrays -- builtin array-oriented types backed by Arrow internally (planned)
  • Multiple output modes -- inspect tokens, AST, LLVM IR, or compile to object files

Project Status

Arx is currently a prototype built on the Kaleidoscope tutorial compiler. It supports functions, control flow (if/else, for), variables, and extern declarations. See the Roadmap for what's planned next.

Arx Enhancement Proposals

Any change to the language syntax should be done using an Enhancement Proposal via the arx-proposals repository.

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

arxlang-0.15.0.tar.gz (46.0 kB view details)

Uploaded Source

Built Distribution

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

arxlang-0.15.0-py3-none-any.whl (56.7 kB view details)

Uploaded Python 3

File details

Details for the file arxlang-0.15.0.tar.gz.

File metadata

  • Download URL: arxlang-0.15.0.tar.gz
  • Upload date:
  • Size: 46.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.3.4 CPython/3.10.20 Linux/6.17.0-1010-azure

File hashes

Hashes for arxlang-0.15.0.tar.gz
Algorithm Hash digest
SHA256 739ce30f39bc23897a891daf6cae0233ff55fff28da9b489deaf28dceea4e005
MD5 32219b89388b9f687ac96d8aa6b15df6
BLAKE2b-256 eae684e5f56f97321d280d6dd3c37a47e7ba17371785f1881ce8b4c4f44c2f2d

See more details on using hashes here.

File details

Details for the file arxlang-0.15.0-py3-none-any.whl.

File metadata

  • Download URL: arxlang-0.15.0-py3-none-any.whl
  • Upload date:
  • Size: 56.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.3.4 CPython/3.10.20 Linux/6.17.0-1010-azure

File hashes

Hashes for arxlang-0.15.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0fc2db261ed964ad3221309ac5281d9151b52a7e0f369b9c2ea11d46a7734fee
MD5 fa7694c69ace6783329581ae5ab2d554
BLAKE2b-256 5afd4b0355f03304f6d372e0ebf67ff7aa1e89e8595986dc5fec7a18d5786521

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