Skip to content

[CodeGen] Use std::bitset for MachineFunctionProperties #94627

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
merged 1 commit into from
Jun 6, 2024

Conversation

aengelke
Copy link
Contributor

@aengelke aengelke commented Jun 6, 2024

The size of the properties is fixed, so no need for a SmallVector. Assigning small, fixed-size bitsets is faster.

It's a minor performance improvement, see here.

The size of the properties is fixed, so no need for a SmallVector.

At most a minor improvement, though.
@arsenm
Copy link
Contributor

arsenm commented Jun 6, 2024

so no need for a SmallVector

This was a BitVector, not a SmallVector

Copy link
Contributor

@arsenm arsenm left a comment

Choose a reason for hiding this comment

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

LGTM with comment fixed

@aengelke aengelke merged commit c0a8fb2 into llvm:main Jun 6, 2024
6 of 8 checks passed
@aengelke aengelke deleted the perf/mfp-no-vector branch June 6, 2024 15:13
@aengelke
Copy link
Contributor Author

aengelke commented Jun 6, 2024

This was a BitVector, not a SmallVector

Yeah, fixed that, thanks. BitVector is implemented on the top of a SmallVector, though. ;)

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.

2 participants