github ldc-developers/ldc v1.42.0-beta2
LDC 1.42.0-beta2

pre-release5 hours ago

(Changes since 1.42.0-beta1 are marked with (new).)

Big news

  • Frontend, druntime and Phobos are at version 2.112.1+, incl. new command-line options -extI, -dllimport=externalOnly and -edition. (#4949, #4962, #4988, #5029, #5042, #5046, #5051) (new)
  • Support for LLVM 21. The prebuilt packages use v21.1.8. (#4950, #5033) (new)
  • New prebuilt package for Alpine Linux aarch64 with musl libc, analogous to the existing x86_64 package. (#4943)
  • Breaking change for dcompute: The special @kernel UDA is now a function and requires parentheses as in @kernel() void foo(){}. Optionally you can provide launch dimensions, @kernel([2,4,8]), to specify to the compute runtime how the kernel is intended to be launched.
  • ldc2.conf can now be a directory. All the files inside it, ordered naturally, will be concatenated and treated like a big config. (#4954)
    • Running ldc-build-runtime --installWithSuffix now includes installing a target-specific .conf file to that directory. (#4978)
  • Breaking change for ldc2.conf cmake generation: The cmake build process now generates the ldc2.conf and ldc2_install.conf as directories. ldc2*.conf.in and ADDITIONAL_DEFAULT_LDC_SWITCHES have been removed, if you need to add switches check out makeConfSection in LdcConfig.cmake. (#4954)
  • When cross-compiling, the fallback value for the (cross) C compiler will be picked based on some heuristics.
    The old behavior was to default to cc.
    As an example, when cross-compiling for aarch64-linux-gnu the compilers that are checked are:
    • aarch64-linux-gnu-gcc
    • aarch64-linux-gnu-clang
    • clang --target=aarch64-linux-gnu
  • The prebuilt arm64/universal macOS packages additionally bundle the arm64 iOS-simulator libraries, for out-of-the-box cross-compilation support via e.g. -mtriple=arm64-apple-ios12.0-simulator. (#4974)
  • New --fdebug-prefix-map command-line option and changed debuginfo file/directory name splitting logic (both now similar to clang), to aid reproducible builds. (#5039) (new)

Platform support

  • Supports LLVM 15 - 21.
  • PowerPC64: real now matches the C++ host compiler's long double when compiling for the native target, not just on Linux hosts. (#5054) (new)

Don't miss a new ldc release

NewReleases is sending notifications on new releases.