Skip to main content

struct tracy_integration

Declaration

struct tracy_integration { /* full declaration omitted */ };

Member Variables

std::vector<async_lane_state> async_lanes
std::string last_instruction_trace
written by `CELERITY_DETAIL_TRACE_INSTRUCTION()`, read by `executor_impl::dispatch()`
tracy_detail::plot<int64_t> assigned_instructions_plot = {"assigned instructions"}
tracy_detail::plot<int64_t> assignment_queue_length_plot = {"assignment queue length"}

Member Function Overview

  • begin_instruction_zone(const instruction_info & info, bool was_eagerly_submitted) → static TracyCZoneCtx
  • end_instruction_zone(const TracyCZoneCtx & ctx, const instruction_info & info, const std::string & trace, const async_event * opt_event = nullptr) → static void
  • get_async_lane_cursor(const out_of_order_engine::assignment & assignment) → async_lane_cursor
  • issue_async_instruction(instruction_info && info, const out_of_order_engine::assignment & assignment, std::string && trace) → async_lane_cursor
  • make_instruction_info(const instruction & instr) → static instruction_info
  • retire_async_instruction(const async_lane_cursor & cursor, const async_event & event) → void

Member Functions

static TracyCZoneCtx begin_instruction_zone(
    const instruction_info& info,
    bool was_eagerly_submitted)

Description

Open a Tracy zone, setting tag, color - and name, if full tracing is enabled.

Parameters

const instruction_info& info
bool was_eagerly_submitted

static void end_instruction_zone(
    const TracyCZoneCtx& ctx,
    const instruction_info& info,
    const std::string& trace,
    const async_event* opt_event = nullptr)

Description

Close a Tracy zone - after emitting the instruction trace and generic instruction info if full tracing is enabled.

Parameters

const TracyCZoneCtx& ctx
const instruction_info& info
const std::string& trace
const async_event* opt_event = nullptr

async_lane_cursor get_async_lane_cursor(
    const out_of_order_engine::assignment&
        assignment)

Description

Picks the (optionally) pre-existing lane for an in-order queue submission, or an arbitrary free lane for async unordered send/receive instructions.

Parameters

const out_of_order_engine::assignment& assignment

async_lane_cursor issue_async_instruction(
    instruction_info&& info,
    const out_of_order_engine::assignment&
        assignment,
    std::string&& trace)

Description

Adds an async instruction to its designated lane queue; beginning a Tracy zone immediately if it is the only instruction in the queue

Parameters

instruction_info&& info
const out_of_order_engine::assignment& assignment
std::string&& trace

static instruction_info make_instruction_info(
    const instruction& instr)

Parameters

const instruction& instr

void retire_async_instruction(
    const async_lane_cursor& cursor,
    const async_event& event)

Description

Closes the tracy zone for an active async instruction; beginning the next queued zone in the same lane, if any.

Parameters

const async_lane_cursor& cursor
const async_event& event