Skip to content

Releases: terralang/terra

Release 1.2.0

25 Jun 18:04
cc543db
Compare
Choose a tag to compare

This release adds new LLVM versions and introduces experimental support for SPIR-V code generation. Note that as of the tested LLVM versions, LLVM's native SPIR-V backend is unable to generate correct SPIR-V code in all cases; but the LLVM SPIR-V target can still be used in combination with the LLVM/SPIR-V Translator to generate valid code.

Users who generate code for AMD GPUs are strongly encouraged to upgrade to LLVM 18 and ROCm 6.0.0, as previous version combinations generate bad code to varying degrees.

Added Features

  • Support for LLVM 17 and 18
  • Experimental support for SPIR-V code generation (e.g., for Intel GPUs)

Fixed Bugs

  • Updated LuaJIT to obtain fix for passing large arrays on macOS M1

Removed Features

  • Removed support for LLVM <= 10
  • Removed the long-deprecated Makefile build

Known Issues

  • #671: When using LLVM >= 17 in JIT mode, Terra is unable to inline functions with :setinlined(true). There are two available workarounds:
    1. Use terralib.saveobj(...) to dump a .o, .so or executable file. This will apply the full optimization suite required to inline these functions.
    2. Build from source or use binaries with LLVM <= 16

Binaries

Binaries for this release were produced in the following configurations:

  • Linux: x86_64 on Ubuntu 18.04 with LLVM 18 and CUDA 11.6 (verified to work on Ubuntu 20.04, 22.04 and 24.04)
    • Note: binaries with LLVM 16 are also provided to work around the above known issue
  • Linux: PPC64le on Ubuntu 18.04 with LLVM 13 (verified to work on POWER9 with RHEL 8)
  • Linux: AArch64 on Ubuntu 18.04 with LLVM 11 (verified to work on Ubuntu 22.04)
  • macOS: x86_64 on macOS 12 with LLVM 18 (verified to work on macOS 14.5)
  • Windows: x86_64 on Server 2022 with LLVM 11 and CUDA 11.6

Note that, while we do our best to make the binaries compatible across OS versions/distros, in general we cannot guarantee compatibility outside of the specified OS release (except where otherwise noted).

Release 1.1.1

23 Aug 05:29
094c5ad
Compare
Choose a tag to compare

This is a bug fix release that addresses a miscompilation related to globals imported from C.

Fixed Bugs

  • Fixed miscompilation of nested arrays included via C headers.

Binaries

Binaries for this release were produced in the following configurations:

  • Linux: x86_64 on Ubuntu 18.04 with LLVM 13 and CUDA 11.6 (verified to work on Ubuntu 20.04 and 22.04)
  • Linux: PPC64le on Ubuntu 18.04 with LLVM 13 (verified to work on POWER9 with RHEL 8)
  • Linux: AArch64 on Ubuntu 18.04 with LLVM 11 (verified to work on Ubuntu 22.04)
  • macOS: x86_64 on macOS 11 with LLVM 13 (verified to work on macOS 13.3)
  • macOS: AArch64 on macOS 13 with LLVM 13
  • Windows: x86_64 on Server 2022 with LLVM 11 and CUDA 11.6

Note that, while we do our best to make the binaries compatible across OS versions/distros, in general we cannot guarantee compatibility outside of the specified OS release (except where otherwise noted).

Release 1.1.0

05 May 20:52
be89521
Compare
Choose a tag to compare

This release brings Terra up to date with LLVM releases and deprecates/removes some older LLVM versions. No breaking changes are expected.

Added features

  • Support for LLVM 15 and 16

Improvements

  • Fixes for WASM calling convention
  • Fixes for tests on macOS 13
  • Fixes for 32-bit ARM on Linux (note this configuration is still experimental)
  • Verify SHA-256 hashsums of all downloads in CMake build

Deprecated features

  • Deprecated support for LLVM <= 10

Removed features

  • Removed support for LLVM <= 5

Binaries

Binaries for this release were produced in the following configurations:

  • Linux: x86_64 on Ubuntu 18.04 with LLVM 13 and CUDA 11.6 (verified to work on Ubuntu 20.04 and 22.04)
  • Linux: PPC64le on Ubuntu 18.04 with LLVM 13 (verified to work on POWER9 with RHEL 8)
  • Linux: AArch64 on Ubuntu 18.04 with LLVM 11 (verified to work on Ubuntu 22.04)
  • macOS: x86_64 on macOS 11 with LLVM 13 (verified to work on macOS 13.3)
  • macOS: AArch64 on macOS 13 with LLVM 13
  • Windows: x86_64 on Server 2022 with LLVM 11 and CUDA 11.6

