Skip to content

v0.2.0

Latest

Choose a tag to compare

@saksham1319 saksham1319 released this 10 Nov 11:49
· 1 commit to main since this release

Prismio 0.2.0 reaches code that waits, code that has no operating system under it, and the editor. async fn, await, scope { } and spawn { } arrive, the compiler serves editors itself through prismio lsp and prismio fmt, and a --freestanding build links nothing from the C library, so a kernel can be written in Prismio. It is still pre-1.0 and several names changed on the way; read the breaking changes in the full notes before upgrading a program written for 0.1.0.

Highlights

  • Async functions and scoped tasks: async fn returns a Future<T>, await runs it, and scope { } cannot be left until every task started inside it has finished.
  • A language server and a formatter, in the compiler: prismio lsp serves LSP 3.17 and prismio fmt formats source, with --check for CI and --stdin for editors.
  • Freestanding programs: --freestanding links no installed runtime, no C library and no startup files. Small kernels boot under QEMU on AArch64 and 32-bit x86 in the project's tests.
  • System calls and platform blocks: std.syscall reaches the kernel on Linux and macOS, and linux { }, macos { } and windows { } choose code per target.
  • Integers of any width: Int<N> and UInt<N> for 1 to 8,388,608 bits, and five float types.
  • A larger standard library: std.json, HashSet, token and byte input in std.input, and std.poll.
  • T? is the only optional: Option<T> is gone, and Map is now HashMap.

Performance

On 86 workloads (Apple M5, 5 runs): geometric mean 0.81× of C++ and 0.79× of Rust, with checksums asserted before any timing is read.

Install

macOS and Linux: curl -fsSL https://prismio.org/install.sh | sh
Windows: unpack the .zip and put bin on PATH.

Archives are named prismio-0.2.0-[os]-[arch] and each has a .sha256. They are not signed, so check the checksum from this page. You also need your platform's C tools to link programs (Xcode Command Line Tools, build-essential, or Visual Studio Build Tools). On Linux x64 the compiler needs glibc 2.38 or later.

Full notes: https://prismio.org/releases/0.2.0