diff options
Diffstat (limited to 'gdb/gdbsupport/btrace-common.h')
-rw-r--r-- | gdb/gdbsupport/btrace-common.h | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/gdb/gdbsupport/btrace-common.h b/gdb/gdbsupport/btrace-common.h index 0b18924..9c57645 100644 --- a/gdb/gdbsupport/btrace-common.h +++ b/gdb/gdbsupport/btrace-common.h @@ -43,11 +43,15 @@ struct btrace_block /* The address of the first byte of the last instruction in the block. */ CORE_ADDR end; -}; -/* Define functions operating on a vector of branch trace blocks. */ -typedef struct btrace_block btrace_block_s; -DEF_VEC_O (btrace_block_s); + /* Simple constructor. */ + btrace_block (CORE_ADDR begin, CORE_ADDR end) + : begin (begin), + end (end) + { + /* Nothing. */ + } +}; /* Enumeration of btrace formats. */ @@ -137,8 +141,9 @@ struct btrace_config struct btrace_data_bts { /* Branch trace is represented as a vector of branch trace blocks starting - with the most recent block. */ - VEC (btrace_block_s) *blocks; + with the most recent block. This needs to be a pointer as we place + btrace_data_bts into a union. */ + std::vector <btrace_block> *blocks; }; /* Configuration information to go with the trace data. */ |