Skip to content

[clang][Modules] Fix the Size of RecordDecl's BitCodeAbbrevOp #10511

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

curmudg-eon
Copy link

(llvm/llvm-project PR#133500)

https://github.com/llvm/llvm-project/pull/102040/files#diff-125f472e690aa3d973bc42aa3c5d580226c5c47661551aca2889f960681aa64dR2477 added 1 bit to RecordDecl's serialization format, but did not increment its abbreviation size.

This can lead to rare cases where a record may overflow if the RecordDecl's getArgPassingRestrictions() returns something bigger than 1 (see
here).

rdar://143763558
(cherry picked from commit 4a73c99)

…vm#133500)

https://github.com/llvm/llvm-project/pull/102040/files#diff-125f472e690aa3d973bc42aa3c5d580226c5c47661551aca2889f960681aa64dR2477
added 1 bit to `RecordDecl`'s serialization format, but did not
increment its abbreviation size.

This can lead to rare cases where a record may overflow if the
`RecordDecl`'s `getArgPassingRestrictions()` returns something bigger
than 1 (see
[here](https://github.com/llvm/llvm-project/blob/b3f01a6aa45b00240cec1c64286b85d7ba87e2af/clang/lib/Serialization/ASTWriterDecl.cpp#L688)).

rdar://143763558
(cherry picked from commit 4a73c99)
@qiongsiwu qiongsiwu self-requested a review April 18, 2025 21:24
Copy link

@qiongsiwu qiongsiwu left a comment

Choose a reason for hiding this comment

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

Cherry-pick LGTM! Thanks!

@qiongsiwu
Copy link

@swift-ci please test llvm

@qiongsiwu
Copy link

@swift-ci please test

@bnbarham bnbarham merged commit 35aa802 into swiftlang:stable/20250402 Apr 18, 2025
2 of 5 checks passed
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