Note that, while we do our best to make the binaries compatible across OS versions/distros, in general we cannot guarantee compatibility outside of the specified OS release (except where otherwise noted).

Release 1.0.6

06 Sep 20:48
Compare
Choose a tag to compare

This release stabilizes support for macOS M1 (AArch64). Terra now passes 100% of the test suite on this hardware.

Changed behaviors

  • Terra previously allowed terralib.atomicrmw("xchg", ...) to be used with pointers. This was a mistake; LLVM does not allow this and LLVM IR with this instruction is invalid. Terra now correctly issues a type error in this situation.

Improvements

  • Fixes for macOS on M1 hardware, allowing Terra to pass 100% of the test suite.
  • Automated testing is now performed regularly on PPC64le hardware.

Known Issues

  • On AArch64, Terra requires LLVM 11 or older. Newer LLVM versions result in segfaults on some tests.

Binaries

Binaries for this release were produced in the following configurations:

  • Linux: x86_64 on Ubuntu 18.04 with LLVM 13 and CUDA 11.6 (verified to work on Ubuntu 20.04 and 22.04)
  • Linux: PPC64le on Ubuntu 18.04 with LLVM 13 (verified to work on POWER9 with RHEL 8)
  • Linux: AArch64 on Ubuntu 18.04 with LLVM 11 (verified to work on Ubuntu 22.04)
  • macOS: x86_64 on macOS 11 with LLVM 13 (verified to work on macOS 12.4)
  • Windows: x86_64 on Server 2022 with LLVM 11 and CUDA 11.6

Note that, while we do our best to make the binaries compatible across OS versions/distros, in general we cannot guarantee compatibility outside of the specified OS release (except where otherwise noted).

Release 1.0.5

17 Aug 04:24
f85f743
Compare
Choose a tag to compare

This release stabilizes support for ARM (AArch64). On a variety of hardware (Graviton, NVIDIA Jetson), Terra now passes 100% of the test suite.

Improvements

  • Fixes for multiple issues on AArch64, allowing Terra to pass 100% of the test suite.
  • Updated LuaJIT to obtain fixes for AArch64.

Known Issues

  • On AArch64, Terra requires LLVM 11 or older. Newer LLVM versions result in segfaults on some tests.

Binaries

Binaries for this release were produced in the following configurations:

  • Linux: x86_64 on Ubuntu 18.04 with LLVM 13 and CUDA 11.6 (verified to work on Ubuntu 20.04 and 22.04)
  • Linux: PPC64le on Ubuntu 18.04 with LLVM 13 (verified to work on POWER9 with RHEL 8)
  • Linux: AArch64 on Ubuntu 18.04 with LLVM 11 (verified to work on Ubuntu 22.04)
  • macOS: x86_64 on macOS 11 with LLVM 13 (verified to work on macOS 12.4)
  • Windows: x86_64 on Server 2022 with LLVM 11 and CUDA 11.6

Note that, while we do our best to make the binaries compatible across OS versions/distros, in general we cannot guarantee compatibility outside of the specified OS release (except where otherwise noted).

Release 1.0.4

08 Jul 20:30
Compare
Choose a tag to compare

This release stabilizes support for PPC64le. On POWER9 hardware, Terra now passes 100% of the test suite. This comes with one large caveat: Terra relies on Moonjit, a fork of LuaJIT, for support for PPC64le. At the time of this release, Moonjit has no active maintainers. Therefore, while Terra itself provides comprehensive support for PPC64le, we are not in a position to fix issues in the Moonjit implementation.

Improvements

  • Fixes for multiple issues on PPC64le, allowing Terra to pass 100% of the test suite.

Binaries

Binaries for this release were produced in the following configurations:

  • Linux: x86_64 on Ubuntu 18.04 with LLVM 13 and CUDA 11.6 (verified to work on Ubuntu 20.04 and 22.04)
  • Linux: PPC64le on Ubuntu 18.04 with LLVM 13 (verified to work on POWER9 with RHEL 8)
  • macOS: x86_64 on macOS 10.15 with LLVM 13 (verified to work on macOS 12.4)
  • Windows: x86_64 on Server 2022 with LLVM 11 and CUDA 11.6

Note that, while we do our best to make the binaries compatible across OS versions/distros, in general we cannot guarantee compatibility outside of the specified OS release (except where otherwise noted).

Experimental binaries

