Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[DebugInfo] Fix printing CIE offsets in EH FDEs.
While the value of the CIE pointer field in a DWARF FDE record is an offset to the corresponding CIE record from the beginning of the section, for EH FDE records it is relative to the current offset. Previously, we did not make that distinction when dumped both kinds of FDE records and just printed the same value for the CIE pointer field and the CIE offset; that was acceptable for DWARF FDEs but was wrong for EH FDEs. This patch fixes the issue by explicitly printing the offset of the linked CIE object. Differential Revision: https://reviews.llvm.org/D74613
- Loading branch information
1 parent
dcd89b3
commit bd2df13
Showing
11 changed files
with
39 additions
and
18 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# RUN: llvm-mc -triple i386-unknown-linux %s -filetype=obj -o - | \ | ||
# RUN: llvm-dwarfdump -debug-frame - | \ | ||
# RUN: FileCheck %s | ||
|
||
# CHECK: .debug_frame contents: | ||
# CHECK: 00000000 0000000c 12345678 FDE cie=<invalid offset> pc=00010000...00010010 | ||
|
||
.section .debug_frame,"",@progbits | ||
.long .LFDE0end-.LFDE0id # Length | ||
.LFDE0id: | ||
.long 0x12345678 # CIE pointer (invalid) | ||
.long 0x00010000 # Initial location | ||
.long 0x00000010 # Address range | ||
.LFDE0end: |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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