From bcf2314f15d68d7a0b94445f99962342b9d4130d Mon Sep 17 00:00:00 2001 From: Julian Blake Kongslie Date: Sat, 15 Oct 2022 15:01:25 -0700 Subject: Switch to external nanosim dependency. --- infra/pipetrace.h | 37 ------------------------------------- 1 file changed, 37 deletions(-) delete mode 100644 infra/pipetrace.h (limited to 'infra/pipetrace.h') diff --git a/infra/pipetrace.h b/infra/pipetrace.h deleted file mode 100644 index 656b9b9..0000000 --- a/infra/pipetrace.h +++ /dev/null @@ -1,37 +0,0 @@ -#pragma once - -#include -#include -#include -#include - -namespace infra { - struct transaction { - std::uint64_t record = ~(std::uint64_t)0; - }; - - struct pt { - static std::ostream *ptfile; - - static std::uint64_t next_record; - - static transaction toplevel() { - transaction t; - t.record = next_record++; - return t; - } - - static transaction child(const transaction &p) { - transaction t; - t.record = next_record++; - if (ptfile) - *ptfile << fmt::format("{} parent {}\n", t.record, p.record); - return t; - } - - static void event(const transaction &t, const char *event, std::uint64_t time, const std::string &data) { - if (ptfile) - *ptfile << fmt::format("@{} {} {} {}\n", time, t.record, event, data); - } - }; -} -- cgit v1.2.3