In addition, the following experimental binaries are available. These platforms do NOT pass 100% of the Terra test suite, and are being provided on an as-is basis for interested users. Your specific mileage may vary depending on what Terra features you use.

  • Linux: ARM64 on Ubuntu 18.04 with LLVM 13 (verified on Ubuntu 22.04: passes about 96% of tests)

Release 1.0.3

01 Jul 18:04
Compare
Choose a tag to compare

This release contains no feature changes, but includes bug fixes for the Terra calling convention on PPC64le for passing arrays by value.

Improvements

  • Fixes for the Terra calling convention on PPC64le for passing arrays by value.

Binaries

Binaries for this release were produced in the following configurations:

  • Linux: x86_64 on Ubuntu 18.04 with LLVM 13 and CUDA 11.6 (verified to work on Ubuntu 20.04 and 22.04)
  • macOS: x86_64 on macOS 10.15 with LLVM 13 (verified to work on macOS 12.4)
  • Windows: x86_64 on Server 2022 with LLVM 11 and CUDA 11.6

Note that, while we do our best to make the binaries compatible across OS versions/distros, in general we cannot guarantee compatibility outside of the specified OS release (except where otherwise noted).

Experimental binaries

In addition, the following experimental binaries are available. These platforms do NOT pass 100% of the Terra test suite, and are being provided on an as-is basis for interested users. Your specific mileage may vary depending on what Terra features you use.

  • Linux: ARM64 on Ubuntu 18.04 with LLVM 13 (verified on Ubuntu 22.04: passes about 96% of tests)
  • Linux: PPC64le on Ubuntu 18.04 with LLVM 13 (verified on RHEL 8: passes about 98.5% of tests)

Release 1.0.2

26 Jun 06:02
Compare
Choose a tag to compare

This release includes improvements to make Terra better match Unix-like system conventions, as well as substantial improvements to C calling convention conformance on PPC64le.

Changed behaviors

  • Terra historically installed its shared library as terra.so or terra.dylib on Unix-like systems. This is for compatibility with Lua, which allows a module be loaded as require("terra") if terra.so (or terra.dylib, depending on the system) is present. However, this conflicts with the Unix standard of having libraries prefixed with lib. In this release, Terra installs its shared library as libterra.so or libterra.dylib, and installs a symlink for terra.so or terra.dylib for backwards compatibility. (Behavior on Windows and with static libraries is unchanged.)

Improvements

  • Substantially improved C calling convention conformance on PPC64le, along with a new conformance test that matches behavior against C for all primitive types (uint8, int16, int32, ...) and structs/arrays of those types, up to a bound. Successfully tested on POWER9 hardware up to N = 23. Current test suite pass rate on this hardware is 98.5%.

Binaries

Binaries for this release were produced in the following configurations:

  • Linux: x86_64 on Ubuntu 18.04 with LLVM 13 and CUDA 11.6 (verified to work on Ubuntu 20.04 and 22.04)
  • macOS: x86_64 on macOS 10.15 with LLVM 13 (verified to work on macOS 12.4)
  • Windows: x86_64 on Server 2022 with LLVM 11 and CUDA 11.6

Note that, while we do our best to make the binaries compatible across OS versions/distros, in general we cannot guarantee compatibility outside of the specified OS release (except where otherwise noted).

Experimental binaries

In addition, the following experimental binaries are available. These platforms do NOT pass 100% of the Terra test suite, and are being provided on an as-is basis for interested users. Your specific mileage may vary depending on what Terra features you use.

  • Linux: ARM64 on Ubuntu 18.04 with LLVM 13 (verified on Ubuntu 22.04: passes about 96% of tests)
  • Linux: PPC64le on Ubuntu 18.04 with LLVM 13 (verified on RHEL 8: passes about 98.5% of tests)

Release 1.0.1

14 Jun 03:16
Compare
Choose a tag to compare

This release includes no major Terra changes, but upgrades the LuaJIT dependency and makes available (experimental) binaries for ARM64 and PPC64le.

Changed behaviors

  • The default Lua has been set back to LuaJIT for all platforms other than PPC64le (where it is still set to Moonjit). As before, this can be configured explicitly with the CMake flag -DTERRA_LUA with either luajit or moonjit

Experimental features added

  • Binary builds for ARM64 and PPC64le. These platforms were already possible to build from source, but this makes them easier to try out. Note the test suite pass rate is about 96% for ARM64 and 98% for PPC64le. You mileage may vary depending on what features of Terra you use

Binaries

Binaries for this release were produced in the following configurations:

  • Linux: x86_64 on Ubuntu 18.04 with LLVM 13 and CUDA 11.6 (verified to work on Ubuntu 20.04 and 22.04)
  • macOS: x86_64 on macOS 10.15 with LLVM 13 (verified to work on macOS 12.4)
  • Windows: x86_64 on Server 2022 with LLVM 11 and CUDA 11.6

