grouter: convert K&R function definitions to ANSI C

Convert the old-style (K&R) function definitions in grouter/ to ANSI C
prototypes, formatted in the project's convention: the return type on its
own line and each parameter on its own line, indented four spaces, with
the original parameter comments retained.

Updates grouter.h with prototypes for the affected declarations.

Builds cleanly under GCC 16 / C23 (with the -std=gnu17 build change).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
Andreas Wendleder 2026-06-10 03:49:15 +02:00
parent 561ea8135e
commit e826c6c82f
No known key found for this signature in database
GPG Key ID: 588785BFDFB01ABD
13 changed files with 360 additions and 343 deletions

View File

@ -134,8 +134,8 @@ PaintArea *glChanPaintList;
*/ */
void void
glChanBuildMap(chanList) glChanBuildMap(
GCRChannel *chanList; /* List of all channels in routing problem */ GCRChannel *chanList) /* List of all channels in routing problem */
{ {
GCRChannel *ch; GCRChannel *ch;
bool workDone; bool workDone;
@ -235,10 +235,10 @@ glChanBuildMap(chanList)
*/ */
int int
glChanFeedFunc(tile, dinfo, clientdata) glChanFeedFunc(
Tile *tile; Tile *tile,
TileType dinfo; /* (unused) */ TileType dinfo, /* (unused) */
ClientData clientdata; /* (unused) */ ClientData clientdata) /* (unused) */
{ {
char *mesg; char *mesg;
Rect r; Rect r;
@ -307,9 +307,9 @@ glChanFreeMap()
int glChanCheckCount; int glChanCheckCount;
void void
glChanCheckCover(chanList, mask) glChanCheckCover(
GCRChannel *chanList; GCRChannel *chanList,
TileTypeBitMask *mask; TileTypeBitMask *mask)
{ {
int glChanCheckFunc(); int glChanCheckFunc();
GCRChannel *ch; GCRChannel *ch;
@ -344,10 +344,10 @@ glChanCheckCover(chanList, mask)
*/ */
int int
glChanCheckFunc(tile, dinfo, ch) glChanCheckFunc(
Tile *tile; Tile *tile,
TileType dinfo; /* (unused) */ TileType dinfo, /* (unused) */
GCRChannel *ch; GCRChannel *ch)
{ {
char mesg[1024]; char mesg[1024];
Rect r; Rect r;
@ -394,8 +394,8 @@ glChanCheckFunc(tile, dinfo, ch)
*/ */
bool bool
glChanClip(ch) glChanClip(
GCRChannel *ch; GCRChannel *ch)
{ {
bool ret; bool ret;
@ -432,17 +432,17 @@ glChanClip(ch)
} }
int int
glChanSetClient(tile, cdata) glChanSetClient(
Tile *tile; Tile *tile,
ClientData cdata; ClientData cdata)
{ {
tile->ti_client = cdata; tile->ti_client = cdata;
return 0; return 0;
} }
void void
glChanShowTiles(mesg) glChanShowTiles(
char *mesg; char *mesg)
{ {
char answer[100], m[1024]; char answer[100], m[1024];
@ -457,10 +457,10 @@ glChanShowTiles(mesg)
} }
int int
glChanShowFunc(tile, dinfo, clientdata) glChanShowFunc(
Tile *tile; Tile *tile,
TileType dinfo; /* (unused) */ TileType dinfo, /* (unused) */
ClientData clientdata; /* (unused) */ ClientData clientdata) /* (unused) */
{ {
GCRChannel *ch; GCRChannel *ch;
char mesg[1024]; char mesg[1024];
@ -503,10 +503,10 @@ glChanShowFunc(tile, dinfo, clientdata)
*/ */
int int
glChanClipFunc(tile, dinfo, area) glChanClipFunc(
Tile *tile; Tile *tile,
TileType dinfo; /* (unused) */ TileType dinfo, /* (unused) */
Rect *area; Rect *area)
{ {
ClientData tileClient = tile->ti_client; ClientData tileClient = tile->ti_client;
TileType type = TiGetType(tile); TileType type = TiGetType(tile);
@ -573,10 +573,10 @@ glChanClipFunc(tile, dinfo, area)
*/ */
int int
glChanMergeFunc(tile, dinfo, clientdata) glChanMergeFunc(
Tile *tile; Tile *tile,
TileType dinfo; /* (unused) */ TileType dinfo, /* (unused) */
ClientData clientdata; /* (unused) */ ClientData clientdata) /* (unused) */
{ {
GCRChannel *ch = (GCRChannel *) tile->ti_client; GCRChannel *ch = (GCRChannel *) tile->ti_client;
Tile *delayed = NULL; /* delayed free to extend lifetime */ Tile *delayed = NULL; /* delayed free to extend lifetime */
@ -664,8 +664,8 @@ glChanMergeFunc(tile, dinfo, clientdata)
*/ */
void void
glChanBlockDens(ch) glChanBlockDens(
GCRChannel *ch; GCRChannel *ch)
{ {
GlobChan *gc = (GlobChan *) ch->gcr_client; GlobChan *gc = (GlobChan *) ch->gcr_client;
int halfGrid, shiftedOrigin; int halfGrid, shiftedOrigin;
@ -782,10 +782,10 @@ glChanBlockDens(ch)
} }
int int
glChanPaintFunc(tile, dinfo, type) glChanPaintFunc(
Tile *tile; Tile *tile,
TileType dinfo; /* (unused) */ TileType dinfo, /* (unused) */
TileType type; TileType type)
{ {
static TileType changeTable[4][4] = { static TileType changeTable[4][4] = {
/* Paint atop CHAN_NORMAL */ /* Paint atop CHAN_NORMAL */
@ -832,9 +832,9 @@ glChanPaintFunc(tile, dinfo, type)
*/ */
void void
glChanFlood(area, type) glChanFlood(
Rect *area; Rect *area,
TileType type; TileType type)
{ {
TileTypeBitMask hMask, vMask; TileTypeBitMask hMask, vMask;
Rect outside; Rect outside;
@ -878,10 +878,10 @@ glChanFlood(area, type)
} }
int int
glChanFloodVFunc(tile, dinfo, area) glChanFloodVFunc(
Tile *tile; Tile *tile,
TileType dinfo; /* (unused) */ TileType dinfo, /* (unused) */
Rect *area; Rect *area)
{ {
PaintArea *pa; PaintArea *pa;
@ -898,10 +898,10 @@ glChanFloodVFunc(tile, dinfo, area)
} }
int int
glChanFloodHFunc(tile, dinfo, area) glChanFloodHFunc(
Tile *tile; Tile *tile,
TileType dinfo; /* (unused) */ TileType dinfo, /* (unused) */
Rect *area; Rect *area)
{ {
PaintArea *pa; PaintArea *pa;
@ -939,10 +939,10 @@ glChanFloodHFunc(tile, dinfo, area)
*/ */
int int
glChanSplitRiver(tile, dinfo, clientdata) glChanSplitRiver(
Tile *tile; Tile *tile,
TileType dinfo; /* (unused) */ TileType dinfo, /* (unused) */
ClientData clientdata; /* (unused) */ ClientData clientdata) /* (unused) */
{ {
ClientData tileClient = tile->ti_client; ClientData tileClient = tile->ti_client;
Tile *tp, *newTile; Tile *tp, *newTile;
@ -1022,10 +1022,10 @@ glChanSplitRiver(tile, dinfo, clientdata)
*/ */
int int
glChanRiverBlock(tile, dinfo, clientdata) glChanRiverBlock(
Tile *tile; Tile *tile,
TileType dinfo; /* (unused) */ TileType dinfo, /* (unused) */
ClientData clientdata; /* (unused) */ ClientData clientdata) /* (unused) */
{ {
GCRPin *pin, *pinLast; GCRPin *pin, *pinLast;
GCRChannel *ch; GCRChannel *ch;
@ -1087,9 +1087,9 @@ glChanRiverBlock(tile, dinfo, clientdata)
*/ */
Tile * Tile *
glChanPinToTile(hintTile, pin) glChanPinToTile(
Tile *hintTile; /* Hint for starting the tile search */ Tile *hintTile, /* Hint for starting the tile search */
GCRPin *pin; /* Find tile containing this pin */ GCRPin *pin) /* Find tile containing this pin */
{ {
GCRChannel *ch; GCRChannel *ch;
Tile *tp; Tile *tp;

View File

@ -87,10 +87,10 @@ void glCrossTakePin();
*/ */
void void
glCrossMark(rootUse, path, pNetId) glCrossMark(
CellUse *rootUse; /* For error feedback if non-NULL */ CellUse *rootUse, /* For error feedback if non-NULL */
GlPoint *path; /* Path linked via gl_path pointers */ GlPoint *path, /* Path linked via gl_path pointers */
NetId *pNetId; /* Net and segment identifier; netid_seg is updated */ NetId *pNetId) /* Net and segment identifier; netid_seg is updated */
{ {
GCRPin *srcPin, *dstPin; GCRPin *srcPin, *dstPin;
GlPoint *rp; GlPoint *rp;
@ -161,10 +161,10 @@ glCrossMark(rootUse, path, pNetId)
*/ */
void void
glCrossTakePin(rootUse, pin, netid) glCrossTakePin(
CellUse *rootUse; /* For error feedback if non-NULL */ CellUse *rootUse, /* For error feedback if non-NULL */
GCRPin *pin; /* Pin to take */ GCRPin *pin, /* Pin to take */
NetId netid; /* Identifier to assign */ NetId netid) /* Identifier to assign */
{ {
char c[2048+64], name1[1024], name2[1024]; char c[2048+64], name1[1024], name2[1024];
Rect r; Rect r;
@ -236,8 +236,8 @@ glCrossTakePin(rootUse, pin, netid)
*/ */
void void
glCrossUnreserve(net) glCrossUnreserve(
NLNet *net; NLNet *net)
{ {
NLTermLoc *loc; NLTermLoc *loc;
NLTerm *term; NLTerm *term;
@ -289,11 +289,11 @@ glCrossUnreserve(net)
*/ */
int int
glCrossEnum(inPt, tp, func, cdata) glCrossEnum(
GlPoint *inPt; /* Top of heap point being expanded */ GlPoint *inPt, /* Top of heap point being expanded */
Tile *tp; /* Tile adjacent to inPt->gl_tile */ Tile *tp, /* Tile adjacent to inPt->gl_tile */
int (*func)(); /* Called for each crossing */ int (*func)(), /* Called for each crossing */
ClientData cdata; /* Passed to (*func)() */ ClientData cdata) /* Passed to (*func)() */
{ {
int outSide, origin, lo, hi, max, start, n, nhi; int outSide, origin, lo, hi, max, start, n, nhi;
GCRChannel *ch = inPt->gl_pin->gcr_ch; GCRChannel *ch = inPt->gl_pin->gcr_ch;
@ -468,11 +468,11 @@ glCrossEnum(inPt, tp, func, cdata)
*/ */
GlPoint * GlPoint *
glCrossAdjust(lookAhead, path) glCrossAdjust(
GlPoint *lookAhead; /* Normally, lookAhead->gl_path == path, except on the GlPoint *lookAhead, /* Normally, lookAhead->gl_path == path, except on the
* initial call, in which case lookAhead == NULL. * initial call, in which case lookAhead == NULL.
*/ */
GlPoint *path; /* Adjust crossings along this path */ GlPoint *path) /* Adjust crossings along this path */
{ {
GlPoint *newPath, *newRest; GlPoint *newPath, *newRest;
GCRPin *linkedPin, *pin; GCRPin *linkedPin, *pin;
@ -571,11 +571,11 @@ glCrossAdjust(lookAhead, path)
/*ARGSUSED*/ /*ARGSUSED*/
int int
glCrossChoose(newRest, tp, pin, newPath) glCrossChoose(
GlPoint *newRest; /* Portion of path already assigned */ GlPoint *newRest, /* Portion of path already assigned */
Tile *tp; /* UNUSED */ Tile *tp, /* UNUSED */
GCRPin *pin; /* Pin on boundary of tp being considered */ GCRPin *pin, /* Pin on boundary of tp being considered */
GlPoint *newPath; /* Update newPath->gl_pin, newPath->gl_cost */ GlPoint *newPath) /* Update newPath->gl_pin, newPath->gl_cost */
{ {
GCRPin *savePin; GCRPin *savePin;
int cost; int cost;
@ -629,10 +629,10 @@ glCrossChoose(newRest, tp, pin, newPath)
*/ */
int int
glCrossCost(lookAhead, exitPt, entryPt) glCrossCost(
GlPoint *lookAhead; GlPoint *lookAhead,
GlPoint *exitPt; GlPoint *exitPt,
GlPoint *entryPt; GlPoint *entryPt)
{ {
GCRPin *entryPin, *exitPin, *otherPin; GCRPin *entryPin, *exitPin, *otherPin;
GCRPin *opposite; GCRPin *opposite;

View File

@ -61,10 +61,11 @@ static char rcsid[] __attribute__ ((unused)) = "$Header: /usr/cvsroot/magic-8.0/
*/ */
bool bool
glDensAdjust(dens, srcPin, dstPin, netid) glDensAdjust(
DensMap dens[2]; DensMap dens[2],
GCRPin *srcPin, *dstPin; GCRPin *srcPin,
NetId netid; GCRPin *dstPin,
NetId netid)
{ {
int minprow, maxprow, minpcol, maxpcol, mincol, maxcol, minrow, maxrow; int minprow, maxprow, minpcol, maxpcol, mincol, maxcol, minrow, maxrow;
int maxvd, maxhd, col, row, nrow, ncol; int maxvd, maxhd, col, row, nrow, ncol;
@ -187,9 +188,10 @@ glDensAdjust(dens, srcPin, dstPin, netid)
*/ */
void void
glDMAlloc(dm, top, cap) glDMAlloc(
DensMap *dm; DensMap *dm,
int top, cap; int top,
int cap)
{ {
dm->dm_max = 0; dm->dm_max = 0;
dm->dm_size = top + 1; dm->dm_size = top + 1;
@ -216,8 +218,9 @@ glDMAlloc(dm, top, cap)
*/ */
void void
glDMCopy(dm1, dm2) glDMCopy(
DensMap *dm1, *dm2; DensMap *dm1,
DensMap *dm2)
{ {
dm2->dm_max = dm1->dm_max; dm2->dm_max = dm1->dm_max;
ASSERT(dm2->dm_size == dm1->dm_size, "glDMCopy"); ASSERT(dm2->dm_size == dm1->dm_size, "glDMCopy");
@ -243,8 +246,8 @@ glDMCopy(dm1, dm2)
*/ */
void void
glDMFree(dm) glDMFree(
DensMap *dm; DensMap *dm)
{ {
freeMagic((char *) dm->dm_value); freeMagic((char *) dm->dm_value);
} }
@ -266,9 +269,10 @@ glDMFree(dm)
*/ */
int int
glDMMaxInRange(dm, lo, hi) glDMMaxInRange(
DensMap *dm; DensMap *dm,
int lo, hi; int lo,
int hi)
{ {
short *dval = dm->dm_value; short *dval = dm->dm_value;
int n, max; int n, max;
@ -305,9 +309,9 @@ glDMMaxInRange(dm, lo, hi)
*/ */
void void
glDensInit(dmap, ch) glDensInit(
DensMap dmap[2]; DensMap dmap[2],
GCRChannel *ch; GCRChannel *ch)
{ {
short *dSrc, *dDst, *dEnd; short *dSrc, *dDst, *dEnd;

View File

@ -80,9 +80,9 @@ void glClientFree();
*/ */
void void
GlGlobalRoute(chanList, netList) GlGlobalRoute(
GCRChannel *chanList; /* List of all channels in routing problem */ GCRChannel *chanList, /* List of all channels in routing problem */
NLNetList *netList; /* Netlist built by caller */ NLNetList *netList) /* Netlist built by caller */
{ {
HeapEntry entry; HeapEntry entry;
Heap netHeap; Heap netHeap;
@ -166,9 +166,9 @@ GlGlobalRoute(chanList, netList)
*/ */
void void
glClientInit(chanList, netList) glClientInit(
GCRChannel *chanList; GCRChannel *chanList,
NLNetList *netList; NLNetList *netList)
{ {
GCRChannel *ch; GCRChannel *ch;
GlobChan *gc; GlobChan *gc;
@ -214,9 +214,9 @@ glClientInit(chanList, netList)
*/ */
void void
glClientFree(chanList, netList) glClientFree(
GCRChannel *chanList; GCRChannel *chanList,
NLNetList *netList; NLNetList *netList)
{ {
GlobChan *gc; GlobChan *gc;
CZone *cz; CZone *cz;
@ -279,13 +279,13 @@ glClientFree(chanList, netList)
*/ */
GlPoint * GlPoint *
glProcessLoc(startList, loc, bestCost, doFast) glProcessLoc(
GlPoint *startList; /* List of starting points */ GlPoint *startList, /* List of starting points */
NLTermLoc *loc; /* Location of terminal being routed to */ NLTermLoc *loc, /* Location of terminal being routed to */
int bestCost; /* Best cost so far; if we can't find a path in int bestCost, /* Best cost so far; if we can't find a path in
* less than this cost, give up. * less than this cost, give up.
*/ */
bool doFast; /* If TRUE, only wiggle crossings around within the bool doFast) /* If TRUE, only wiggle crossings around within the
* channels on the shortest path; don't bother * channels on the shortest path; don't bother
* considering other sequences of channels. If FALSE, * considering other sequences of channels. If FALSE,
* we keep generating longer and longer paths until * we keep generating longer and longer paths until

View File

@ -92,9 +92,9 @@ bool glMazeCheckLoop();
*/ */
GlPoint * GlPoint *
glMazeFindPath(loc, bestCost) glMazeFindPath(
NLTermLoc *loc; /* Destination point */ NLTermLoc *loc, /* Destination point */
int bestCost; /* Beat this cost or give up */ int bestCost) /* Beat this cost or give up */
{ {
int heapPts, startPts, frontierPts; int heapPts, startPts, frontierPts;
GlPoint *inPt; GlPoint *inPt;
@ -183,9 +183,9 @@ glMazeFindPath(loc, bestCost)
*/ */
void void
glMazePropFinal(inPt, loc) glMazePropFinal(
GlPoint *inPt; /* Point being processed */ GlPoint *inPt, /* Point being processed */
NLTermLoc *loc; /* Destination point */ NLTermLoc *loc) /* Destination point */
{ {
GCRPin *destPin = loc->nloc_pin; GCRPin *destPin = loc->nloc_pin;
Point *destPoint = &loc->nloc_stem; Point *destPoint = &loc->nloc_stem;
@ -229,8 +229,8 @@ glMazePropFinal(inPt, loc)
*/ */
void void
glMazePropRiver(inPt) glMazePropRiver(
GlPoint *inPt; GlPoint *inPt)
{ {
GCRPin *inPin = inPt->gl_pin, *outPin, *linkedPin; GCRPin *inPin = inPt->gl_pin, *outPin, *linkedPin;
GCRChannel *inCh = inPin->gcr_ch; GCRChannel *inCh = inPin->gcr_ch;
@ -311,8 +311,8 @@ glMazePropRiver(inPt)
#define NOTBLOCKEDV(tp) (NOTBLOCKED(tp) && TiGetType(tp) != CHAN_HRIVER) #define NOTBLOCKEDV(tp) (NOTBLOCKED(tp) && TiGetType(tp) != CHAN_HRIVER)
void void
glMazePropNormal(inPt) glMazePropNormal(
GlPoint *inPt; GlPoint *inPt)
{ {
Tile *tile = inPt->gl_tile, *tp; Tile *tile = inPt->gl_tile, *tp;
@ -362,10 +362,10 @@ glMazePropNormal(inPt)
*/ */
void void
glMazeTile(inPt, tile, dir) glMazeTile(
GlPoint *inPt; /* Top of heap point being expanded */ GlPoint *inPt, /* Top of heap point being expanded */
Tile *tile; /* Tile adjacent to inPt->gl_tile */ Tile *tile, /* Tile adjacent to inPt->gl_tile */
int dir; /* Direction from inPt->gl_tile to tile */ int dir) /* Direction from inPt->gl_tile to tile */
{ {
GCRChannel *ch = (GCRChannel *) tile->ti_client; GCRChannel *ch = (GCRChannel *) tile->ti_client;
TileType type = TiGetType(tile); TileType type = TiGetType(tile);
@ -471,10 +471,10 @@ glMazeTile(inPt, tile, dir)
*/ */
int int
glMazeTileFunc(inPt, tp, pin) glMazeTileFunc(
GlPoint *inPt; /* Top of heap point being expanded */ GlPoint *inPt, /* Top of heap point being expanded */
Tile *tp; /* Tile adjacent to inPt->gl_tile */ Tile *tp, /* Tile adjacent to inPt->gl_tile */
GCRPin *pin; /* Available pin on boundary of tp */ GCRPin *pin) /* Available pin on boundary of tp */
{ {
GlPoint *outPt; GlPoint *outPt;
int cost; int cost;
@ -530,9 +530,9 @@ glMazeTileFunc(inPt, tp, pin)
*/ */
bool bool
glMazeCheckLoop(path, tp) glMazeCheckLoop(
GlPoint *path; GlPoint *path,
Tile *tp; Tile *tp)
{ {
for ( ; path; path = path->gl_path) for ( ; path; path = path->gl_path)
if (path->gl_tile == tp) if (path->gl_tile == tp)
@ -559,9 +559,9 @@ glMazeCheckLoop(path, tp)
*/ */
void void
glMazeResetCost(headPage, headFree) glMazeResetCost(
GlPage *headPage; GlPage *headPage,
int headFree; int headFree)
{ {
GlPage *gpage; GlPage *gpage;
GCRPin *pin; GCRPin *pin;
@ -583,8 +583,8 @@ glMazeResetCost(headPage, headFree)
} }
void void
glPathPrint(path) glPathPrint(
GlPoint *path; GlPoint *path)
{ {
GlPoint *rp; GlPoint *rp;
GCRPin *pin; GCRPin *pin;

View File

@ -109,13 +109,13 @@ void glMultiAddStart();
*/ */
int int
glMultiSteiner(rootUse, net, routeProc, markProc, cdRoute, cdMark) glMultiSteiner(
CellUse *rootUse; /* If non-NULL, feedback for errors left here */ CellUse *rootUse, /* If non-NULL, feedback for errors left here */
NLNet *net; /* Net to process */ NLNet *net, /* Net to process */
GlPoint *(*routeProc)(); /* Procedure to route a segment */ GlPoint *(*routeProc)(), /* Procedure to route a segment */
int (*markProc)(); /* Procedure to remember the route */ int (*markProc)(), /* Procedure to remember the route */
ClientData cdRoute; /* Passed to (*routeProc)() */ ClientData cdRoute, /* Passed to (*routeProc)() */
ClientData cdMark; /* Passed to (*markProc)() */ ClientData cdMark) /* Passed to (*markProc)() */
{ {
GlPoint *startList, *bestDest, *dest; GlPoint *startList, *bestDest, *dest;
char mesg[128], *lastTermName; char mesg[128], *lastTermName;
@ -240,8 +240,8 @@ glMultiSteiner(rootUse, net, routeProc, markProc, cdRoute, cdMark)
*/ */
int int
glMultiStemCost(loc) glMultiStemCost(
NLTermLoc *loc; NLTermLoc *loc)
{ {
int n1, n2, cost; int n1, n2, cost;
@ -278,9 +278,9 @@ glMultiStemCost(loc)
*/ */
void void
glMultiAddStart(path, pStartList) glMultiAddStart(
GlPoint *path; /* Path linked via gl_path pointers */ GlPoint *path, /* Path linked via gl_path pointers */
GlPoint **pStartList; /* List of starting points */ GlPoint **pStartList) /* List of starting points */
{ {
GlPoint *srcEntry, *dstEntry; GlPoint *srcEntry, *dstEntry;
GCRPin *srcPin, *dstPin; GCRPin *srcPin, *dstPin;

View File

@ -58,9 +58,9 @@ static bool glNameDidInit = FALSE;
*/ */
void void
glNetNameInit(netList, numNets) glNetNameInit(
NLNetList *netList; NLNetList *netList,
int numNets; int numNets)
{ {
NLNet *net; NLNet *net;
int i; int i;
@ -116,8 +116,8 @@ glNetNameInit(netList, numNets)
*/ */
char * char *
GlNetIdName(id) GlNetIdName(
int id; int id)
{ {
static char tempId[100]; static char tempId[100];

View File

@ -131,9 +131,9 @@ int fudgeDenom = 10;
*/ */
GlPoint * GlPoint *
glRouteToPoint(loc, bestCost) glRouteToPoint(
NLTermLoc *loc; /* Route from points on heap to this point */ NLTermLoc *loc, /* Route from points on heap to this point */
int bestCost; /* If we haven't found a path with less than int bestCost) /* If we haven't found a path with less than
* this cost, return NULL. * this cost, return NULL.
*/ */
{ {
@ -321,14 +321,14 @@ glScalePenalties()
*/ */
bool bool
glPopFromHeap(pNewBest, newPaths, hEntry) glPopFromHeap(
bool *pNewBest; /* Should be TRUE on initial call; afterwards, bool *pNewBest, /* Should be TRUE on initial call; afterwards,
* we set it to TRUE when glBestCost is updated. * we set it to TRUE when glBestCost is updated.
*/ */
bool newPaths; /* TRUE if points added to glHeap since the last bool newPaths, /* TRUE if points added to glHeap since the last
* call to glPopFromHeap(). * call to glPopFromHeap().
*/ */
HeapEntry *hEntry; /* See above */ HeapEntry *hEntry) /* See above */
{ {
HeapEntry *bestCostTop, *glHeapTop; HeapEntry *bestCostTop, *glHeapTop;
int minAcceptableCost, newBestCost; int minAcceptableCost, newBestCost;
@ -495,9 +495,9 @@ glPopFromHeap(pNewBest, newPaths, hEntry)
*/ */
bool bool
glFinalPropagate(inPt, loc) glFinalPropagate(
GlPoint *inPt; /* Point being processed */ GlPoint *inPt, /* Point being processed */
NLTermLoc *loc; /* Destination point */ NLTermLoc *loc) /* Destination point */
{ {
GCRChannel *destCh = loc->nloc_chan; GCRChannel *destCh = loc->nloc_chan;
GCRPin *destPin = loc->nloc_pin; GCRPin *destPin = loc->nloc_pin;
@ -565,8 +565,8 @@ glFinalPropagate(inPt, loc)
*/ */
int int
glRiverPropagate(inPt) glRiverPropagate(
GlPoint *inPt; GlPoint *inPt)
{ {
GCRPin *inPin = inPt->gl_pin, *outPin, *linkedPin; GCRPin *inPin = inPt->gl_pin, *outPin, *linkedPin;
GCRChannel *inCh = inPt->gl_ch; GCRChannel *inCh = inPt->gl_ch;
@ -719,10 +719,10 @@ glRiverPropagate(inPt)
*/ */
void void
glNormalPropagate(inPt, inCh, heapCost) glNormalPropagate(
GlPoint *inPt; /* Point on the boundary of inCh */ GlPoint *inPt, /* Point on the boundary of inCh */
GCRChannel *inCh; /* Channel through which we're passing */ GCRChannel *inCh, /* Channel through which we're passing */
int heapCost; /* Cost with which inPt was added to heap */ int heapCost) /* Cost with which inPt was added to heap */
{ {
PinRanges pinRange, prevRange; PinRanges pinRange, prevRange;
int x, y, baseCost, min, max; int x, y, baseCost, min, max;
@ -913,10 +913,11 @@ glNormalPropagate(inPt, inCh, heapCost)
int int
glMinRemainingCost(inPt, inCh, pRect, dRect) glMinRemainingCost(
GlPoint *inPt; GlPoint *inPt,
GCRChannel *inCh; GCRChannel *inCh,
Rect *pRect, *dRect; Rect *pRect,
Rect *dRect)
{ {
int cost, n; int cost, n;
GCRPin *pins; GCRPin *pins;
@ -1042,10 +1043,10 @@ glMinRemainingCost(inPt, inCh, pRect, dRect)
int int
glPinCost(inPt, pin, oldCost) glPinCost(
GlPoint *inPt; GlPoint *inPt,
GCRPin *pin; GCRPin *pin,
int oldCost; int oldCost)
{ {
int cost; int cost;
@ -1089,10 +1090,10 @@ glPinCost(inPt, pin, oldCost)
*/ */
bool bool
glSetDensityClip(inPt, ch, dRect) glSetDensityClip(
GlPoint *inPt; GlPoint *inPt,
GCRChannel *ch; GCRChannel *ch,
Rect *dRect; Rect *dRect)
{ {
GCRPin *inPin = inPt->gl_pin; GCRPin *inPin = inPt->gl_pin;
short *den, maxdensity; short *den, maxdensity;
@ -1213,11 +1214,12 @@ glSetDensityClip(inPt, ch, dRect)
*/ */
void void
glSetPinClip(inPt, inCh, heapCost, dRect, pRect) glSetPinClip(
GlPoint *inPt; GlPoint *inPt,
GCRChannel *inCh; GCRChannel *inCh,
int heapCost; int heapCost,
Rect *dRect, *pRect; Rect *dRect,
Rect *pRect)
{ {
int bloat, estCost, t; int bloat, estCost, t;
Rect r; Rect r;
@ -1272,9 +1274,9 @@ glSetPinClip(inPt, inCh, heapCost, dRect, pRect)
*/ */
void void
glResetCost(headPage, headFree) glResetCost(
GlPage *headPage; GlPage *headPage,
int headFree; int headFree)
{ {
GlPage *gpage; GlPage *gpage;
GCRPin *pin; GCRPin *pin;
@ -1315,10 +1317,10 @@ glResetCost(headPage, headFree)
*/ */
int int
glPropagateFn(outCh, outPin, inPt) glPropagateFn(
GCRChannel *outCh; /* Channel entered from outPin */ GCRChannel *outCh, /* Channel entered from outPin */
GCRPin *outPin; /* Exit pin, also in inCh */ GCRPin *outPin, /* Exit pin, also in inCh */
GlPoint *inPt; /* Point being considered */ GlPoint *inPt) /* Point being considered */
{ {
int cost, n; int cost, n;
int finalCost; int finalCost;
@ -1403,14 +1405,14 @@ glPropagateFn(outCh, outPin, inPt)
*/ */
int int
glCrossPenalty(cost, inCh, outCh, inPin, outPin) glCrossPenalty(
int cost; /* Distance cost */ int cost, /* Distance cost */
GCRChannel *inCh; /* Both inPin and outPin are in this channel */ GCRChannel *inCh, /* Both inPin and outPin are in this channel */
GCRChannel *outCh; /* Channel to which outPin exits, or NULL GCRChannel *outCh, /* Channel to which outPin exits, or NULL
* if outPin is the destination. * if outPin is the destination.
*/ */
GCRPin *inPin; /* Pin used to enter inCh */ GCRPin *inPin, /* Pin used to enter inCh */
GCRPin *outPin; /* Pin used to exit inCh into outCh */ GCRPin *outPin) /* Pin used to exit inCh into outCh */
{ {
GCRPin *otherPin; GCRPin *otherPin;
int count; int count;
@ -1518,9 +1520,10 @@ glCrossPenalty(cost, inCh, outCh, inPin, outPin)
*/ */
bool bool
glDensityExceeded(inCh, inPin, outPin) glDensityExceeded(
GCRChannel *inCh; GCRChannel *inCh,
GCRPin *inPin, *outPin; GCRPin *inPin,
GCRPin *outPin)
{ {
int min, max, maxdensity; int min, max, maxdensity;
short *den; short *den;
@ -1590,10 +1593,10 @@ glDensityExceeded(inCh, inPin, outPin)
*/ */
void void
glRectToRange(ch, r, pr) glRectToRange(
GCRChannel *ch; GCRChannel *ch,
Rect *r; Rect *r,
PinRanges *pr; PinRanges *pr)
{ {
Rect clipR; Rect clipR;
@ -1642,8 +1645,9 @@ glRectToRange(ch, r, pr)
*/ */
bool bool
glJogsAcrossChannel(inPin, outPin) glJogsAcrossChannel(
GCRPin *inPin, *outPin; GCRPin *inPin,
GCRPin *outPin)
{ {
switch (inPin->gcr_side) switch (inPin->gcr_side)
{ {
@ -1691,11 +1695,13 @@ glJogsAcrossChannel(inPin, outPin)
*/ */
void void
glPropagateDebug(inPt, inPin, outCh, outPin, prevCost, distCost) glPropagateDebug(
GlPoint *inPt; GlPoint *inPt,
GCRPin *inPin, *outPin; GCRPin *inPin,
GCRChannel *outCh; GCRChannel *outCh,
int prevCost, distCost; GCRPin *outPin,
int prevCost,
int distCost)
{ {
char mesg[256]; char mesg[256];
Point linkedPt; Point linkedPt;
@ -1752,9 +1758,9 @@ glPropagateDebug(inPt, inPin, outCh, outPin, prevCost, distCost)
*/ */
void void
glLogPath(inPt, cost) glLogPath(
GlPoint *inPt; GlPoint *inPt,
int cost; int cost)
{ {
extern Rect glInitRect; extern Rect glInitRect;
@ -1784,8 +1790,8 @@ glLogPath(inPt, cost)
*/ */
void void
glPrintPoint(inPt) glPrintPoint(
GlPoint *inPt; GlPoint *inPt)
{ {
TxPrintf("(%d,%d) l=%d p=0x%x c=0x%x", TxPrintf("(%d,%d) l=%d p=0x%x c=0x%x",
inPt->gl_point.p_x, inPt->gl_point.p_y, inPt->gl_point.p_x, inPt->gl_point.p_y,

View File

@ -69,10 +69,10 @@ GlPage *glPathCurPage = NULL;
*/ */
void void
glListAdd(list, pin, cost) glListAdd(
GlPoint **list; /* Linked via gl_path pointers */ GlPoint **list, /* Linked via gl_path pointers */
GCRPin *pin; GCRPin *pin,
int cost; int cost)
{ {
GlPoint *newPt; GlPoint *newPt;
@ -106,9 +106,9 @@ glListAdd(list, pin, cost)
*/ */
void void
glListToHeap(list, destPt) glListToHeap(
GlPoint *list; /* List of points linked via gl_path pointers */ GlPoint *list, /* List of points linked via gl_path pointers */
Point *destPt; Point *destPt)
{ {
GlPoint *temp, *new; GlPoint *temp, *new;
GCRPin *pin; GCRPin *pin;
@ -164,8 +164,8 @@ glListToHeap(list, destPt)
*/ */
GlPoint * GlPoint *
glPathCopyPerm(list) glPathCopyPerm(
GlPoint *list; GlPoint *list)
{ {
GlPoint *new, *prev, *first; GlPoint *new, *prev, *first;
@ -183,8 +183,8 @@ glPathCopyPerm(list)
} }
int int
glPathFreePerm(list) glPathFreePerm(
GlPoint *list; GlPoint *list)
{ {
GlPoint *p; GlPoint *p;
@ -213,10 +213,10 @@ glPathFreePerm(list)
*/ */
GlPoint * GlPoint *
glPathNew(pin, cost, prev) glPathNew(
GCRPin *pin; /* Pin at the crossing point (mustn't be NULL) */ GCRPin *pin, /* Pin at the crossing point (mustn't be NULL) */
int cost; /* The cost to get here from source */ int cost, /* The cost to get here from source */
GlPoint *prev; /* Point from which the new one was visited */ GlPoint *prev) /* Point from which the new one was visited */
{ {
GlPoint *result; GlPoint *result;

View File

@ -73,8 +73,8 @@ CZone *glPenFindCZones();
*/ */
void void
glPenSetPerChan(net) glPenSetPerChan(
NLNet *net; NLNet *net)
{ {
CZone *czNet, *czChan; CZone *czNet, *czChan;
GlobChan *gc; GlobChan *gc;
@ -92,8 +92,8 @@ glPenSetPerChan(net)
} }
int int
glPenClearPerChan(net) glPenClearPerChan(
NLNet *net; NLNet *net)
{ {
CZone *czNet, *czChan; CZone *czNet, *czChan;
GlobChan *gc; GlobChan *gc;
@ -181,9 +181,9 @@ glPenClearPerChan(net)
*/ */
void void
glPenCompute(chanList, netList) glPenCompute(
GCRChannel *chanList; /* All the channels in the routing problem */ GCRChannel *chanList, /* All the channels in the routing problem */
NLNetList *netList; /* Netlist being routed */ NLNetList *netList) /* Netlist being routed */
{ {
#ifdef notdef #ifdef notdef
CZone *czones, *cz; CZone *czones, *cz;
@ -263,8 +263,8 @@ glPenCompute(chanList, netList)
*/ */
CZone * CZone *
glPenFindCZones(chanList) glPenFindCZones(
GCRChannel *chanList; /* All the channels in the routing problem */ GCRChannel *chanList) /* All the channels in the routing problem */
{ {
CZone *czList; CZone *czList;
DensMap *dmap; DensMap *dmap;
@ -300,11 +300,11 @@ glPenFindCZones(chanList)
*/ */
CZone * CZone *
glPenScanDens(czList, ch, dm, type) glPenScanDens(
CZone *czList; /* Prepend to this list */ CZone *czList, /* Prepend to this list */
GCRChannel *ch; /* Which channel is being processed */ GCRChannel *ch, /* Which channel is being processed */
DensMap *dm; /* Map to search */ DensMap *dm, /* Map to search */
int type; /* Type of zone: CZ_ROW or CZ_COL */ int type) /* Type of zone: CZ_ROW or CZ_COL */
{ {
short *val = dm->dm_value; short *val = dm->dm_value;
CZone *cz; CZone *cz;
@ -381,9 +381,9 @@ glPenScanDens(czList, ch, dm, type)
*/ */
void void
glPenAssignCosts(cz, netList) glPenAssignCosts(
CZone *cz; /* A single CZone being processed */ CZone *cz, /* A single CZone being processed */
NLNetList *netList; /* List of all nets; we look for nets that cross NLNetList *netList) /* List of all nets; we look for nets that cross
* this zone. * this zone.
*/ */
{ {
@ -484,8 +484,9 @@ glPenAssignCosts(cz, netList)
*/ */
int int
glPenSortNetSet(ns1, ns2) glPenSortNetSet(
NetSet **ns1, **ns2; NetSet **ns1,
NetSet **ns2)
{ {
if ((*ns1)->ns_cost > (*ns2)->ns_cost) return 1; if ((*ns1)->ns_cost > (*ns2)->ns_cost) return 1;
if ((*ns1)->ns_cost < (*ns2)->ns_cost) return -1; if ((*ns1)->ns_cost < (*ns2)->ns_cost) return -1;
@ -518,9 +519,9 @@ struct glCrossClient
}; };
NetSet * NetSet *
glPenFindCrossingNets(cz, netList) glPenFindCrossingNets(
CZone *cz; /* A single CZone being processed */ CZone *cz, /* A single CZone being processed */
NLNetList *netList; /* List of all nets; we look for nets that cross NLNetList *netList) /* List of all nets; we look for nets that cross
* this zone. * this zone.
*/ */
{ {
@ -566,10 +567,11 @@ glPenFindCrossingNets(cz, netList)
/*ARGSUSED*/ /*ARGSUSED*/
int int
glPenFindCrossingFunc(cz, srcPin, dstPin, rcc) glPenFindCrossingFunc(
CZone *cz; /* UNUSED */ CZone *cz, /* UNUSED */
GCRPin *srcPin, *dstPin; /* UNUSED */ GCRPin *srcPin,
struct glCrossClient *rcc; GCRPin *dstPin,
struct glCrossClient *rcc)
{ {
NetSet *ns; NetSet *ns;
@ -615,11 +617,11 @@ glPenFindCrossingFunc(cz, srcPin, dstPin, rcc)
*/ */
int int
glPenEnumCross(cz, rp, func, cdata) glPenEnumCross(
CZone *cz; /* Look for segments passing through here */ CZone *cz, /* Look for segments passing through here */
GlPoint *rp; /* List of GlPoints (linked by gl_path ptrs) */ GlPoint *rp, /* List of GlPoints (linked by gl_path ptrs) */
int (*func)(); /* Apply to each segment passing through cz */ int (*func)(), /* Apply to each segment passing through cz */
ClientData cdata; /* Passed to (*func)() */ ClientData cdata) /* Passed to (*func)() */
{ {
GCRPin *srcPin, *dstPin; GCRPin *srcPin, *dstPin;
int cSrc, cDst; int cSrc, cDst;
@ -674,9 +676,9 @@ glPenEnumCross(cz, rp, func, cdata)
*/ */
int int
glPenRerouteNetCost(cz, net) glPenRerouteNetCost(
CZone *cz; CZone *cz,
NLNet *net; /* Net to be rerouted */ NLNet *net) /* Net to be rerouted */
{ {
NetClient *nc = (NetClient *) net->nnet_cdata; NetClient *nc = (NetClient *) net->nnet_cdata;
CZone fakeCZ; CZone fakeCZ;
@ -707,11 +709,11 @@ glPenRerouteNetCost(cz, net)
/*ARGSUSED*/ /*ARGSUSED*/
int int
glPenRouteCost(rootUse, bestPath, pNetId, pCost) glPenRouteCost(
CellUse *rootUse; /* UNUSED */ CellUse *rootUse, /* UNUSED */
GlPoint *bestPath; /* Best path for this segment */ GlPoint *bestPath, /* Best path for this segment */
NetId *pNetId; /* UNUSED */ NetId *pNetId, /* UNUSED */
int *pCost; /* Add bestPath->gl_cost to this */ int *pCost) /* Add bestPath->gl_cost to this */
{ {
*pCost += bestPath->gl_cost; *pCost += bestPath->gl_cost;
return 0; return 0;
@ -739,10 +741,10 @@ glPenRouteCost(rootUse, bestPath, pNetId, pCost)
*/ */
int int
glPenDeleteNet(dm, list, cz) glPenDeleteNet(
DensMap *dm; /* Update this map */ DensMap *dm, /* Update this map */
List *list; /* List of paths */ List *list, /* List of paths */
CZone *cz; /* Remove all segments passing through 'cz' from 'dm' */ CZone *cz) /* Remove all segments passing through 'cz' from 'dm' */
{ {
for ( ; list; list = LIST_TAIL(list)) for ( ; list; list = LIST_TAIL(list))
(void) glPenEnumCross(cz, (GlPoint *) LIST_FIRST(list), (void) glPenEnumCross(cz, (GlPoint *) LIST_FIRST(list),
@ -768,10 +770,11 @@ glPenDeleteNet(dm, list, cz)
*/ */
int int
glPenDeleteFunc(cz, srcPin, dstPin, dm) glPenDeleteFunc(
CZone *cz; /* Being passed through by srcPin..dstPin */ CZone *cz, /* Being passed through by srcPin..dstPin */
GCRPin *srcPin, *dstPin; /* Two pins in cz->cz_chan */ GCRPin *srcPin,
DensMap *dm; /* Remove srcPin..dstPin segment from 'dm' */ GCRPin *dstPin,
DensMap *dm) /* Remove srcPin..dstPin segment from 'dm' */
{ {
int n; int n;
int lo, hi; int lo, hi;
@ -819,8 +822,8 @@ glPenDeleteFunc(cz, srcPin, dstPin, dm)
*/ */
void void
glPenCleanNet(net) glPenCleanNet(
NLNet *net; NLNet *net)
{ {
List *list; List *list;
NetClient *nc; NetClient *nc;
@ -851,10 +854,10 @@ glPenCleanNet(net)
*/ */
void void
glPenSavePath(rootUse, path, pNetId) glPenSavePath(
CellUse *rootUse; /* UNUSED */ CellUse *rootUse, /* UNUSED */
GlPoint *path; /* Path linked via gl_path pointers */ GlPoint *path, /* Path linked via gl_path pointers */
NetId *pNetId; /* Net and segment identifier */ NetId *pNetId) /* Net and segment identifier */
{ {
GlPoint *newpath; GlPoint *newpath;
NetClient *nc; NetClient *nc;
@ -884,8 +887,8 @@ glPenSavePath(rootUse, path, pNetId)
*/ */
void void
glPenDensitySet(net) glPenDensitySet(
NLNet *net; NLNet *net)
{ {
NetClient *nc = (NetClient *) net->nnet_cdata; NetClient *nc = (NetClient *) net->nnet_cdata;
GCRPin *srcPin, *dstPin; GCRPin *srcPin, *dstPin;

View File

@ -58,10 +58,10 @@ static char sccsid[] = "@(#)groutePin.c 4.9 MAGIC (Berkeley) 12/8/85";
*/ */
GCRPin * GCRPin *
glPointToPin(ch, side, point) glPointToPin(
GCRChannel *ch; /* The channel containing the point */ GCRChannel *ch, /* The channel containing the point */
int side; /* Side of ch that point lies on */ int side, /* Side of ch that point lies on */
Point *point; /* The point to be converted to a pin */ Point *point) /* The point to be converted to a pin */
{ {
int coord; int coord;
@ -131,8 +131,8 @@ glPointToPin(ch, side, point)
*/ */
void void
GLInitPins(ch) GLInitPins(
GCRChannel *ch; GCRChannel *ch)
{ {
glPinArrayInit(ch, GEO_NORTH, ch->gcr_tPins, ch->gcr_length); glPinArrayInit(ch, GEO_NORTH, ch->gcr_tPins, ch->gcr_length);
glPinArrayInit(ch, GEO_SOUTH, ch->gcr_bPins, ch->gcr_length); glPinArrayInit(ch, GEO_SOUTH, ch->gcr_bPins, ch->gcr_length);
@ -141,10 +141,11 @@ GLInitPins(ch)
} }
void void
glPinArrayInit(ch, side, pins, nPins) glPinArrayInit(
GCRChannel *ch; GCRChannel *ch,
GCRPin *pins; int side,
int nPins; GCRPin *pins,
int nPins)
{ {
GCRPin *pin, *linked; GCRPin *pin, *linked;
GCRChannel *adjacent; GCRChannel *adjacent;
@ -275,8 +276,8 @@ glPinArrayInit(ch, side, pins, nPins)
*/ */
bool bool
GLBlockPins(ch) GLBlockPins(
GCRChannel *ch; GCRChannel *ch)
{ {
bool changed; bool changed;
@ -294,13 +295,13 @@ GLBlockPins(ch)
} }
bool bool
glPinArrayBlock(ch, pins, opins, nPins) glPinArrayBlock(
GCRChannel *ch; /* Channel pins belong to */ GCRChannel *ch, /* Channel pins belong to */
GCRPin *pins; /* Processing this side of channel */ GCRPin *pins, /* Processing this side of channel */
GCRPin *opins; /* Pins on opposite side; used only if ch is a GCRPin *opins, /* Pins on opposite side; used only if ch is a
* river-routing channel. * river-routing channel.
*/ */
int nPins; /* Number of internal pins (not counting pins[0]) */ int nPins) /* Number of internal pins (not counting pins[0]) */
{ {
bool changed, isRiver = (ch->gcr_type != CHAN_NORMAL); bool changed, isRiver = (ch->gcr_type != CHAN_NORMAL);
GCRPin *pin, *opin, *linked; GCRPin *pin, *opin, *linked;
@ -353,8 +354,8 @@ glPinArrayBlock(ch, pins, opins, nPins)
*/ */
void void
GLLinkPins(ch) GLLinkPins(
GCRChannel *ch; GCRChannel *ch)
{ {
glPinArrayLink(ch->gcr_tPins, ch->gcr_length); glPinArrayLink(ch->gcr_tPins, ch->gcr_length);
glPinArrayLink(ch->gcr_bPins, ch->gcr_length); glPinArrayLink(ch->gcr_bPins, ch->gcr_length);
@ -363,9 +364,9 @@ GLLinkPins(ch)
} }
void void
glPinArrayLink(pins, nPins) glPinArrayLink(
GCRPin *pins; GCRPin *pins,
int nPins; int nPins)
{ {
GCRPin *pin, *lastPin, *lastValid; GCRPin *pin, *lastPin, *lastValid;
@ -386,8 +387,8 @@ glPinArrayLink(pins, nPins)
} }
} }
glShowPin(pin) glShowPin(
GCRPin *pin; GCRPin *pin)
{ {
char mesg[256]; char mesg[256];
Rect r, area; Rect r, area;
@ -453,8 +454,8 @@ glShowPin(pin)
*/ */
void void
GLFixStemPins(ch) GLFixStemPins(
GCRChannel *ch; GCRChannel *ch)
{ {
glPinArrayFixStems(ch->gcr_tPins, ch->gcr_length); glPinArrayFixStems(ch->gcr_tPins, ch->gcr_length);
glPinArrayFixStems(ch->gcr_bPins, ch->gcr_length); glPinArrayFixStems(ch->gcr_bPins, ch->gcr_length);
@ -463,9 +464,9 @@ GLFixStemPins(ch)
} }
void void
glPinArrayFixStems(pins, nPins) glPinArrayFixStems(
GCRPin *pins; GCRPin *pins,
int nPins; int nPins)
{ {
GCRPin *pin, *lastPin; GCRPin *pin, *lastPin;

View File

@ -111,9 +111,9 @@ void glShowCross();
*/ */
void void
GlTest(w, cmd) GlTest(
MagWindow *w; MagWindow *w,
TxCommand *cmd; TxCommand *cmd)
{ {
int glDebugSides(); int glDebugSides();
typedef enum { CLRDEBUG, ONLYNET, SETDEBUG, SHOWDEBUG, SIDES } cmdType; typedef enum { CLRDEBUG, ONLYNET, SETDEBUG, SHOWDEBUG, SIDES } cmdType;
@ -209,8 +209,8 @@ badCmd:
} }
int int
glDebugSides(side) glDebugSides(
Side *side; Side *side)
{ {
char mesg[256]; char mesg[256];
CellDef *def = EditCellUse->cu_def; CellDef *def = EditCellUse->cu_def;
@ -311,9 +311,10 @@ GlInit()
*/ */
void void
glShowPath(dest, root, kind) glShowPath(
GlPoint *dest, *root; GlPoint *dest,
int kind; GlPoint *root,
int kind)
{ {
static NetId dummyId = { 0, 0 }; static NetId dummyId = { 0, 0 };
GlPoint *temp; GlPoint *temp;
@ -343,10 +344,10 @@ glShowPath(dest, root, kind)
*/ */
void void
glShowCross(pin, netId, kind) glShowCross(
GCRPin *pin; /* Pin itself */ GCRPin *pin, /* Pin itself */
NetId netId; /* Identifies net and segment for this pin */ NetId netId, /* Identifies net and segment for this pin */
int kind; /* Determines kind of display; see above */ int kind) /* Determines kind of display; see above */
{ {
char *name, name1[1024], name2[1024]; char *name, name1[1024], name2[1024];
int style; int style;
@ -402,8 +403,10 @@ glShowCross(pin, netId, kind)
*/ */
void void
glHistoAdd(heapPtsBefore, frontierPtsBefore, startPtsBefore) glHistoAdd(
int heapPtsBefore, frontierPtsBefore, startPtsBefore; int heapPtsBefore,
int frontierPtsBefore,
int startPtsBefore)
{ {
GlNetHisto *gh; GlNetHisto *gh;
@ -575,9 +578,9 @@ glStatsInit()
*/ */
void void
glStatsDone(numNets, numTerms) glStatsDone(
int numNets; int numNets,
int numTerms; int numTerms)
{ {
if (DebugIsSet(glDebugID, glDebVerbose)) if (DebugIsSet(glDebugID, glDebVerbose))

View File

@ -233,7 +233,7 @@ extern CellUse *glChanUse;
/* Internal procedures */ /* Internal procedures */
GlPoint *glPathNew(); GlPoint *glPathNew();
GlPoint *glPathCopyPerm(); GlPoint *glPathCopyPerm();
GlPoint *glProcessLoc(); GlPoint *glProcessLoc(GlPoint *startList, NLTermLoc *loc, int bestCost, bool doFast);
Tile *glChanPinToTile(); Tile *glChanPinToTile();
void glCrossMark(); void glCrossMark();