forked from llvm/llvm-project
-
Notifications
You must be signed in to change notification settings - Fork 344
Create new CAS Blocks to represent missing DWARF sections #8576
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
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@swift-ci please test llvm |
72a755a
to
363b8f0
Compare
In MCCAS we use MCCASBuilder::mergeMCFragmentContents to merge the contents of DWARF sections before doing optimizations on them for deduplication, while most sections only use MCDataFragments, some other sections can use other kinds of fragments, make sure we support all MCEncodedFragmentWithContents types.
363b8f0
to
a04f8d8
Compare
@swift-ci please test llvm |
MCCAS DWARF section materialization and creation can have a lot of redundant code for most sections, this patch introduces some functions to reduce the code duplication.
MCCAS has an ability to have different block types for different data, this patch introduces DebugStrOffsetsRef and DebugStringOffsetsSectionRef to represent the debug_str_offsets section in DWARF5.
MCCAS has an ability to have different block types for different data, this patch introduces DebugLoclistsRef and DebugLoclistsSectionRef to represent the debug_loclists section in DWARF5.
MCCAS has an ability to have different block types for different data, this patch introduces DebugRangesRef and DebugRangesSectionRef to represent the debug_ranges section in DWARF4.
MCCAS has an ability to have different block types for different data, this patch introduces DebugLocRef and DebugLocSectionRef to represent the debug_str_loc section in DWARF4.
MCCAS has an ability to have different block types for different data, this patch introduces DebugRangelistsRef and DebugRangelistsSectionRef to represent the debug_rnglist section in DWARF5.
MCCAS has an ability to have different block types for different data, this patch introduces DebugLineStrRef and DebugLineStrSectionRef to represent the debug_line_str section in DWARF5.
MCCAS has an ability to have different block types for different data, this patch introduces DebugNamesRef and DebugNamesSectionRef to represent the debug_names section in DWARF5.
MCCAS has an ability to have different block types for different data, this patch introduces DebugAppleNamesRef and DebugAppleNamesSectionRef to represent the apple_names section in DWARF4.
MCCAS has an ability to have different block types for different data, this patch introduces AppleTypesRef and AppleTypesSectionRef to represent the apple_types section in DWARF4.
MCCAS has an ability to have different block types for different data, this patch introduces AppleNamespaceRef and AppleNamespaceSectionRef to represent the apple_namepsac section in DWARF4.
a04f8d8
to
99db925
Compare
MCCAS has an ability to have different block types for different data, this patch introduces AppleObjCRef and AppleObjCSectionRef to represent the apple_objc section in DWARF4.
9f4e4e1
to
71bb893
Compare
felipepiovezan
approved these changes
Apr 22, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This patch adds support for representing any missing DWARF sections as their own unique CAS Blocks, namely:
apple_objc
apple_namepsac
apple_types
apple_names
debug_names
debug_line_str
debug_rnglist
debug_loc
debug_ranges
debug_loclists
debug_str_offsets