diff options
author | Alan Modra <amodra@gmail.com> | 2019-10-14 13:52:32 +1030 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2019-10-14 16:47:13 +1030 |
commit | 8025b0554c5a2e2fe56b769fd556fe13268b4879 (patch) | |
tree | ed6b83bb9aa8e9e9c6eee67992c87e92b2a78ad2 /gdb/ada-lang.c | |
parent | 3a3f4bf76a4790e81ee186ea76731a7f67dba1c8 (diff) | |
download | binutils-8025b0554c5a2e2fe56b769fd556fe13268b4879.zip binutils-8025b0554c5a2e2fe56b769fd556fe13268b4879.tar.gz binutils-8025b0554c5a2e2fe56b769fd556fe13268b4879.tar.bz2 |
qsort: dwarf2.c
This patch ensures qsort stability in line and function sorting done
in dwarf2.c. For the line sequences we make use of an existing field
that isn't used until later, as a monotonic counter for the qsort.
* dwarf2.c (struct lookup_funcinfo): Add idx field.
(compare_lookup_funcinfos): Perform final sort on idx.
(build_lookup_funcinfo_table): Set idx.
(compare_sequences): Perform final sort on num_lines.
(build_line_info_table): Set num_lines and line_info_lookup earlier.
(sort_line_sequences): Set num_lines for sort.
Diffstat (limited to 'gdb/ada-lang.c')
0 files changed, 0 insertions, 0 deletions