Replace svector with vector in synth_sync methods.

This commit is contained in:
Stephen Williams 2013-08-22 20:00:23 -07:00
parent d209d8ee39
commit a47447610f
2 changed files with 14 additions and 14 deletions

View File

@ -43,7 +43,6 @@
# include "StringHeap.h" # include "StringHeap.h"
# include "HName.h" # include "HName.h"
# include "LineInfo.h" # include "LineInfo.h"
# include "svector.h"
# include "Attrib.h" # include "Attrib.h"
# include "PUdp.h" # include "PUdp.h"
@ -2395,7 +2394,7 @@ class NetProc : public virtual LineInfo {
virtual bool synth_sync(Design*des, NetScope*scope, NetFF*ff, virtual bool synth_sync(Design*des, NetScope*scope, NetFF*ff,
const NetBus&nex_map, NetBus&nex_out, const NetBus&nex_map, NetBus&nex_out,
const svector<NetEvProbe*>&events); const std::vector<NetEvProbe*>&events);
virtual void dump(ostream&, unsigned ind) const; virtual void dump(ostream&, unsigned ind) const;
@ -2653,7 +2652,7 @@ class NetBlock : public NetProc {
bool synth_sync(Design*des, NetScope*scope, NetFF*ff, bool synth_sync(Design*des, NetScope*scope, NetFF*ff,
const NetBus&nex_map, NetBus&nex_out, const NetBus&nex_map, NetBus&nex_out,
const svector<NetEvProbe*>&events); const std::vector<NetEvProbe*>&events);
// This version of emit_recurse scans all the statements of // This version of emit_recurse scans all the statements of
// the begin-end block sequentially. It is typically of use // the begin-end block sequentially. It is typically of use
@ -2784,7 +2783,7 @@ class NetCondit : public NetProc {
bool synth_sync(Design*des, NetScope*scope, NetFF*ff, bool synth_sync(Design*des, NetScope*scope, NetFF*ff,
const NetBus&nex_map, NetBus&nex_out, const NetBus&nex_map, NetBus&nex_out,
const svector<NetEvProbe*>&events); const std::vector<NetEvProbe*>&events);
virtual bool emit_proc(struct target_t*) const; virtual bool emit_proc(struct target_t*) const;
virtual int match_proc(struct proc_match_t*); virtual int match_proc(struct proc_match_t*);
@ -3030,7 +3029,7 @@ class NetEvWait : public NetProc {
virtual bool synth_sync(Design*des, NetScope*scope, NetFF*ff, virtual bool synth_sync(Design*des, NetScope*scope, NetFF*ff,
const NetBus&nex_map, NetBus&nex_out, const NetBus&nex_map, NetBus&nex_out,
const svector<NetEvProbe*>&events); const std::vector<NetEvProbe*>&events);
virtual void dump(ostream&, unsigned ind) const; virtual void dump(ostream&, unsigned ind) const;
// This will ignore any statement. // This will ignore any statement.

View File

@ -26,6 +26,7 @@
# include "compiler.h" # include "compiler.h"
# include "ivl_assert.h" # include "ivl_assert.h"
using namespace std;
bool NetProc::synth_async(Design*, NetScope*, const NetBus&, NetBus&) bool NetProc::synth_async(Design*, NetScope*, const NetBus&, NetBus&)
{ {
@ -34,9 +35,9 @@ bool NetProc::synth_async(Design*, NetScope*, const NetBus&, NetBus&)
bool NetProc::synth_sync(Design*des, NetScope*scope, NetFF* /*ff*/, bool NetProc::synth_sync(Design*des, NetScope*scope, NetFF* /*ff*/,
const NetBus&nex_map, NetBus&nex_out, const NetBus&nex_map, NetBus&nex_out,
const svector<NetEvProbe*>&events) const vector<NetEvProbe*>&events)
{ {
if (events.count() > 0) { if (events.size() > 0) {
cerr << get_fileline() << ": error: Events are unaccounted" cerr << get_fileline() << ": error: Events are unaccounted"
<< " for in process synthesis." << endl; << " for in process synthesis." << endl;
des->errors += 1; des->errors += 1;
@ -396,7 +397,7 @@ bool NetProcTop::synth_async(Design*des)
*/ */
bool NetBlock::synth_sync(Design*des, NetScope* /*scope*/, NetFF* /*ff*/, bool NetBlock::synth_sync(Design*des, NetScope* /*scope*/, NetFF* /*ff*/,
const NetBus& /*nex_map*/, NetBus& /*nex_out*/, const NetBus& /*nex_map*/, NetBus& /*nex_out*/,
const svector<NetEvProbe*>& /*events_in*/) const vector<NetEvProbe*>& /*events_in*/)
{ {
if (last_ == 0) { if (last_ == 0) {
return true; return true;
@ -561,7 +562,7 @@ bool NetBlock::synth_sync(Design*des, NetScope* /*scope*/, NetFF* /*ff*/,
*/ */
bool NetCondit::synth_sync(Design*des, NetScope* /*scope*/, NetFF* /*ff*/, bool NetCondit::synth_sync(Design*des, NetScope* /*scope*/, NetFF* /*ff*/,
const NetBus& /*nex_map*/, NetBus& /*nex_out*/, const NetBus& /*nex_map*/, NetBus& /*nex_out*/,
const svector<NetEvProbe*>& /*events_in*/) const vector<NetEvProbe*>& /*events_in*/)
{ {
cerr << get_fileline() << ": sorry: " cerr << get_fileline() << ": sorry: "
<< "Forgot to implement NetCondit::synth_sync" << endl; << "Forgot to implement NetCondit::synth_sync" << endl;
@ -776,15 +777,15 @@ bool NetCondit::synth_sync(Design*des, NetScope* /*scope*/, NetFF* /*ff*/,
bool NetEvWait::synth_sync(Design*des, NetScope*scope, NetFF*ff, bool NetEvWait::synth_sync(Design*des, NetScope*scope, NetFF*ff,
const NetBus&nex_map, NetBus&nex_out, const NetBus&nex_map, NetBus&nex_out,
const svector<NetEvProbe*>&events_in) const vector<NetEvProbe*>&events_in)
{ {
if (events_in.count() > 0) { if (events_in.size() > 0) {
cerr << get_fileline() << ": error: Events are unaccounted" cerr << get_fileline() << ": error: Events are unaccounted"
<< " for in process synthesis." << endl; << " for in process synthesis." << endl;
des->errors += 1; des->errors += 1;
} }
assert(events_in.count() == 0); assert(events_in.size() == 0);
/* This can't be other than one unless there are named events, /* This can't be other than one unless there are named events,
which I cannot synthesize. */ which I cannot synthesize. */
@ -792,7 +793,7 @@ bool NetEvWait::synth_sync(Design*des, NetScope*scope, NetFF*ff,
NetEvent*ev = events_[0]; NetEvent*ev = events_[0];
assert(ev->nprobe() >= 1); assert(ev->nprobe() >= 1);
svector<NetEvProbe*>events (ev->nprobe() - 1); vector<NetEvProbe*>events (ev->nprobe() - 1);
/* Get the input set from the substatement. This will be used /* Get the input set from the substatement. This will be used
to figure out which of the probes is the clock. */ to figure out which of the probes is the clock. */
@ -899,7 +900,7 @@ bool NetProcTop::synth_sync(Design*des)
/* Synthesize the input to the DFF. */ /* Synthesize the input to the DFF. */
bool flag = statement_->synth_sync(des, scope(), ff, bool flag = statement_->synth_sync(des, scope(), ff,
nex_q, nex_d, nex_q, nex_d,
svector<NetEvProbe*>()); vector<NetEvProbe*>());
if (! flag) { if (! flag) {
delete ff; delete ff;
return false; return false;