diff options
Diffstat (limited to 'gdb/common/btrace-common.h')
-rw-r--r-- | gdb/common/btrace-common.h | 39 |
1 files changed, 38 insertions, 1 deletions
diff --git a/gdb/common/btrace-common.h b/gdb/common/btrace-common.h index ba99a06..ebae17e 100644 --- a/gdb/common/btrace-common.h +++ b/gdb/common/btrace-common.h @@ -58,7 +58,10 @@ enum btrace_format /* Branch trace is in Branch Trace Store (BTS) format. Actually, the format is a sequence of blocks derived from BTS. */ - BTRACE_FORMAT_BTS + BTRACE_FORMAT_BTS, + + /* Branch trace is in Intel(R) Processor Trace format. */ + BTRACE_FORMAT_PT }; /* An enumeration of cpu vendors. */ @@ -97,6 +100,14 @@ struct btrace_config_bts unsigned int size; }; +/* An Intel(R) Processor Trace configuration. */ + +struct btrace_config_pt +{ + /* The size of the branch trace buffer in bytes. */ + unsigned int size; +}; + /* A branch tracing configuration. This describes the requested configuration as well as the actually @@ -111,6 +122,9 @@ struct btrace_config /* The BTS format configuration. */ struct btrace_config_bts bts; + + /* The Intel(R) Processor Trace format configuration. */ + struct btrace_config_pt pt; }; /* Branch trace in BTS format. */ @@ -121,6 +135,26 @@ struct btrace_data_bts VEC (btrace_block_s) *blocks; }; +/* Configuration information to go with the trace data. */ +struct btrace_data_pt_config +{ + /* The processor on which the trace has been collected. */ + struct btrace_cpu cpu; +}; + +/* Branch trace in Intel(R) Processor Trace format. */ +struct btrace_data_pt +{ + /* Some configuration information to go with the data. */ + struct btrace_data_pt_config config; + + /* The trace data. */ + gdb_byte *data; + + /* The size of DATA in bytes. */ + unsigned long size; +}; + /* The branch trace data. */ struct btrace_data { @@ -130,6 +164,9 @@ struct btrace_data { /* Format == BTRACE_FORMAT_BTS. */ struct btrace_data_bts bts; + + /* Format == BTRACE_FORMAT_PT. */ + struct btrace_data_pt pt; } variant; }; |