do not export phcons when they were present in the

prepplaced phfig
This commit is contained in:
Christophe Alexandre 2008-07-15 16:29:10 +00:00
parent 0118f02c3f
commit df8da45edd
3 changed files with 28 additions and 29 deletions

View File

@ -52,9 +52,8 @@ PCon::PCon(const locon* con, PPos pos, char orient)
{} {}
void void
PCon::Save(struct phfig *physicalfig, const double dx, const double dy) const PCon::Save(struct phfig *physicalfig, const double dx, const double dy) const {
{ if (!_phcon) {
if (!_phcon)
addphcon(physicalfig addphcon(physicalfig
, _orient , _orient
, _con->NAME , _con->NAME
@ -62,15 +61,20 @@ PCon::Save(struct phfig *physicalfig, const double dx, const double dy) const
, (int)(GetPosY() * PITCH + dy) , (int)(GetPosY() * PITCH + dy)
, _orient==NORTH || _orient == SOUTH ? ALU2 : ALU3 , _orient==NORTH || _orient == SOUTH ? ALU2 : ALU3
, (_orient==NORTH || _orient == SOUTH ? 2 : 1) * (PITCH/5)); , (_orient==NORTH || _orient == SOUTH ? 2 : 1) * (PITCH/5));
else } else {
addphcon(physicalfig #if 0
, _phcon->ORIENT addphcon(physicalfig,
, _phcon->NAME _phcon->ORIENT,
, _phcon->XCON _phcon->NAME,
, _phcon->YCON _phcon->XCON,
, _phcon->LAYER _phcon->YCON,
, _phcon->WIDTH _phcon->LAYER,
); _phcon->WIDTH);
//modification 15/07/2008 (xtof)
//why should we add the physical connectors
//on the existing phfig ?
#endif
}

View File

@ -224,14 +224,11 @@ PPlacement::Init(lofig* fig, int NbRows)
it = it->NEXT) it = it->NEXT)
{ {
locon_list* con = (locon_list*)(it->DATA); locon_list* con = (locon_list*)(it->DATA);
if (con->TYPE == EXTERNAL) if (con->TYPE == EXTERNAL) {
{
if ( (_prePlaceFig && _prePlaceFig->PHCON) if ( (_prePlaceFig && _prePlaceFig->PHCON)
|| _placeCons || _ringPlaceCons || _iocFile) || _placeCons || _ringPlaceCons || _iocFile) {
{
PConMap::iterator cit = pconmap.find(con->NAME); PConMap::iterator cit = pconmap.find(con->NAME);
if (cit != pconmap.end()) if (cit != pconmap.end()) {
{
++totreatinscpt; ++totreatinscpt;
} }
} }

View File

@ -258,13 +258,11 @@ PPlacement::FinalOptimize()
// int Save() // int Save()
// ====================================================================== // ======================================================================
int int
PPlacement::Save() PPlacement::Save() {
{
char* phfigname; char* phfigname;
struct phfig* physicalfig; struct phfig* physicalfig;
if (!_prePlaceFig) if (!_prePlaceFig) {
{
physicalfig = addphfig(_fileName); physicalfig = addphfig(_fileName);
phfigname = _fileName; phfigname = _fileName;
if (_verbose) cout << "NO PREPLACEMENT GIVEN" << endl; if (_verbose) cout << "NO PREPLACEMENT GIVEN" << endl;
@ -272,9 +270,7 @@ PPlacement::Save()
physicalfig->XAB2 =(int)(BBox.GetMaxX() * PITCH); physicalfig->XAB2 =(int)(BBox.GetMaxX() * PITCH);
physicalfig->YAB1 =(int)(BBox.GetMinY() * PITCH); physicalfig->YAB1 =(int)(BBox.GetMinY() * PITCH);
physicalfig->YAB2 =(int)(BBox.GetMaxY() * PITCH); physicalfig->YAB2 =(int)(BBox.GetMaxY() * PITCH);
} } else {
else
{
if (_verbose) cout << "PREPLACEMENT GIVEN" << endl; if (_verbose) cout << "PREPLACEMENT GIVEN" << endl;
physicalfig = _prePlaceFig; physicalfig = _prePlaceFig;
phfigname = physicalfig->NAME; phfigname = physicalfig->NAME;
@ -291,13 +287,15 @@ PPlacement::Save()
} }
} }
for (PCons::const_iterator cit = _cons.begin(); cit != _cons.end(); cit++) for (PCons::const_iterator cit = _cons.begin();
{ cit != _cons.end();
if (_ringPlaceCons) cit++) {
if (_ringPlaceCons) {
(*cit)->RingSave(physicalfig, _dx, _dy); (*cit)->RingSave(physicalfig, _dx, _dy);
else } else {
(*cit)->Save(physicalfig, _dx, _dy); (*cit)->Save(physicalfig, _dx, _dy);
} }
}
int superr = AddRowend(physicalfig); int superr = AddRowend(physicalfig);