Skip to content

[Sema] NFC: Expand TypeVar ID/GraphIndex to 32 bits #25818

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

davezarzycki
Copy link
Contributor

As an aside, I really wish these user visible limits were formalized and not side effects of internal compiler data structures.

@davezarzycki
Copy link
Contributor Author

@swift-ci please smoke test

Users are edging closer to the arbitrary but plausible 20-bit limit.
@davezarzycki davezarzycki force-pushed the auto_repack_TypeVariableType_bitfield branch from a5b29d3 to d0b221e Compare June 29, 2019 10:07
@davezarzycki davezarzycki changed the title [AST] NFC: auto repack TypeVariableType bitfield at compile time [Sema] NFC: Expand TypeVar ID/GraphIndex to 32 bits Jun 29, 2019
@davezarzycki
Copy link
Contributor Author

@xedin – After some thought, let's define this problem away instead of micro-optimizing the bit layout of TypeVariableTypes (and inviting subtle bugs later). The auto repacking I proposed only made sense if users were far away from bumping into any nontrivial limit.

@swift-ci please smoke test

Copy link
Contributor

@xedin xedin left a comment

Choose a reason for hiding this comment

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

Sure, that makes sense to me!

@xedin
Copy link
Contributor

xedin commented Jun 30, 2019

Let's run source compat suite just in case.

@xedin
Copy link
Contributor

xedin commented Jun 30, 2019

@swift-ci please test source compatibility

@davezarzycki davezarzycki merged commit 7d1772c into swiftlang:master Jun 30, 2019
@davezarzycki davezarzycki deleted the auto_repack_TypeVariableType_bitfield branch June 30, 2019 14:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants