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-3764] Use IdentifierIDs in serialization's lookup tables #46349

Open
belkadan opened this issue Jan 27, 2017 · 0 comments
Open

[SR-3764] Use IdentifierIDs in serialization's lookup tables #46349

belkadan opened this issue Jan 27, 2017 · 0 comments
Labels
compiler The Swift compiler in itself improvement serialization Area → compiler: Serialization & deserialization

Comments

@belkadan
Copy link
Contributor

Previous ID SR-3764
Radar None
Original Reporter @belkadan
Type Improvement
Additional Detail from JIRA
Votes 0
Component/s Compiler
Labels Improvement, Serialization
Assignee None
Priority Medium

md5: 99588a280e62b5fc59fdb265fe8314b1

Issue Description:

Serialization has a number of OnDiskHashTables keyed by Identifiers. Rather than use the existing uniqued identifier table in the serialized archive, however, they're just using raw string data. This is unnecessary and will become more of a problem when we start including lookup tables for members of nominal types.

Instead, we should have both serialization and deserialization use the existing IdentifierID mechanism to reference identifiers from the unique table. This deserialization can happen fairly eagerly; deserializing an identifier is pretty cheap.

(Note that we do not need to do this for the "local decls" table, which is keyed by mangled names. These names are likely not uttered anywhere else, so uniquing them would be a waste.)

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
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 serialization Area → compiler: Serialization & deserialization
Projects
None yet
Development

No branches or pull requests

1 participant