mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-31 20:51:52 +01:00
[DWARF] Emit reasonable debug info for empty .s files.
llvm-svn: 352541
This commit is contained in:
parent
e15a520f8c
commit
e0007a64ee
@ -900,6 +900,9 @@ bool AsmParser::Run(bool NoInitialTextSection, bool NoFinalize) {
|
||||
eatToEndOfStatement();
|
||||
}
|
||||
|
||||
// Make sure we get proper DWARF even for empty files.
|
||||
(void)enabledGenDwarfForAssembly();
|
||||
|
||||
getTargetParser().onEndOfFile();
|
||||
printPendingErrors();
|
||||
|
||||
|
6
test/MC/AsmParser/debug-only-comments.s
Normal file
6
test/MC/AsmParser/debug-only-comments.s
Normal file
@ -0,0 +1,6 @@
|
||||
# RUN: llvm-mc -triple i386-linux-gnu -g -dwarf-version 4 < %s | FileCheck %s
|
||||
# RUN: llvm-mc -triple i386-linux-gnu -g -dwarf-version 5 < %s | FileCheck %s
|
||||
# CHECK: .section .debug_info
|
||||
# CHECK: .section .debug_info
|
||||
# CHECK-NOT: .section
|
||||
# CHECK: .ascii "<stdin>"
|
Loading…
x
Reference in New Issue
Block a user