simplified process scan for targets.
This commit is contained in:
parent
13cd13d9d5
commit
7ba7b925ed
12
emit.cc
12
emit.cc
|
|
@ -17,7 +17,7 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||
*/
|
||||
#if !defined(WINNT)
|
||||
#ident "$Id: emit.cc,v 1.16 1999/07/07 04:20:57 steve Exp $"
|
||||
#ident "$Id: emit.cc,v 1.17 1999/07/17 03:39:11 steve Exp $"
|
||||
#endif
|
||||
|
||||
/*
|
||||
|
|
@ -72,12 +72,7 @@ void NetBUFZ::emit_node(ostream&o, struct target_t*tgt) const
|
|||
|
||||
void NetProcTop::emit(ostream&o, struct target_t*tgt) const
|
||||
{
|
||||
assert(statement_);
|
||||
tgt->start_process(o, this);
|
||||
|
||||
statement_->emit_proc(o, tgt);
|
||||
|
||||
tgt->end_process(o, this);
|
||||
tgt->process(o, this);
|
||||
}
|
||||
|
||||
void NetProc::emit_proc(ostream&o, struct target_t*tgt) const
|
||||
|
|
@ -308,6 +303,9 @@ void emit(ostream&o, const Design*des, const char*type)
|
|||
|
||||
/*
|
||||
* $Log: emit.cc,v $
|
||||
* Revision 1.17 1999/07/17 03:39:11 steve
|
||||
* simplified process scan for targets.
|
||||
*
|
||||
* Revision 1.16 1999/07/07 04:20:57 steve
|
||||
* Emit vvm for user defined tasks.
|
||||
*
|
||||
|
|
|
|||
18
t-vvm.cc
18
t-vvm.cc
|
|
@ -17,7 +17,7 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||
*/
|
||||
#if !defined(WINNT)
|
||||
#ident "$Id: t-vvm.cc,v 1.30 1999/07/10 03:00:05 steve Exp $"
|
||||
#ident "$Id: t-vvm.cc,v 1.31 1999/07/17 03:39:11 steve Exp $"
|
||||
#endif
|
||||
|
||||
# include <iostream>
|
||||
|
|
@ -50,7 +50,7 @@ class target_vvm : public target_t {
|
|||
virtual void net_const(ostream&os, const NetConst*);
|
||||
virtual void net_esignal(ostream&os, const NetESignal*);
|
||||
virtual void net_event(ostream&os, const NetNEvent*);
|
||||
virtual void start_process(ostream&os, const NetProcTop*);
|
||||
virtual void process(ostream&os, const NetProcTop*);
|
||||
virtual void proc_assign(ostream&os, const NetAssign*);
|
||||
virtual void proc_assign_mem(ostream&os, const NetAssignMem*);
|
||||
virtual void proc_assign_nb(ostream&os, const NetAssignNB*);
|
||||
|
|
@ -64,9 +64,11 @@ class target_vvm : public target_t {
|
|||
virtual void proc_while(ostream&os, const NetWhile*);
|
||||
virtual void proc_event(ostream&os, const NetPEvent*);
|
||||
virtual void proc_delay(ostream&os, const NetPDelay*);
|
||||
virtual void end_process(ostream&os, const NetProcTop*);
|
||||
virtual void end_design(ostream&os, const Design*);
|
||||
|
||||
void start_process(ostream&os, const NetProcTop*);
|
||||
void end_process(ostream&os, const NetProcTop*);
|
||||
|
||||
private:
|
||||
void emit_gate_outputfun_(const NetNode*);
|
||||
|
||||
|
|
@ -419,6 +421,13 @@ void target_vvm::end_design(ostream&os, const Design*mod)
|
|||
os << "}" << endl;
|
||||
}
|
||||
|
||||
void target_vvm::process(ostream&os, const NetProcTop*top)
|
||||
{
|
||||
start_process(os, top);
|
||||
top->statement()->emit_proc(os, this);
|
||||
end_process(os, top);
|
||||
}
|
||||
|
||||
void target_vvm::signal(ostream&os, const NetNet*sig)
|
||||
{
|
||||
|
||||
|
|
@ -1267,6 +1276,9 @@ extern const struct target tgt_vvm = {
|
|||
};
|
||||
/*
|
||||
* $Log: t-vvm.cc,v $
|
||||
* Revision 1.31 1999/07/17 03:39:11 steve
|
||||
* simplified process scan for targets.
|
||||
*
|
||||
* Revision 1.30 1999/07/10 03:00:05 steve
|
||||
* Proper initialization of registers.
|
||||
*
|
||||
|
|
|
|||
7
t-xnf.cc
7
t-xnf.cc
|
|
@ -17,7 +17,7 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||
*/
|
||||
#if !defined(WINNT)
|
||||
#ident "$Id: t-xnf.cc,v 1.6 1998/12/09 02:43:19 steve Exp $"
|
||||
#ident "$Id: t-xnf.cc,v 1.7 1999/07/17 03:39:11 steve Exp $"
|
||||
#endif
|
||||
|
||||
/* XNF BACKEND
|
||||
|
|
@ -175,7 +175,7 @@ void target_xnf::draw_sym_with_lcaname(ostream&os, string lca,
|
|||
void target_xnf::start_design(ostream&os, const Design*des)
|
||||
{
|
||||
os << "LCANET,6" << endl;
|
||||
os << "PROG,verilog,0.0,\"Steve's Verilog\"" << endl;
|
||||
os << "PROG,verilog,0.0,\"Icarus Verilog\"" << endl;
|
||||
os << "PART," << des->get_flag("part") << endl;
|
||||
}
|
||||
|
||||
|
|
@ -333,6 +333,9 @@ extern const struct target tgt_xnf = { "xnf", &target_xnf_obj };
|
|||
|
||||
/*
|
||||
* $Log: t-xnf.cc,v $
|
||||
* Revision 1.7 1999/07/17 03:39:11 steve
|
||||
* simplified process scan for targets.
|
||||
*
|
||||
* Revision 1.6 1998/12/09 02:43:19 steve
|
||||
* Fix 2pin logic gates.
|
||||
*
|
||||
|
|
|
|||
14
target.cc
14
target.cc
|
|
@ -17,7 +17,7 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||
*/
|
||||
#if !defined(WINNT)
|
||||
#ident "$Id: target.cc,v 1.13 1999/07/03 02:12:52 steve Exp $"
|
||||
#ident "$Id: target.cc,v 1.14 1999/07/17 03:39:11 steve Exp $"
|
||||
#endif
|
||||
|
||||
# include "target.h"
|
||||
|
|
@ -91,12 +91,15 @@ void target_t::net_event(ostream&os, const NetNEvent*)
|
|||
"Unhandled EVENT net node." << endl;
|
||||
}
|
||||
|
||||
void target_t::start_process(ostream&os, const NetProcTop*)
|
||||
void target_t::process(ostream&os, const NetProcTop*top)
|
||||
{
|
||||
top->statement()->emit_proc(os, this);
|
||||
}
|
||||
|
||||
void target_t::proc_assign(ostream&os, const NetAssign*)
|
||||
{
|
||||
cerr << "target (" << typeid(*this).name() << "): "
|
||||
"Unhandled procedural assignment." << endl;
|
||||
}
|
||||
|
||||
void target_t::proc_assign_mem(ostream&os, const NetAssignMem*)
|
||||
|
|
@ -174,10 +177,6 @@ void target_t::proc_while(ostream&os, const NetWhile*net)
|
|||
net->dump(cerr, 6);
|
||||
}
|
||||
|
||||
void target_t::end_process(ostream&os, const NetProcTop*)
|
||||
{
|
||||
}
|
||||
|
||||
void target_t::end_design(ostream&os, const Design*)
|
||||
{
|
||||
}
|
||||
|
|
@ -236,6 +235,9 @@ void expr_scan_t::expr_binary(const NetEBinary*ex)
|
|||
|
||||
/*
|
||||
* $Log: target.cc,v $
|
||||
* Revision 1.14 1999/07/17 03:39:11 steve
|
||||
* simplified process scan for targets.
|
||||
*
|
||||
* Revision 1.13 1999/07/03 02:12:52 steve
|
||||
* Elaborate user defined tasks.
|
||||
*
|
||||
|
|
|
|||
13
target.h
13
target.h
|
|
@ -19,7 +19,7 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||
*/
|
||||
#if !defined(WINNT)
|
||||
#ident "$Id: target.h,v 1.13 1999/07/03 02:12:52 steve Exp $"
|
||||
#ident "$Id: target.h,v 1.14 1999/07/17 03:39:11 steve Exp $"
|
||||
#endif
|
||||
|
||||
# include "netlist.h"
|
||||
|
|
@ -74,8 +74,9 @@ struct target_t {
|
|||
virtual void net_esignal(ostream&os, const NetESignal*);
|
||||
virtual void net_event(ostream&os, const NetNEvent*);
|
||||
|
||||
/* Output a process (called for each process) */
|
||||
virtual void start_process(ostream&os, const NetProcTop*);
|
||||
/* Output a process (called for each process). It is up to the
|
||||
target to recurse if desired. */
|
||||
virtual void process(ostream&os, const NetProcTop*);
|
||||
|
||||
/* Various kinds of process nodes are dispatched through these. */
|
||||
virtual void proc_assign(ostream&os, const NetAssign*);
|
||||
|
|
@ -93,9 +94,6 @@ struct target_t {
|
|||
virtual void proc_event(ostream&os, const NetPEvent*);
|
||||
virtual void proc_delay(ostream&os, const NetPDelay*);
|
||||
|
||||
/* (called for each process) */
|
||||
virtual void end_process(ostream&os, const NetProcTop*);
|
||||
|
||||
/* Done with the design. */
|
||||
virtual void end_design(ostream&os, const Design*);
|
||||
};
|
||||
|
|
@ -131,6 +129,9 @@ extern const struct target *target_table[];
|
|||
|
||||
/*
|
||||
* $Log: target.h,v $
|
||||
* Revision 1.14 1999/07/17 03:39:11 steve
|
||||
* simplified process scan for targets.
|
||||
*
|
||||
* Revision 1.13 1999/07/03 02:12:52 steve
|
||||
* Elaborate user defined tasks.
|
||||
*
|
||||
|
|
|
|||
Loading…
Reference in New Issue