diff options
author | Simon Marchi <simon.marchi@ericsson.com> | 2017-10-16 10:14:53 -0400 |
---|---|---|
committer | Simon Marchi <simon.marchi@ericsson.com> | 2017-10-16 11:07:18 -0400 |
commit | a79b1bc6f690f3d146a3caddabd9f13a886c856a (patch) | |
tree | a80d8994788044e3c175bb974b2893352b065db5 /gdb/ChangeLog | |
parent | 63f0e930d4667eb7dbc95c78f770cd58acd328ef (diff) | |
download | binutils-a79b1bc6f690f3d146a3caddabd9f13a886c856a.zip binutils-a79b1bc6f690f3d146a3caddabd9f13a886c856a.tar.gz binutils-a79b1bc6f690f3d146a3caddabd9f13a886c856a.tar.bz2 |
Get rid of VEC(mem_range_s)
This patch replaces the last usages of VEC(mem_range_s) with
std::vector<mem_range>. This allows getting rid of a few cleanups and
of the DEF_VEC_O(mem_range_s).
I added a test for normalize_mem_ranges to make sure I didn't break
anything there.
Regtested on the buildbot.
gdb/ChangeLog:
* memrange.h (struct mem_range): Define operator< and operator==.
(mem_range_s): Remove.
(DEF_VEC_O (mem_range_s)): Remove.
(normalize_mem_ranges): Change parameter type to std::vector.
* memrange.c (compare_mem_ranges): Remove.
(normalize_mem_ranges): Change parameter type to std::vector,
adjust to vector change.
* exec.c (section_table_available_memory): Return vector, remove
parameter.
(section_table_read_available_memory): Adjust to std::vector
change.
* remote.c (remote_read_bytes): Adjust to std::vector
change.
* tracepoint.h (traceframe_available_memory): Change parameter
type to std::vector.
* tracepoint.c (traceframe_available_memory): Change parameter
type to std::vector, adjust.
* gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
std::vector change.
* gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
unittests/memrange-selftests.c.
(SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
* gdb/unittests/memrange-selftests.c: New file.
Diffstat (limited to 'gdb/ChangeLog')
-rw-r--r-- | gdb/ChangeLog | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index cc81af8..169304a 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,29 @@ +2017-10-16 Simon Marchi <simon.marchi@ericsson.com> + + * memrange.h (struct mem_range): Define operator< and operator==. + (mem_range_s): Remove. + (DEF_VEC_O (mem_range_s)): Remove. + (normalize_mem_ranges): Change parameter type to std::vector. + * memrange.c (compare_mem_ranges): Remove. + (normalize_mem_ranges): Change parameter type to std::vector, + adjust to vector change. + * exec.c (section_table_available_memory): Return vector, remove + parameter. + (section_table_read_available_memory): Adjust to std::vector + change. + * remote.c (remote_read_bytes): Adjust to std::vector + change. + * tracepoint.h (traceframe_available_memory): Change parameter + type to std::vector. + * tracepoint.c (traceframe_available_memory): Change parameter + type to std::vector, adjust. + * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to + std::vector change. + * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add + unittests/memrange-selftests.c. + (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o. + * gdb/unittests/memrange-selftests.c: New file. + 2017-10-16 Pedro Alves <palves@redhat.com> * elfread.c (probe_key_free): Rename range-for variable. |