Skip to content

[5.0] stdlib: Make ArrayBufferProtocol.init inlinable to facilitate specialization #20800

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

aschwaighofer
Copy link
Contributor

Change the attribute of init(copying:) from @usableFromInline to
@inlinable to enable generic specialization. Resulting in a 2x speedup
of array copying.

This is not ABI affecting because both @usableFromInline and @inlinable
cause emission of the symbol in the standard library dylib.

This is a fix for a performance regression from a previously shipped
swift and it is not a correctness fix.

SR-9284
rdar://46277030

…pecialization

Change the attribute of init(copying:) from @usableFromInline to
@inlinable to enable generic specialization. Resulting in a 2x speedup
of array copying.

This is not ABI affecting because both @usableFromInline and @inlinable
cause emission of the symbol in the standard library dylib.

This is a fix for a performance regression from a previously shipped
swift and it is not a correctness fix.

SR-9284
rdar://46277030
@aschwaighofer aschwaighofer requested a review from a team as a code owner November 27, 2018 16:48
@aschwaighofer
Copy link
Contributor Author

@swift-ci Please test

@aschwaighofer
Copy link
Contributor Author

Not critical for convergence.

Copy link
Contributor

@eeckstein eeckstein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

@bob-wilson bob-wilson merged commit 6c7f80f into swiftlang:swift-5.0-branch Dec 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants