40 #if !defined(sc_method_process_h_INCLUDED)
41 #define sc_method_process_h_INCLUDED
59 # define DEBUG_NAME ""
60 # define DEBUG_MSG(NAME,P,MSG) \
62 if ( P && ( (strlen(NAME)==0) || !strcmp(NAME,P->name())) ) \
63 std::cout << "**** " << sc_time_stamp() << " (" \
64 << sc_get_current_process_name() << "): " << MSG \
65 << " - " << P->name() << std::endl; \
68 # define DEBUG_MSG(NAME,P,MSG)
81 class sc_process_table;
82 class sc_process_handle;
88 void next_trigger(
const sc_event_or_list&, sc_simcontext* );
89 void next_trigger(
const sc_event_and_list&, sc_simcontext* );
91 void next_trigger(
const sc_time&,
const sc_event&, sc_simcontext* );
92 void next_trigger(
const sc_time&,
const sc_event_or_list&, sc_simcontext* );
93 void next_trigger(
const sc_time&,
const sc_event_and_list&, sc_simcontext* );
95 struct sc_invoke_method;
133 virtual const char*
kind()
const
134 {
return "sc_method_process"; }
188 e.add_dynamic(
this );
231 e.add_dynamic(
this );
298 bool restart =
false;
301 DEBUG_MSG(DEBUG_NAME,
this,
"executing method semantics");
306 DEBUG_MSG(DEBUG_NAME,
this,
"caught unwind exception");
344 #if ! defined( SC_ENABLE_IMMEDIATE_SELF_NOTIFICATIONS )
350 #endif // SC_ENABLE_IMMEDIATE_SELF_NOTIFICATIONS
465 #endif // !defined(sc_method_process_h_INCLUDED)
const sc_event * m_event_p
virtual void suspend_process(sc_descendant_inclusion_info descendants=SC_NO_DESCENDANTS)
virtual void kill_process(sc_descendant_inclusion_info descendants=SC_NO_DESCENDANTS)
virtual bool is_reset() const
void set_stack_size(std::size_t size)
void set_next_runnable(sc_method_handle next_p)
void set_next_exist(sc_method_handle next_p)
friend void sc_cmethod_cor_fn(void *)
void(sc_process_host::* SC_ENTRY_FUNC)()
sc_method_handle next_runnable()
#define DEBUG_MSG(NAME, P, MSG)
void set_error(sc_report *)
sc_process_b * sc_get_current_process_b()
friend void next_trigger(sc_simcontext *)
sc_process_b * m_runnable_p
friend void sc_set_stack_size(sc_method_handle, std::size_t)
const sc_event_list * m_event_list_p
sc_event * m_timeout_event_p
friend void sc_method_cor_fn(void *)
virtual void throw_reset(bool async)
void report_immediate_self_notification() const
friend class sc_process_table
virtual void enable_process(sc_descendant_inclusion_info descendants=SC_NO_DESCENDANTS)
void sc_set_stack_size(sc_method_handle, std::size_t)
std::vector< sc_process_monitor * > m_monitor_q
bool trigger_dynamic(sc_event *)
void add_dynamic(sc_method_handle) const
virtual void resume_process(sc_descendant_inclusion_info descendants=SC_NO_DESCENDANTS)
void sc_method_cor_fn(void *)
sc_descendant_inclusion_info
void sc_cmethod_cor_fn(void *)
friend struct sc_invoke_method
void next_trigger(sc_simcontext *)
class sc_method_process * sc_method_handle
sc_simcontext * simcontext() const
virtual void throw_user(const sc_throw_it_helper &helper, sc_descendant_inclusion_info descendants=SC_NO_DESCENDANTS)
virtual const char * kind() const
virtual void disable_process(sc_descendant_inclusion_info descendants=SC_NO_DESCENDANTS)
sc_method_process(const char *name_p, bool free_host, SC_ENTRY_FUNC method_p, sc_process_host *host_p, const sc_spawn_options *opt_p)
sc_method_handle next_exist()
sc_report * sc_handle_exception()