Commit Graph

5 Commits

Author SHA1 Message Date
Erik Eckstein
3f95ce9645 Optimizer: fix spelling of the Simplifiable protocol
Rename `Simplifyable` -> `Simplifiable`

NFC
2025-02-12 09:01:11 +01:00
Erik Eckstein
318c30895f Swift Optimizer: eliminate ARC operations on types which are marked as immortal
A type (mostly classes) can be attributed with `@_semantics("arc.immortal")`.
ARC operations on values of such types are eliminated.

This is useful for the bridged SIL objects in the swift compiler sources.
2023-03-14 21:07:03 +01:00
Erik Eckstein
f1095556c9 Swift SIL: let var UnaryInstruction.operand return an Operand and not a Value
To avoid confusion. Instead add specific getters for unary instructions with dedicated names.

NFC
2023-02-21 17:57:29 +01:00
Erik Eckstein
85210a4e91 Swift Optimizer: make some SILCombine optimizations available for the "Simplification" pass
* begin_cow_mutation
* global_value
* strong_retain and strong_release

So far, those simplifications did only run in SILCombine. Now they are also considered in the swift Simplification pass.
2023-02-09 06:50:05 +01:00
Erik Eckstein
ea746479ad SIL Optimizer: rename directory InstructionPasses -> InstructionSimplification 2023-01-16 16:16:51 +01:00