From d93a11b8ea39294d74f1beb3116b0c1707778b98 Mon Sep 17 00:00:00 2001 From: Holger Vogt Date: Mon, 17 Nov 2025 23:56:50 +0100 Subject: [PATCH] Remove unused functions from the IFfrontEnd struct. --- src/frontend/outitf.c | 72 ++----------------------------------- src/frontend/outitf.h | 9 ----- src/include/ngspice/ifsim.h | 15 -------- src/main.c | 13 ++----- src/sharedspice.c | 6 ---- 5 files changed, 4 insertions(+), 111 deletions(-) diff --git a/src/frontend/outitf.c b/src/frontend/outitf.c index 8e9bcd9ce..91cb49624 100644 --- a/src/frontend/outitf.c +++ b/src/frontend/outitf.c @@ -118,20 +118,6 @@ OUTpBeginPlot(CKTcircuit *circuitPtr, JOB *analysisPtr, } -int -OUTwBeginPlot(CKTcircuit *circuitPtr, JOB *analysisPtr, - IFuid analName, - IFuid refName, int refType, - int numNames, IFuid *dataNames, int dataType, runDesc **plotPtr) -{ - - return (beginPlot(analysisPtr, circuitPtr, "circuit name", - analName, refName, refType, numNames, - dataNames, dataType, TRUE, - plotPtr)); -} - - static int beginPlot(JOB *analysisPtr, CKTcircuit *circuitPtr, char *cktName, char *analName, char *refName, int refType, int numNames, char **dataNames, int dataType, bool windowed, runDesc **runp) { @@ -148,10 +134,9 @@ beginPlot(JOB *analysisPtr, CKTcircuit *circuitPtr, char *cktName, char *analNam bool savenointernals = FALSE; char *an_name; int initmem; - /*to resume a run saj - *All it does is reassign the file pointer and return (requires *runp to be NULL if this is not needed) - */ + /*to resume a run, Reassign the file pointer and return + (requires *runp to be NULL if this is not needed)*/ if (dataType == 666 && numNames == 666) { run = *runp; run->writeOut = ft_getOutReq(&run->fp, &run->runPlot, &run->binary, @@ -801,38 +786,6 @@ OUTpData(runDesc *plotPtr, IFvalue *refValue, IFvalue *valuePtr) } /* end of function OUTpData */ - -int OUTwReference(runDesc*plotPtr, IFvalue *valuePtr, void **refPtr) -{ - NG_IGNORE(refPtr); - NG_IGNORE(valuePtr); - NG_IGNORE(plotPtr); - - return OK; -} - - -int -OUTwData(runDesc *plotPtr, int dataIndex, IFvalue *valuePtr, void *refPtr) -{ - NG_IGNORE(refPtr); - NG_IGNORE(valuePtr); - NG_IGNORE(dataIndex); - NG_IGNORE(plotPtr); - - return OK; -} - - -int -OUTwEnd(runDesc *plotPtr) -{ - NG_IGNORE(plotPtr); - - return OK; -} - - int OUTendPlot(runDesc *plotPtr) { @@ -852,27 +805,6 @@ OUTendPlot(runDesc *plotPtr) } -int -OUTbeginDomain(runDesc *plotPtr, IFuid refName, int refType, IFvalue *outerRefValue) -{ - NG_IGNORE(outerRefValue); - NG_IGNORE(refType); - NG_IGNORE(refName); - NG_IGNORE(plotPtr); - - return (OK); -} - - -int -OUTendDomain(runDesc *plotPtr) -{ - NG_IGNORE(plotPtr); - - return (OK); -} - - int OUTattributes(runDesc *plotPtr, IFuid varName, int param, IFvalue *value) { diff --git a/src/frontend/outitf.h b/src/frontend/outitf.h index efb333119..cf4895d7e 100644 --- a/src/frontend/outitf.h +++ b/src/frontend/outitf.h @@ -50,17 +50,8 @@ int OUTpBeginPlot(CKTcircuit *circuitPtr, JOB *analysisPtr, IFuid analName, IFuid refName, int refType, int numNames, IFuid *dataNames, int dataType, runDesc **plotPtr); -int OUTwBeginPlot(CKTcircuit *circuitPtr, JOB *analysisPtr, - IFuid analName, - IFuid refName, int refType, - int numNames, IFuid *dataNames, int dataType, runDesc **plotPtr); int OUTpData(runDesc *plotPtr, IFvalue *refValue, IFvalue *valuePtr); -int OUTwReference(runDesc *plotPtr, IFvalue *valuePtr, void **refPtr); -int OUTwData(runDesc *plotPtr, int dataIndex, IFvalue *valuePtr, void *refPtr); -int OUTwEnd(runDesc *plotPtr); int OUTendPlot(runDesc *plotPtr); -int OUTbeginDomain(runDesc *plotPtr, IFuid refName, int refType, IFvalue *outerRefValue); -int OUTendDomain(runDesc *plotPtr); int OUTattributes(runDesc *plotPtr, IFuid varName, int param, IFvalue *value); int OUTstopnow(void); void OUTerror(int flags, char *format, IFuid *names); diff --git a/src/include/ngspice/ifsim.h b/src/include/ngspice/ifsim.h index cf019be2e..ca2f0787f 100644 --- a/src/include/ngspice/ifsim.h +++ b/src/include/ngspice/ifsim.h @@ -455,23 +455,8 @@ struct IFfrontEnd { /* start pointwise output plot */ int (*OUTpData) (runDesc *, IFvalue *, IFvalue *); /* data for pointwise plot */ - int (*OUTwBeginPlot) (CKTcircuit *, JOB *, - IFuid, - IFuid, int, - int, IFuid *, int, runDesc **); - /* start windowed output plot */ - int (*OUTwReference) (runDesc *, IFvalue *, void **); - /* independent vector for windowed plot */ - int (*OUTwData) (runDesc *, int, IFvalue *, void *); - /* data for windowed plot */ - int (*OUTwEnd) (runDesc *); - /* signal end of windows */ int (*OUTendPlot) (runDesc *); /* end of plot */ - int (*OUTbeginDomain) (runDesc *, IFuid, int, IFvalue *); - /* start nested domain */ - int (*OUTendDomain) (runDesc *); - /* end nested domain */ int (*OUTattributes) (runDesc *, IFuid, int, IFvalue *); /* specify output attributes of node */ }; diff --git a/src/main.c b/src/main.c index 723855c7a..c547d5475 100644 --- a/src/main.c +++ b/src/main.c @@ -200,11 +200,8 @@ struct comm *cp_coms = spcp_coms; extern int OUTpBeginPlot(CKTcircuit *, JOB *, IFuid, IFuid, int, int, IFuid *, int, runDesc **); extern int OUTpData(runDesc *, IFvalue *, IFvalue *); -extern int OUTwBeginPlot(CKTcircuit *, JOB *, IFuid, IFuid, int, int, IFuid *, int, runDesc **); -extern int OUTwReference(runDesc *, IFvalue *, void **); -extern int OUTwData(runDesc *, int, IFvalue *, void *), OUTwEnd(runDesc *), OUTendPlot(runDesc *); -extern int OUTbeginDomain(runDesc *, IFuid, int, IFvalue *); -extern int OUTendDomain(runDesc *), OUTstopnow(void); +extern int OUTendPlot(runDesc *); +extern int OUTstopnow(void); extern void OUTerror(int, char *, IFuid *); #ifdef __GNUC__ @@ -224,13 +221,7 @@ IFfrontEnd nutmeginfo = { OUTerrorf, OUTpBeginPlot, OUTpData, - OUTwBeginPlot, - OUTwReference, - OUTwData, - OUTwEnd, OUTendPlot, - OUTbeginDomain, - OUTendDomain, OUTattributes }; diff --git a/src/sharedspice.c b/src/sharedspice.c index 5049fd12a..b7c660c87 100644 --- a/src/sharedspice.c +++ b/src/sharedspice.c @@ -258,13 +258,7 @@ IFfrontEnd nutmeginfo = { OUTerrorf, OUTpBeginPlot, OUTpData, - OUTwBeginPlot, - OUTwReference, - OUTwData, - OUTwEnd, OUTendPlot, - OUTbeginDomain, - OUTendDomain, OUTattributes };