//===- ActionProfiler.h - Profiling Actions *- C++ -*-=======================// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// #ifndef MLIR_TRACING_OBSERVERS_ACTIONPROFILER_H #define MLIR_TRACING_OBSERVERS_ACTIONPROFILER_H #include "mlir/Debug/ExecutionContext.h" #include "llvm/ADT/StringRef.h" #include "llvm/Support/raw_ostream.h" #include <chrono> #include <mutex> namespace mlir { namespace tracing { /// This class defines an observer that profiles events before and after /// execution on the provided stream. The events are stored in the Chrome trace /// event format. struct ActionProfiler : public ExecutionContext::Observer { … }; } // namespace tracing } // namespace mlir #endif // MLIR_TRACING_OBSERVERS_ACTIONPROFILER_H