Note that, while we do our best to make the binaries compatible across OS versions/distros, in general we cannot guarantee compatibility outside of the specified OS release (except where otherwise noted).

Experimental binaries

In addition, the following experimental binaries are available. These platforms do NOT pass 100% of the Terra test suite, and are being provided on an as-is basis for interested users. Your specific mileage may vary depending on what Terra features you use.

  • Linux: ARM64 on Ubuntu 18.04 with LLVM 13 (verified on Ubuntu 22.04: passes about 96% of tests)
  • Linux: PPC64le on Ubuntu 18.04 with LLVM 13 (verified on RHEL 8: passes about 98% of tests)

Release 1.0.0

08 Jun 18:43
Compare
Choose a tag to compare

This release recognizes what has already been true for quite some time: Terra is mature and has been tested in a variety of production environments. As a result, the version numbers are changing with this release to follow our stability policy, starting with version number 1.0.0. Terra is expected to remain at 1.x for the forseeable future.

The following changes are included in this release:

Added features

  • Support for LLVM 3.8, 3.9, 5, 6, 7, 8, 9, 10, 11, 12, 13 and 14
  • Support for CUDA 9, 10 and 11
  • Support for Visual Studio 2015, 2017, 2019 and 2022 on Windows
  • Support for FreeBSD
  • New CMake-based build system replaces Make/NMake on all platforms
  • Upgrade to LuaJIT 2.1 (from Git) by default
  • Added optional support for Moonjit, a LuaJIT fork that works on PPC64le
  • Added terralib.linkllvmstring to link bitcode modules directly from memory
  • Allow types defined via ffi.cdef to be used as Terra types as well
  • Support for "module" definitions in ASDL, which allow ASTs to be namespaced
  • Added command line flag -e to evaluate a Terra expression
  • Added terralib.version which contains the version string, or unknown if this can't be detected
  • Added optimize flag to terralib.saveobj to specify an optimization profile. Currently optimization profiles can be used to disable optimizations, or to enable fast-math flags
  • Added support for all fast-math optimizations supported by LLVM
  • Added support for :setcallingconv() on Terra functions to set the calling convention (with any supported LLVM calling convention)

Experimental features added

  • Added terralib.atomicrmw to support atomic read-modify-write operations
  • Added terralib.fence to support fence operations
  • Added switch statement
  • Added support for AMD GPU code generation (with LLVM 13 and up)
  • Added support for Nix derivation, and merged upstream into NixOS

Deprecated features

  • Deprecated support for Make (Linux, macOS, FreeBSD) build system
  • Deprecated support for LLVM 3.8, 3.9 and 5

Removed features

  • Removed support for all LLVM versions 3.7 and prior
  • Removed support for NMake (Windows) build system

Changed behaviors

  • Errors are printed to stderr instead of stdout

Infrastructure improvements

  • Automated tests with GitHub Actions (Linux, macOS, Windows), Cirrus (FreeBSD) and AppVeyor (Windows)
  • Automated tests for various Linux distros (currently Ubuntu 18.04, 20.04, 22.04) via Docker
  • Automated Linux "compability" tests (cross-distro-version tests for binary compatibility)
  • Automated release build infrastructure

Bug fixes

  • Fixes for nontemporal loads and stores
  • Fixes for link errors due to multiple definitions of internal functions in different modules
  • Fixes for Windows default include path handling
  • Fix errors in parsing constants from macros
  • Fix bugs in constant checking
  • Fix auto-detection of AVX support
  • Fixes for building on FreeBSD
  • Fix auto-detection of library type when file name ends in [^.]bc
  • Fixes for PPC64le
  • Fixes for AMD GPU
  • Fixes for performance regressions in NVIDIA CUDA code generation in LLVM 13 (as compared to LLVM 3.8, the last release that supported NVVM)

Binaries

Binaries for this release were produced in the following configurations:

  • Linux: x86_64 on Ubuntu 18.04 with LLVM 13 and CUDA 11.6 (verified to work on Ubuntu 20.04 and 22.04)
  • macOS: x86_64 on macOS 10.15 with LLVM 13 (verified to work on macOS 12.4)
  • Windows: x86_64 on Server 2022 with LLVM 11 and CUDA 11.6

Note that, while we do our best to make the binaries compatible across OS versions/distros, in general we cannot guarantee compatibility outside of the specified OS release (except where otherwise noted).