Skip to content

[Bitcode] Use DenseSet instead of std::set (NFC) #105851

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

Merged

Conversation

kazutakahirata
Copy link
Contributor

DefOrUseGUIDs is used only for membership checking purposes. We don't
need std::set's strengths like iterators staying valid or the ability
to traverse in a sorted order.

While I am at it, this patch replaces count with contains for slightly
increased readability.

DefOrUseGUIDs is used only for membership checking purposes.  We don't
need std::set's strengths like iterators staying valid or the ability
to traverse in a sorted order.

While I am at it, this patch replaces count with contains for slightly
increased readability.
Copy link
Contributor

@teresajohnson teresajohnson left a comment

Choose a reason for hiding this comment

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

lgtm but can you fix the description - it is switching from std::set not std::map

@kazutakahirata kazutakahirata changed the title [Bitcode] Use DenseSet instead of std::map (NFC) [Bitcode] Use DenseSet instead of std::set (NFC) Aug 23, 2024
@kazutakahirata
Copy link
Contributor Author

lgtm but can you fix the description - it is switching from std::set not std::map

Thanks! Fixed.

@kazutakahirata kazutakahirata merged commit 3b703d4 into llvm:main Aug 23, 2024
7 of 9 checks passed
@kazutakahirata kazutakahirata deleted the cleanup_001_DenseSet_DefOrUseGUIDs branch August 23, 2024 21:19
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.

3 participants