mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-23 03:02:36 +01:00
7e0c7ec095
As stated in section 6.1.1.2, DWARFv5, p. 142, | The last entry for each name is followed by a zero byte that | terminates the list. There may be gaps between the lists. The patch changes emitting a 4-byte zero value to a 1-byte one, which effectively removes the gap between entry lists, and thus saves approximately 3 bytes per name; the calculation is not exact because the total size of the table is aligned to 4. Differential Revision: https://reviews.llvm.org/D86927
25 lines
1012 B
LLVM
25 lines
1012 B
LLVM
; This checks that the list of index entries in the name index is terminated
|
|
; with a 1-byte value.
|
|
|
|
; RUN: llc -mtriple x86_64 -accel-tables=Dwarf -dwarf-version=5 -filetype=asm %s -o - | \
|
|
; RUN: FileCheck %s
|
|
|
|
; CHECK: .section .debug_names,"",@progbits
|
|
; CHECK: .Lnames_entries0:
|
|
; CHECK: .byte 0 # End of list: int
|
|
; CHECK: .byte 0 # End of list: foo
|
|
|
|
@foo = common dso_local global i32 0, align 4, !dbg !5
|
|
|
|
!llvm.dbg.cu = !{!2}
|
|
!llvm.module.flags = !{!0}
|
|
|
|
!0 = !{i32 2, !"Debug Info Version", i32 3}
|
|
!1 = !DIFile(filename: "foo.c", directory: "/tmp")
|
|
!2 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "Manual", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, enums: !3, globals: !4)
|
|
!3 = !{}
|
|
!4 = !{!5}
|
|
!5 = !DIGlobalVariableExpression(var: !6, expr: !DIExpression())
|
|
!6 = distinct !DIGlobalVariable(name: "foo", scope: !2, file: !1, line: 1, type: !7, isLocal: false, isDefinition: true)
|
|
!7 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
|