Include some block matching from Larry.
This commit is contained in:
parent
2bc8f79e0f
commit
e77bcf6910
18
functor.cc
18
functor.cc
|
|
@ -17,7 +17,7 @@
|
||||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||||
*/
|
*/
|
||||||
#if !defined(WINNT)
|
#if !defined(WINNT)
|
||||||
#ident "$Id: functor.cc,v 1.10 2000/01/13 03:35:35 steve Exp $"
|
#ident "$Id: functor.cc,v 1.11 2000/02/13 04:35:43 steve Exp $"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
# include "functor.h"
|
# include "functor.h"
|
||||||
|
|
@ -145,6 +145,18 @@ int NetAssignMem::match_proc(proc_match_t*that)
|
||||||
return that->assign_mem(this);
|
return that->assign_mem(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int proc_match_t::block(NetBlock*)
|
||||||
|
{
|
||||||
|
cerr << "default (failing) match for block" << endl;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
int NetBlock::match_proc(proc_match_t*that)
|
||||||
|
{
|
||||||
|
cerr << "NetBlock::match_proc" << endl;
|
||||||
|
return that->block(this);
|
||||||
|
}
|
||||||
|
|
||||||
int proc_match_t::condit(NetCondit*)
|
int proc_match_t::condit(NetCondit*)
|
||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
|
|
@ -152,6 +164,7 @@ int proc_match_t::condit(NetCondit*)
|
||||||
|
|
||||||
int NetCondit::match_proc(proc_match_t*that)
|
int NetCondit::match_proc(proc_match_t*that)
|
||||||
{
|
{
|
||||||
|
cerr << "NetCondit::match_proc" << endl;
|
||||||
return that->condit(this);
|
return that->condit(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -167,6 +180,9 @@ int NetPEvent::match_proc(proc_match_t*that)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* $Log: functor.cc,v $
|
* $Log: functor.cc,v $
|
||||||
|
* Revision 1.11 2000/02/13 04:35:43 steve
|
||||||
|
* Include some block matching from Larry.
|
||||||
|
*
|
||||||
* Revision 1.10 2000/01/13 03:35:35 steve
|
* Revision 1.10 2000/01/13 03:35:35 steve
|
||||||
* Multiplication all the way to simulation.
|
* Multiplication all the way to simulation.
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -19,7 +19,7 @@
|
||||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||||
*/
|
*/
|
||||||
#if !defined(WINNT)
|
#if !defined(WINNT)
|
||||||
#ident "$Id: functor.h,v 1.7 2000/01/13 03:35:35 steve Exp $"
|
#ident "$Id: functor.h,v 1.8 2000/02/13 04:35:43 steve Exp $"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
@ -65,11 +65,15 @@ struct proc_match_t {
|
||||||
virtual int assign_mem(class NetAssignMem*);
|
virtual int assign_mem(class NetAssignMem*);
|
||||||
virtual int condit(class NetCondit*);
|
virtual int condit(class NetCondit*);
|
||||||
virtual int pevent(class NetPEvent*);
|
virtual int pevent(class NetPEvent*);
|
||||||
|
virtual int block(class NetBlock*);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* $Log: functor.h,v $
|
* $Log: functor.h,v $
|
||||||
|
* Revision 1.8 2000/02/13 04:35:43 steve
|
||||||
|
* Include some block matching from Larry.
|
||||||
|
*
|
||||||
* Revision 1.7 2000/01/13 03:35:35 steve
|
* Revision 1.7 2000/01/13 03:35:35 steve
|
||||||
* Multiplication all the way to simulation.
|
* Multiplication all the way to simulation.
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -19,7 +19,7 @@
|
||||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||||
*/
|
*/
|
||||||
#if !defined(WINNT)
|
#if !defined(WINNT)
|
||||||
#ident "$Id: netlist.h,v 1.108 2000/01/13 03:35:35 steve Exp $"
|
#ident "$Id: netlist.h,v 1.109 2000/02/13 04:35:43 steve Exp $"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
@ -1072,7 +1072,7 @@ class NetAssignMemNB : public NetAssignMem_ {
|
||||||
private:
|
private:
|
||||||
};
|
};
|
||||||
|
|
||||||
/* A block is stuff line begin-end blocks, that contain and ordered
|
/* A block is stuff like begin-end blocks, that contain an ordered
|
||||||
list of NetProc statements.
|
list of NetProc statements.
|
||||||
|
|
||||||
NOTE: The emit method calls the target->proc_block function but
|
NOTE: The emit method calls the target->proc_block function but
|
||||||
|
|
@ -1092,6 +1092,7 @@ class NetBlock : public NetProc {
|
||||||
|
|
||||||
void emit_recurse(ostream&, struct target_t*) const;
|
void emit_recurse(ostream&, struct target_t*) const;
|
||||||
virtual bool emit_proc(ostream&, struct target_t*) const;
|
virtual bool emit_proc(ostream&, struct target_t*) const;
|
||||||
|
virtual int match_proc(struct proc_match_t*);
|
||||||
virtual void dump(ostream&, unsigned ind) const;
|
virtual void dump(ostream&, unsigned ind) const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
@ -2151,6 +2152,9 @@ extern ostream& operator << (ostream&, NetNet::Type);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* $Log: netlist.h,v $
|
* $Log: netlist.h,v $
|
||||||
|
* Revision 1.109 2000/02/13 04:35:43 steve
|
||||||
|
* Include some block matching from Larry.
|
||||||
|
*
|
||||||
* Revision 1.108 2000/01/13 03:35:35 steve
|
* Revision 1.108 2000/01/13 03:35:35 steve
|
||||||
* Multiplication all the way to simulation.
|
* Multiplication all the way to simulation.
|
||||||
*
|
*
|
||||||
|
|
|
||||||
25
synth.cc
25
synth.cc
|
|
@ -17,7 +17,7 @@
|
||||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||||
*/
|
*/
|
||||||
#if !defined(WINNT)
|
#if !defined(WINNT)
|
||||||
#ident "$Id: synth.cc,v 1.4 1999/12/05 02:24:09 steve Exp $"
|
#ident "$Id: synth.cc,v 1.5 2000/02/13 04:35:43 steve Exp $"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
@ -205,6 +205,21 @@ void match_dff::make_ram_()
|
||||||
des_->add_node(ram);
|
des_->add_node(ram);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
class match_block : public proc_match_t {
|
||||||
|
|
||||||
|
public:
|
||||||
|
match_block(Design*d, NetProcTop*t)
|
||||||
|
: des_(d), top_(t)
|
||||||
|
{ }
|
||||||
|
|
||||||
|
~match_block() { }
|
||||||
|
|
||||||
|
private:
|
||||||
|
|
||||||
|
Design*des_;
|
||||||
|
NetProcTop*top_;
|
||||||
|
};
|
||||||
|
|
||||||
class synth_f : public functor_t {
|
class synth_f : public functor_t {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
@ -242,6 +257,11 @@ void synth_f::proc_always_(class Design*des)
|
||||||
des->delete_process(top_);
|
des->delete_process(top_);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
match_block block_pat(des, top_);
|
||||||
|
if (top_->statement()->match_proc(&block_pat)) {
|
||||||
|
cerr << "XXXX: recurse and return here" << endl;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -253,6 +273,9 @@ void synth(Design*des)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* $Log: synth.cc,v $
|
* $Log: synth.cc,v $
|
||||||
|
* Revision 1.5 2000/02/13 04:35:43 steve
|
||||||
|
* Include some block matching from Larry.
|
||||||
|
*
|
||||||
* Revision 1.4 1999/12/05 02:24:09 steve
|
* Revision 1.4 1999/12/05 02:24:09 steve
|
||||||
* Synthesize LPM_RAM_DQ for writes into memories.
|
* Synthesize LPM_RAM_DQ for writes into memories.
|
||||||
*
|
*
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue