Skip to content

Releases: llvm-swift/LLVMSwift

0.8.0

26 Mar 22:58
Compare
Choose a tag to compare

LLVMSwift now tracks LLVM 11.0.

⚠️ Breaking Changes Ahead ⚠️

  • Minimum tools versions have been bumped to LLVM 11.0 and Swift tools 5.2 (h/t @twof & @ThatsJustCheesy).
  • Non-default brew install locations are now supported by the utils/make-pkgconfig.swift script (h/t @eonil).
  • DIBuilder methods now require explicitly-specified alignments. They previously defaulted to 0-alignment, which violates the DWARF standard.
  • A sourceFilename may now be set on a Module. This value still defaults to the value of name. (h/t @ColMcp)
  • In accordance with recent LLVM changes, alignments of 0 (the default) passed to IRBuilder's buildAlloca, buildStore, and buildLoad will result in the target choosing a default alignment that is convenient and compatible with the type. This will impact output IR files, which previously left out default aligns altogether.
  • Per LLVM 10.0, unnamed function arguments now get printed with their automatically generated name (e.g. “i32 %0”) in IR function definitions.
  • DIBuilder.buildCompileUnit now accepts parameters for sysRoot and sdkRoot.
  • Fixed an issue where the |= and <<= operators were inverted for Size types.
  • Fixed issues in the behavior of Alignment.log2 for zero-alignments and 64-bit results.

0.7.0

10 Aug 10:51
Compare
Choose a tag to compare

LLVMSwift now tracks LLVM 9.

0.6.0

25 May 23:10
b876a1b
Compare
Choose a tag to compare

⚠️ Breaking Changes Ahead ⚠️

  • LLVMSwift now enforces deployment target constraints. In the future, we will continue to update this constraint in line with the LLVM homebrew package.
  • The PassPipeliner is now provided as an alternative to FunctionPassManager, which may crash if used in many common situations. Please migrate accordingly.
  • The FunctionPassManager is now deprecated
  • Documentation for core components continues to improve
  • An analog to LLVM’s infamous target Triple API has been added. APIs that previously dealt with Strings have been updated accordingly
  • The bindings to ObjectFile were not correct and were not nearly feature-rich enough. The API has been completely overhauled
  • The IRInstruction protocol has been added to unify instruction values around a common protocol.
  • Metadata can now be attached to instructions
  • The debug location accessor now supports being reset to nil without crashing
  • DIFile now exposes file metadata, and file metadata now exposes its source text, directory, and name
  • The Metadata Builder facility (MDBuilder) has been ported from LLVM
  • Additional bit-manipulation primitives for setting and clearing bits and getting leading and trailing 1’s counts have been added to APInt
  • The labels on FunctionType's initializer have been removed
  • The internalize pass has been added
  • All SROA passes no longer differentiate between their parameters. They are now deprecated - SROA is available under with the unified scalarReplacementOfAggregates pass

0.5.0

22 Mar 16:15
78d734e
Compare
Choose a tag to compare

LLVMSwift now tracks LLVM 8.0

  • Convenience bindings to common memory intrinsics (memcpy/memset/memmove) and pointer/integral casts have been added
  • TargetData functions that used to take and return integers were deprecated last release. They are now removed. Please update to the corresponding functions using Size and Alignment.
  • More bindings to optimizer passes have been added
  • Support for the JIT on Linux has been restored
  • The value type of a global value is now accessible
  • A new API for retrieving and attaching metadata to global values and instructions has been added.
  • The new APInt type provides arbitrary precision integral arithmetic that is compatible with LLVM values
  • BasicBlock is now Equatable

Intrinsics

LLVMSwift finally supports intrinsics! For more information, see Intrinsics.

0.4.1

25 Feb 20:43
e4aa37b
Compare
Choose a tag to compare
  • Convenience functions to insert the llvm.dbg.declare and llvm.dbg.value intrinsics have been added to the DIBuilder
  • Inline assembly builders have been improved. Notably, the choice of syntax is now customizable.
  • Bindings for inserting and manipulating module-level debug information flags has been added.
  • Bindings for a few missing optimization passes have been added
  • A crash in the setter for a module's link name has been resolved (h/t @matthewseaman)
  • All concrete instances of IRTypes are now equatable. Values of IRType may be compared directly but are not themselves Equatable.

0.4.0

08 Nov 00:39
fca99fe
Compare
Choose a tag to compare

LLVMSwift now tracks LLVM 7.0

In addition to breaking a lot of APIs, our upgrade path to LLVM 7.0 coincides with the first removals of deprecated APIs in LLVMSwift. Without further ado

⚠️ Breaking Changes Ahead ⚠️

  • LLVMSwift now supports Swift 4.2 and the Swift 4.2 tooling and package manager
  • cllvm has been internalized to LLVMSwift. The separate repository has been archived and will no longer be maintained.
  • The CallingConvention enumeration has drastically expanded
  • APIs for COMDAT support have been added
  • The IRConstant protocol has been added, and all global values now conform to it.
  • The return type of APIs that return constants have been refined to use IRConstant where possible
  • Constant GEP, sign extension, and bitcasting APIs have been aded
  • Restrictions on function attributes have been completely lifted
  • Documentation for ThreadLocalModels has drastically expanded and is much more accurate
  • UnnamedAddress now supports local unnamed addresses
  • Routines for adding globals have been moved from IRBuilder to Module where they belong
  • StructType now includes accessors for its opacity and whether it was created with bitpacking or not.
  • The Size and Alignment unit values have been added. Like clang's CharUnits, they prevent bugs with mixed-unit arithmetic and make it convenient to work with byte-level calculations.
  • APIs that used to take and return integers now speak in terms of Size and Alignment. Notably, TargetData's functions that used to take and return integers now take and return Size and Alignment. The old forms are now deprecated
  • The StructLayout enum has been ported from LLVM to provide convenient access to the layout of StructTypes.
  • Accessors for many more attributes of TargetMachine have been added.
  • The Targets supported by a TargetMachine are now enumerable.

ORCJIT

LLVMSwift has migrated JIT to ORCJIT this release. To do so, we have completely removed and rewritten the old API. The ORCJIT will continue to evolve and stabilize over the next several LLVM releases.

Debug Information

Last but not least, LLVMSwift now includes a nearly feature-complete implementation of LLVM's debug information APIs. It's been a long time coming, but creating and attaching metadata to IRValues is now a reality!

0.3.0

16 Apr 23:38
e7c190e
Compare
Choose a tag to compare

⚠️ Breaking Changes Ahead ⚠️

LLVMSwift now requires LLVM 6.0 and Swift 4.1 to build.

In exchange, MetadataType and TokenType now have working initializers.

0.2.3: Merge pull request #126 from kyouko-taiga/llvmattributeref-api

13 Mar 23:00
a9581c7
Compare
Choose a tag to compare

Support for the modern LLVM attribute API.

⚠️ Breaking Changes Ahead ⚠️

This is the last release of LLVMSwift that will fully support LLVM 5.0.

0.2.2: Merge pull request #125 from CodaFi/whats-up-doc

19 Feb 00:08
adc94d2
Compare
Choose a tag to compare
  • Resolves an issue where MCJIT was not linked-into the calling process.
  • Documentation fixes
  • Additional constant operations to support load-time inert references

Fix SwiftPM Versioning

30 Oct 14:19
1e1f638
Compare
Choose a tag to compare

We saw some issues with SwiftPM versioning of this project's dependencies. They now track explicit versions instead of master, so we can avoid transitive dependency issues.