Commit Graph

7 Commits

Author SHA1 Message Date
Arnold Schwaighofer
9795f65145 Change tests to also test that this feature is available per default 2025-11-07 10:10:47 -08:00
Arnold Schwaighofer
25a071efc8 Add experimental feature @inline(always)
The intent for `@inline(always)` is to act as an optimization control.
The user can rely on inlining to happen or the compiler will emit an error
message.

Because function values can be dynamic (closures, protocol/class lookup)
this guarantee can only be upheld for direct function references.

In cases where the optimizer can resolve dynamic function values the
attribute shall be respected.

rdar://148608854
2025-09-30 08:36:26 -07:00
Erik Eckstein
7a2a4024cd SILGen: Closures within @inline(__always) functions should be always inlined, too
rdar://106046747
2023-03-09 06:51:54 +01:00
Michael Gottesman
40a09c9c21 Fixup tests for -assume-parsing-unqualified-ownership-sil => [ossa] transition. 2018-12-18 00:49:32 -08:00
Michael Gottesman
9e13779702 [ownership] Remove most -enable-sil-ownership from SILGen now that %target-swift-emit-silgen does it automatically.
I did this using a sed pattern and verified by hand that I was only touching
target-swift-emit-silgen lines.
2018-12-13 11:54:54 -08:00
Slava Pestov
22c6d4e84f SILGen: Remove debug code from inline_always test 2018-11-16 23:18:37 -05:00
Slava Pestov
f715421e9d SILGen: add tests for @inline(__always) 2018-11-15 16:10:52 -05:00