Big news
- Frontend, druntime and Phobos are at version 2.099.0+. (#3917, #3893, #3937)
- Support for LLVM 13. The prebuilt packages use v13.0.1. (#3842)
- On Linux, LDC doesn't default to the
ld.gold
linker anymore. The combination of LLVM 13 and older gold linkers can apparently cause problems. We recommend using LLD, e.g., via-linker=lld
or by setting your default/usr/bin/ld
symlink; it's significantly faster too. -linkonce-templates
is less aggressive by default now and IMHO production-ready. (#3924)- When linking manually (not via LDC) against shared druntime, it is now required to link the bundled
lib/ldc_rt.dso.o[bj]
object file into each binary. It replaces the previously Windows-specificdso_windows.obj
. (#3850) - Breaking
extern(D)
ABI change for all targets: formal parameters of non-variadic functions aren't reversed anymore, in line with the spec. For 32-bit x86, the first parameter is accordingly now potentially passed in EAX, not the last one. So non-variadicextern(D)
functions with multiple explicit parameters will break if expecting parameters in specific registers or stack slots, e.g., naked DMD-style inline assembly. (#3873, ldc-developers/phobos@3d725fc)
Bug fixes
- Linux: Make LTO work with LLD. (#3786, #3850)
- Windows: Fix most undefined symbols with
-dllimport=all
without-linkonce-templates
. (#3916, #3923, #3926, #3927, #3928, #3931, #3932) - Capture NRVO variable by ref for stack closures. (#3883, #3902)
- RISC-V: Use 128-bit quadruple
real
. (#3892)
Supported LLVM versions
- 6.0 up to 13.0.
Known issues
- When building LDC, old LDC 0.17.*/ltsmaster host compilers miscompile LDC ≥ 1.21, leading to potential segfaults of the built LDC. Ltsmaster can still be used to bootstrap a first compiler and then let that compiler compile itself. (#3354)