Skip to content

Conversation

augusto2112
Copy link

@augusto2112 augusto2112 commented Feb 10, 2024

Commit 1:

[DebugInfo] Emit spare bits mask in debug info The spare bits mask is a mask of the unused bits that a type may have. Swift uses these on enums to pack extra data when wrapping these enums in other types. Emit this field in LLVM-IR and DWARF. 

Commit 2:

[DebugInfo] Add an specification_of attribute to LLVM DebugInfo Add a specification_of attribute to LLVM DebugInfo, which is analogous to DWARF's DW_AT_specification. According to the DWARF spec: "A debugging information entry that represents a declaration that completes another (earlier) non-defining declaration may have a DW_AT_specification attribute whose value is a reference to the debugging information entry representing the non-defining declaration." This patch allows types to be specifications of other types. For example, a templated type where the template parameters are substituted in could be a specification of the non-substituted template type. 
@augusto2112
Copy link
Author

@swift-ci test

@augusto2112
Copy link
Author

@swift-ci test macOS

@augusto2112 augusto2112 force-pushed the spare-bits-mask-dwarf branch from 2979fe9 to 490b689 Compare February 15, 2024 18:54
@augusto2112
Copy link
Author

@swift-ci test

@augusto2112
Copy link
Author

@swift-ci test

@augusto2112 augusto2112 force-pushed the spare-bits-mask-dwarf branch from 020cd44 to d229f19 Compare February 15, 2024 22:23
@augusto2112
Copy link
Author

@swift-ci test

The spare bits mask is a mask of the unused bits that a type may have. Swift uses these on enums to pack extra data when wrapping these enums in other types. Emit this field in LLVM-IR and DWARF.
@augusto2112 augusto2112 force-pushed the spare-bits-mask-dwarf branch from d229f19 to d0c5c44 Compare February 15, 2024 23:05
@augusto2112
Copy link
Author

@swift-ci test

@augusto2112
Copy link
Author

@swift-ci test Windows

1 similar comment
@augusto2112
Copy link
Author

@swift-ci test Windows

Add a specification_of attribute to LLVM DebugInfo, which is analogous to DWARF's DW_AT_specification. According to the DWARF spec: "A debugging information entry that represents a declaration that completes another (earlier) non-defining declaration may have a DW_AT_specification attribute whose value is a reference to the debugging information entry representing the non-defining declaration." This patch allows types to be specifications of other types. For example, a templated type where the template parameters are substituted in could be a specification of the non-substituted template type.
@augusto2112
Copy link
Author

@swift-ci test

@augusto2112
Copy link
Author

@swift-ci test Windows

@augusto2112 augusto2112 changed the title [DebugInfo] Emit spare bits mask in debug info [DebugInfo] Emit specifiction_of and spare bits mask in debug info Feb 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants