probe: Replace VEC(probe_ops_cp) with std::vector
authorSimon Marchi <simon.marchi@ericsson.com>
Tue, 12 Sep 2017 12:15:23 +0000 (14:15 +0200)
committerSimon Marchi <simon.marchi@ericsson.com>
Tue, 12 Sep 2017 12:15:23 +0000 (14:15 +0200)
commit0782db848b52ecaf29e13d9f12a2c7cfabec2bdb
treefa9363f082aa5fc8678fd60e12b247c74dfe2540
parent1eac6bea98f41ee12ba9e750a9578bd8585011c9
probe: Replace VEC(probe_ops_cp) with std::vector

This patch replaces the usage of VEC to store pointers to probe_ops with
an std::vector.  The sole usage of that vector type is one global
variable that holds the ops for the various kinds of probes, so this is
pretty straightforward (no allocation/deallocation issues).

gdb/ChangeLog:

* probe.h (probe_ops_cp): Remove typedef.
(DEF_VEC_P (probe_ops_cp)): Remove.
(all_probe_ops): Change type to std::vector.
* probe.c (info_probes_for_ops): Adjust to vector change.
(probe_linespec_to_ops): Likewise.
(all_probe_ops): Change type to std::vector.
(_initialize_probe): Adjust to vector change.
* dtrace-probe.c (_initialize_dtrace_probe): Likewise.
* elfread.c (elf_get_probes): Likewise.
* stap-probe.c (_initialize_stap_probe): Likewise.
gdb/ChangeLog
gdb/dtrace-probe.c
gdb/elfread.c
gdb/probe.c
gdb/probe.h
gdb/stap-probe.c