-struct trace_file_writer;
-
-/* Operations to write trace frames to a specific trace format. */
-
-struct trace_frame_write_ops
-{
- /* Write a new trace frame. The tracepoint number of this trace
- frame is TPNUM. */
- void (*start) (struct trace_file_writer *self, uint16_t tpnum);
-
- /* Write an 'R' block. Buffer BUF contains its contents and SIZE is
- its size. */
- void (*write_r_block) (struct trace_file_writer *self,
- gdb_byte *buf, int32_t size);
-
- /* Write an 'M' block, the header and memory contents respectively.
- The header of 'M' block is composed of the start address and the
- length of memory collection, and the memory contents contain
- the collected memory contents in tracing.
- For extremely large M block, GDB is unable to get its contents
- and write them into trace file in one go, due to the limitation
- of the remote target or the size of internal buffer, we split
- the operation to 'M' block to two operations. */
- /* Write the head of 'M' block. ADDR is the start address of
- collected memory and LENGTH is the length of memory contents. */
- void (*write_m_block_header) (struct trace_file_writer *self,
- uint64_t addr, uint16_t length);
- /* Write the memory contents of 'M' block. Buffer BUF contains
- its contents and LENGTH is its length. This method can be called
- multiple times to write large memory contents of a single 'M'
- block. */
- void (*write_m_block_memory) (struct trace_file_writer *self,
- gdb_byte *buf, uint16_t length);
-
- /* Write a 'V' block. NUM is the trace variable number and VAL is
- the value of the trace variable. */
- void (*write_v_block) (struct trace_file_writer *self, int32_t num,
- uint64_t val);
-
- /* The end of the trace frame. */
- void (*end) (struct trace_file_writer *self);
-};
-
-/* Operations to write trace buffers to a specific trace format. */
-
-struct trace_file_write_ops