28#ifndef __SYSTEMC_SC_PORT_WRAPPER_HH__
29#define __SYSTEMC_SC_PORT_WRAPPER_HH__
47class ScInterfaceWrapper;
72 panic(
"sc_port can't be unbound.");
83 }
else if (
auto* iface =
87 fatal(
"Attempt to bind sc_port %s to incompatible port %s.",
114 using namespace gem5;
116 panic(
"sc_interface can't be unbound.");
122 using namespace gem5;
127 "Attempt to bind sc_interface %s to incompatible port %s.",
140template <
typename IF>
159 using namespace gem5;
161 panic(
"sc_export cannot be unbound.");
167 using namespace gem5;
171 "Attempt to bind sc_export %s to incompatible port %s.",
Ports are used to interface objects to each other.
const PortID id
A numeric identifier to distinguish ports in a vector, and set to InvalidPortID in case this port is ...
const std::string name() const
Return port name (for DPRINTF).
virtual void bind(Port &peer)
Attach to a peer port.
void unbind() override
Dettach from a peer port.
ScExportWrapper(ScExport &p, const std::string &name, gem5::PortID id)
sc_core::sc_export< IF > ScExport
void bind(gem5::Port &peer) override
Attach to a peer port.
ScInterfaceWrapper(IF &i, const std::string name, gem5::PortID id)
void unbind() override
Dettach from a peer port.
void bind(gem5::Port &peer) override
Attach to a peer port.
void unbind() override
Dettach from a peer port.
sc_core::sc_port_b< IF > ScPort
ScPortWrapper(ScPort &p, const std::string &name, gem5::PortID id)
void bind(gem5::Port &peer) override
Attach to a peer port.
#define panic(...)
This implements a cprintf based panic() function.
#define fatal_if(cond,...)
Conditional fatal macro that checks the supplied condition and only causes a fatal error if the condi...
#define fatal(...)
This implements a cprintf based fatal() function.
Copyright (c) 2024 - Pranith Kumar Copyright (c) 2020 Inria All rights reserved.
int16_t PortID
Port index/ID type, and a symbolic name for an invalid port id.