LDC 1.14.0 釋出,高效能 dlang 編譯器
LDC 是一個高效能的 D 語言編譯器。LDC 1.14.0 新版本更新亮點如下:
-
支援 D 語言最新版本 2.084.1.
-
增強對 WebAssembly 的相容性
-
改進 Windows 32 位系統安裝包形式
-
纖程改進
-
其他穩定性提升
完整更新日誌(英文)
Big news
-
Frontend, druntime and Phobos are at version2.084.1
, incl. new command-line options
-mixin
,-{enable,disable}-switch-errors
and-checkaction
. (#2946 ,#2977 ,#2999 )(new)-
Options
-release
,-d-debug
and-unittest
don't override preceding, more specific options (-{enable,disable}-{asserts,invariants,preconditions,postconditions,contracts}
) anymore.
-
Options
-
Linking WebAssembly doesn't require
-link-internally
(integrated LLD) anymore; an external linker (default:wasm-ld
, override with-linker
) can be used as well. (#2951 ) - Prebuilt Windows packages include LTO-able 32-bit druntime/Phobos too (previously: Win64 only).
-
AddressSanitizer support for fibers (requiresrebuilding the runtime libraries
with CMake option
RT_SUPPORT_SANITIZERS=ON
). (#2975 ,ldc-developers/druntime#152 )(new) -
Support
pragma(LDC_extern_weak)
for function declarations - if the function isn't available when linking, its address is null. (#2984 )(new)
Platform support
- Supports LLVM 3.9 - 7.0.
Bug fixes
-
Fix C++ mangling regression for functions with multiple
real
parameters introduced with v1.13, preventing to build DMD. (#2954 ,dlang/dmd#9129 ) - Fix context of some nested aggregates. (#2960 ,#2969 )
- Support templated LLVM intrinsics with vector arguments. (#2962 ,#2971 )
-
Avoid crashes with
-allinst
(fix emission of only speculatively nested functions). (#2932 ,#2940 ) - Fix XRay support for LLVM 7+. (#2965 )
- AArch64: Fix DMD-style profile measurements. (#2950 )
-
Be less picky about placement of pragmas (allow intermediate
extern(C)
etc.). (#2599 ) -
MSVC: Fix
real
C++ mangling to match Visual C++long double
. (#2974 ) - Fix bad ICE noticed when building protobuf-d. (#2990 ,#2992 )(new)
- Fix ICE when directly indexing vector return value. (#2988 ,#2991 )(new)
- Fix identity comparisons of complex numbers. (#2918 ,#2993 )(new)
-
MIPS32 fix for
core.stdc.stdarg
. (#2989 ,ldc-developers/druntime#153 )(new) -
Fix
core.atomic.cas()
for 64-bit floating-point values. (#3000 ,#3001 )(new) - beta1 regression: 'Instruction does not dominate all uses' (#2996 ,#2997 )(new)
Known issues
-
Buggy older
ld.bfd
linker versions may wrongly strip out required symbols, e.g., ModuleInfos (so that e.g. no module ctors/dtors are run). LDC defaults told.gold
on Linux. -
LDC does not zero the padding area of a
real
variable. This may lead to wrong results if the padding area is also considered. See#770 . Does not apply toreal
members inside structs etc.