Possibilite de mettre un espace en premier
This commit is contained in:
parent
5a6c402d1e
commit
1107eff334
|
@ -156,7 +156,7 @@ PPlacement::Init(lofig* fig, int NbRows)
|
||||||
}
|
}
|
||||||
|
|
||||||
for (locon* con = fig->LOCON; con; con = con->NEXT)
|
for (locon* con = fig->LOCON; con; con = con->NEXT)
|
||||||
ploconmap[con->NAME] = con;
|
ploconmap[con->NAME] = con;
|
||||||
|
|
||||||
// traitement de l'emplacement des connecteurs
|
// traitement de l'emplacement des connecteurs
|
||||||
// creation des PCon si fichier ioc
|
// creation des PCon si fichier ioc
|
||||||
|
@ -718,43 +718,48 @@ PPlacement::SetPosIocFile(PConMap& pconmap)
|
||||||
void
|
void
|
||||||
PPlacement::ParseIocFile(PLoconMap& ploconmap)
|
PPlacement::ParseIocFile(PLoconMap& ploconmap)
|
||||||
{
|
{
|
||||||
PPos position;
|
PPos position;
|
||||||
|
|
||||||
_PtList = iocparse(_iocFileName);
|
_PtList = iocparse(_iocFileName);
|
||||||
|
|
||||||
char orientation;
|
char orientation;
|
||||||
|
|
||||||
for(con_list* tmpcon = _PtList ; tmpcon ; tmpcon = tmpcon->NEXT)
|
for(con_list* tmpcon = _PtList ; tmpcon ; tmpcon = tmpcon->NEXT)
|
||||||
{
|
|
||||||
if (strcmp(tmpcon->NAME,"SPACE") != 0)
|
|
||||||
{
|
{
|
||||||
if (ploconmap.find(tmpcon->NAME) == ploconmap.end())
|
if (strcmp(tmpcon->NAME,"SPACE") != 0)
|
||||||
{
|
{
|
||||||
cerr << " o Error in ioc file ...." << endl
|
if (ploconmap.find(tmpcon->NAME) == ploconmap.end())
|
||||||
<< " The connector " << tmpcon->NAME
|
{
|
||||||
<< " doesn't exist in your figure ...."
|
cerr << " o Error in ioc file ...." << endl
|
||||||
<< endl;
|
<< " The connector " << tmpcon->NAME
|
||||||
exit(1);
|
<< " doesn't exist in your figure ...."
|
||||||
|
<< endl;
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
switch (tmpcon->ORIENT)
|
||||||
|
{
|
||||||
|
case 'T':
|
||||||
|
orientation = NORTH;
|
||||||
|
break;
|
||||||
|
case 'B':
|
||||||
|
orientation = SOUTH;
|
||||||
|
break;
|
||||||
|
case 'L':
|
||||||
|
orientation = WEST;
|
||||||
|
break;
|
||||||
|
case 'R':
|
||||||
|
orientation = EAST;
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
cerr << "Unknown Orientation for connector: "
|
||||||
|
<< tmpcon->NAME << endl;
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
position.SetX(0);
|
||||||
|
position.SetY(0);
|
||||||
|
InsertCon(ploconmap[tmpcon->NAME], position, orientation);
|
||||||
}
|
}
|
||||||
switch (tmpcon->ORIENT)
|
|
||||||
{
|
|
||||||
case 'T' : orientation = NORTH;
|
|
||||||
break;
|
|
||||||
case 'B' : orientation = SOUTH;
|
|
||||||
break;
|
|
||||||
case 'L' : orientation = WEST;
|
|
||||||
break;
|
|
||||||
case 'R' : orientation = EAST;
|
|
||||||
break;
|
|
||||||
default: cerr << "Unknown Orientation for connector: "
|
|
||||||
<< tmpcon->NAME << endl;
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
position.SetX(0);
|
|
||||||
position.SetY(0);
|
|
||||||
InsertCon(ploconmap[tmpcon->NAME], position, orientation);
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// ======================================================================
|
// ======================================================================
|
||||||
|
|
|
@ -63,7 +63,7 @@ orientation : TOP {
|
||||||
|
|
||||||
expr :
|
expr :
|
||||||
| iopin expr;
|
| iopin expr;
|
||||||
| iopin space expr;
|
| space expr;
|
||||||
|
|
||||||
|
|
||||||
iopin : PAROUV IOPIN iopin1 PARFER PTVIRG;
|
iopin : PAROUV IOPIN iopin1 PARFER PTVIRG;
|
||||||
|
@ -112,6 +112,7 @@ con_list* add_con(con_list* ptlist, char orient, char* name)
|
||||||
|
|
||||||
return ptcon;
|
return ptcon;
|
||||||
}
|
}
|
||||||
|
|
||||||
con_list* add_space(con_list* ptlist, char orient, char *value)
|
con_list* add_space(con_list* ptlist, char orient, char *value)
|
||||||
{
|
{
|
||||||
con_list* ptcon;
|
con_list* ptcon;
|
||||||
|
@ -124,6 +125,7 @@ con_list* add_space(con_list* ptlist, char orient, char *value)
|
||||||
|
|
||||||
return ptcon;
|
return ptcon;
|
||||||
}
|
}
|
||||||
|
|
||||||
con_list* iocparse(char *file)
|
con_list* iocparse(char *file)
|
||||||
{
|
{
|
||||||
extern FILE *yyin;
|
extern FILE *yyin;
|
||||||
|
|
Loading…
Reference in New Issue