93 lines
		
	
	
		
			3.0 KiB
		
	
	
	
		
			YAML
		
	
	
	
			
		
		
	
	
			93 lines
		
	
	
		
			3.0 KiB
		
	
	
	
		
			YAML
		
	
	
	
# RUN: yaml2obj %s | llvm-dwarfdump --statistics - | FileCheck %s
 | 
						|
 | 
						|
## Check that we are covering the situation when
 | 
						|
## sum of bytes in scope is a huge (uint64_t) number.
 | 
						|
##
 | 
						|
## The yaml represents this DWARF:
 | 
						|
##
 | 
						|
## DW_TAG_compile_unit
 | 
						|
##   DW_AT_low_pc	(0x0000000000000000)
 | 
						|
##   DW_AT_high_pc	(0x000000000000000b)
 | 
						|
##
 | 
						|
##   DW_TAG_subprogram
 | 
						|
##     DW_AT_low_pc	(0x0000000000000000)
 | 
						|
##     DW_AT_high_pc	(0x00000000ffffffff)
 | 
						|
##       DW_TAG_variable
 | 
						|
##         DW_AT_location	(0x00000023:
 | 
						|
##            [0x0000000000000003, 0x0000000000000005): DW_OP_reg2 RCX)
 | 
						|
##   DW_TAG_subprogram
 | 
						|
##     DW_AT_low_pc    (0x0000000000000000)
 | 
						|
##     DW_AT_high_pc   (0x00000000ffffffff)
 | 
						|
##     DW_TAG_variable
 | 
						|
##       DW_AT_location        (0x00000023:
 | 
						|
##             [0x0000000000000003, 0x0000000000000005): DW_OP_reg2 RCX)
 | 
						|
 | 
						|
# CHECK: "version": 9,
 | 
						|
# CHECK: "sum_all_variables(#bytes in parent scope)": 8589934590
 | 
						|
 | 
						|
--- !ELF
 | 
						|
FileHeader:
 | 
						|
  Class:   ELFCLASS64
 | 
						|
  Data:    ELFDATA2LSB
 | 
						|
  Type:    ET_EXEC
 | 
						|
  Machine: EM_X86_64
 | 
						|
Sections:
 | 
						|
  - Name:         .debug_loc
 | 
						|
    Type:         SHT_PROGBITS
 | 
						|
    AddressAlign: 0x01
 | 
						|
    Content:      '00000000000000000600000000000000010055000000000000000000000000000000000300000000000000050000000000000001005200000000000000000000000000000000'
 | 
						|
  - Name:         .debug_ranges
 | 
						|
    Type:         SHT_PROGBITS
 | 
						|
    AddressAlign: 0x01
 | 
						|
    Content:      '000000000000000003000000000000000500000000000000080000000000000000000000000000000000000000000000'
 | 
						|
DWARF:
 | 
						|
  debug_abbrev:
 | 
						|
    - Table:
 | 
						|
      - Code:     1
 | 
						|
        Tag:      DW_TAG_compile_unit
 | 
						|
        Children: DW_CHILDREN_yes
 | 
						|
        Attributes:
 | 
						|
          - Attribute: DW_AT_low_pc
 | 
						|
            Form:      DW_FORM_addr
 | 
						|
          - Attribute: DW_AT_high_pc
 | 
						|
            Form:      DW_FORM_data4
 | 
						|
      - Code:     2
 | 
						|
        Tag:      DW_TAG_subprogram
 | 
						|
        Children: DW_CHILDREN_yes
 | 
						|
        Attributes:
 | 
						|
          - Attribute: DW_AT_low_pc
 | 
						|
            Form:      DW_FORM_addr
 | 
						|
          - Attribute: DW_AT_high_pc
 | 
						|
            Form:      DW_FORM_data4
 | 
						|
      - Code:     3
 | 
						|
        Tag:      DW_TAG_variable
 | 
						|
        Children: DW_CHILDREN_no
 | 
						|
        Attributes:
 | 
						|
          - Attribute: DW_AT_location
 | 
						|
            Form:      DW_FORM_sec_offset
 | 
						|
  debug_info:
 | 
						|
    - Version:    4
 | 
						|
      AbbrOffset: 0x00
 | 
						|
      Entries:
 | 
						|
        - AbbrCode: 1 ## DW_TAG_compile_unit
 | 
						|
          Values:
 | 
						|
            - Value: 0x00 ## DW_AT_low_pc
 | 
						|
            - Value: 0x0b ## DW_AT_high_pc
 | 
						|
        - AbbrCode: 2 ## DW_TAG_subprogram
 | 
						|
          Values:
 | 
						|
            - Value: 0x00 ## DW_AT_low_pc
 | 
						|
            - Value: 0xFFFFFFFF ## DW_AT_high_pc
 | 
						|
        - AbbrCode: 3 ## DW_TAG_variable
 | 
						|
          Values:
 | 
						|
            - Value: 0x23 ## DW_AT_sec_offset
 | 
						|
        - AbbrCode: 0 ## NULL
 | 
						|
        - AbbrCode: 2 ## DW_TAG_subprogram
 | 
						|
          Values:
 | 
						|
            - Value: 0x00 ## DW_AT_low_pc
 | 
						|
            - Value: 0xFFFFFFFF ## DW_AT_high_pc
 | 
						|
        - AbbrCode: 3 ## DW_TAG_variable
 | 
						|
          Values:
 | 
						|
            - Value: 0x23 ## DW_AT_sec_offset
 | 
						|
        - AbbrCode: 0 ## NULL
 | 
						|
        - AbbrCode: 0 ## NULL
 |