CIRCT
19.0.0git
|
Connect to an ESI simulation. More...
#include <Trace.h>
Classes | |
struct | Impl |
Public Types | |
enum | Mode { Write } |
Public Types inherited from esi::AcceleratorConnection | |
using | Service = services::Service |
Public Member Functions | |
TraceAccelerator (Context &, Mode mode, std::filesystem::path manifestJson, std::filesystem::path traceFile) | |
Create a trace-based accelerator backend. More... | |
std::map< std::string, ChannelPort & > | requestChannelsFor (AppIDPath, const BundleType *) override |
Request the host side channel ports for a particular instance (identified by the AppID path). More... | |
Public Member Functions inherited from esi::AcceleratorConnection | |
AcceleratorConnection (Context &ctxt) | |
virtual | ~AcceleratorConnection ()=default |
Context & | getCtxt () const |
template<typename ServiceClass > | |
ServiceClass * | getService (AppIDPath id={}, std::string implName={}, ServiceImplDetails details={}, HWClientDetails clients={}) |
Get a typed reference to a particular service type. More... | |
virtual Service * | getService (Service::Type service, AppIDPath id={}, std::string implName={}, ServiceImplDetails details={}, HWClientDetails clients={}) |
Calls createService and caches the result. More... | |
Static Public Member Functions | |
static std::unique_ptr< AcceleratorConnection > | connect (Context &, std::string connectionString) |
Parse the connection string and instantiate the accelerator. More... | |
Protected Member Functions | |
virtual Service * | createService (Service::Type service, AppIDPath idPath, std::string implName, const ServiceImplDetails &details, const HWClientDetails &clients) override |
Called by getServiceImpl exclusively. More... | |
Private Attributes | |
std::unique_ptr< Impl > | impl |
TraceAccelerator::TraceAccelerator | ( | Context & | , |
Mode | mode, | ||
std::filesystem::path | manifestJson, | ||
std::filesystem::path | traceFile | ||
) |
Create a trace-based accelerator backend.
mode | The mode of operation. See Mode. |
manifestJson | The path to the manifest JSON file. |
traceFile | The path to the trace file. For 'Write' mode, this file is opened for writing. For 'Read' mode, this file is opened for reading. |
Definition at line 126 of file Trace.cpp.
References impl.
|
static |
Parse the connection string and instantiate the accelerator.
Format is: "<mode>:<manifest path>[:<traceFile>]".
Definition at line 96 of file Trace.cpp.
References esiaccel.accelerator::ctxt.
|
overrideprotectedvirtual |
Called by getServiceImpl
exclusively.
It wraps the pointer returned by this in a unique_ptr and caches it. Separate this from the wrapping/caching since wrapping/caching is an implementation detail.
Implements esi::AcceleratorConnection.
Definition at line 133 of file Trace.cpp.
References impl.
|
overridevirtual |
Request the host side channel ports for a particular instance (identified by the AppID path).
For convenience, provide the bundle type.
Implements esi::AcceleratorConnection.
Definition at line 242 of file Trace.cpp.
References impl.
|
private |
Definition at line 76 of file Trace.h.
Referenced by createService(), requestChannelsFor(), and TraceAccelerator().