This is an archive of the discontinued LLVM Phabricator instance.

[DEBUGINFO] Do not output labels for empty macinfo sections.
ClosedPublic

Authored by ABataev on Feb 21 2018, 10:55 AM.

Details

Summary

If there is no debug info for macros, do not emit labels for empty
macinfo sections.

Diff Detail

Repository
rL LLVM

Event Timeline

ABataev created this revision.Feb 21 2018, 10:55 AM
probinson added inline comments.Feb 21 2018, 3:19 PM
test/DebugInfo/X86/empty_macinfo.ll
1 ↗(On Diff #135300)

Adding -dwarf-version 4 here would make me happy (the .debug_macinfo section goes away in DWARF v5).

7 ↗(On Diff #135300)

This depends on the order of sections, and can be made more robust pretty easily. Replace the second CHECK-NEXT with this:

; CHECK-NEXT: .section
; CHECK-NOT: .debug_macinfo
ABataev added inline comments.Feb 22 2018, 6:38 AM
test/DebugInfo/X86/empty_macinfo.ll
1 ↗(On Diff #135300)

Ok

7 ↗(On Diff #135300)

Ok, will do

ABataev updated this revision to Diff 135414.Feb 22 2018, 7:06 AM

Updated patch

This revision is now accepted and ready to land.Feb 22 2018, 8:01 AM
This revision was automatically updated to reflect the committed changes.