Skip to content

KeyError: 'DW_AT_count' #8

@embedcat

Description

@embedcat

Using with arm-none-eabi-gcc, i have this error in multiple object files. For example:

# python frame_larger_than.py ../trunk/KitBox/build/obj/configuration_hash.o cfgHashCalc
cfgHashCalc:
Traceback (most recent call last):
  File "X:\Work\SVN\KitBox\frame-larger-than\frame_larger_than.py", line 216, in <module>
    parse_file(elffile.get_dwarf_info(), sys.argv[2])
  File "X:\Work\SVN\KitBox\frame-larger-than\frame_larger_than.py", line 194, in parse_file
    print_var(dwarf_info, DIE)
  File "X:\Work\SVN\KitBox\frame-larger-than\frame_larger_than.py", line 179, in print_var
    type_string = get_type_string(dwarf_info, type_info)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "X:\Work\SVN\KitBox\frame-larger-than\frame_larger_than.py", line 125, in get_type_string
    num_elements = get_array_count(type_info)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "X:\Work\SVN\KitBox\frame-larger-than\frame_larger_than.py", line 78, in get_array_count
    return child.attributes['DW_AT_count'].value
           ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
KeyError: 'DW_AT_count'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions