CIRCT 20.0.0git
|
Engines implement the actual channel communication between the host and the accelerator. More...
#include <Engines.h>
Public Member Functions | |
virtual | ~Engine ()=default |
virtual void | connect () |
Start the engine, if applicable. | |
virtual void | disconnect () |
Stop the engine, if applicable. | |
virtual ChannelPort & | requestPort (AppIDPath idPath, const std::string &channelName, BundleType::Direction dir, const Type *type) |
Get a port for a channel, from the cache if it exists or create it. | |
Protected Member Functions | |
virtual std::unique_ptr< ChannelPort > | createPort (AppIDPath idPath, const std::string &channelName, BundleType::Direction dir, const Type *type)=0 |
Each engine needs to know how to create a ports. | |
Private Attributes | |
std::map< std::pair< AppIDPath, std::string >, std::unique_ptr< ChannelPort > > | ownedPorts |
Engines implement the actual channel communication between the host and the accelerator.
Engines can support multiple channels. They are low level of the ESI runtime API and are not intended to be used directly by users.
|
virtualdefault |
|
inlinevirtual |
|
protectedpure virtual |
Each engine needs to know how to create a ports.
This method is called if a port doesn't exist in the engine cache.
Implemented in esi::backends::cosim::CosimEngine.
Referenced by requestPort().
|
inlinevirtual |
|
virtual |
Get a port for a channel, from the cache if it exists or create it.
An engine may override this method if different behavior is desired.
Definition at line 19 of file Engines.cpp.
References createPort(), and ownedPorts.
|
private |
Definition at line 63 of file Engines.h.
Referenced by requestPort().