Skip to content
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

[SR-10294] convertBoolToDarwinBool and friends should be inlined #52694

Closed
Catfish-Man opened this issue Apr 3, 2019 · 2 comments
Closed

[SR-10294] convertBoolToDarwinBool and friends should be inlined #52694

Catfish-Man opened this issue Apr 3, 2019 · 2 comments
Assignees
Labels
compiler The Swift compiler in itself improvement standard library Area: Standard library umbrella

Comments

@Catfish-Man
Copy link
Member

Previous ID SR-10294
Radar None
Original Reporter @Catfish-Man
Type Improvement
Status Resolved
Resolution Done
Additional Detail from JIRA
Votes 0
Component/s Compiler, Standard Library
Labels Improvement
Assignee @Catfish-Man
Priority Medium

md5: 41f827cc81368edfdec58404eb29ab32

is blocked by:

  • SR-10318 Marking compiler-intrinsic bool conversion functions as @_transparent crashes the compiler

Issue Description:

From SmallString bridging:

+0x5a callq "DYLD-STUB$$*convertBoolToDarwinBoolean(*🙂"

It's a shame to pay for a whole stack frame and dyld stub just to convert 1 to 1 and 0 to 0.

@belkadan
Copy link
Contributor

belkadan commented Apr 4, 2019

We can probably just make convertBoolToDarwinBoolean @inline(__always) and call it a day.

@Catfish-Man
Copy link
Member Author

Sadly transparent causes compiler crashes and inline(__always) doesn't work.

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
compiler The Swift compiler in itself improvement standard library Area: Standard library umbrella
Projects
None yet
Development

No branches or pull requests

2 participants