Browse Source

Improve efficiency and irreversible CM support in EVTcall_hybrids() by

halting calls to code models as soon as the timestep is chenged.
This should have been included in 508fad0f55.
pre-master-46
Giles Atkinson 2 years ago
committed by Holger Vogt
parent
commit
ffcf3b24d9
  1. 9
      src/xspice/evt/evtcall_hybrids.c

9
src/xspice/evt/evtcall_hybrids.c

@ -45,6 +45,7 @@ NON-STANDARD FEATURES
#include "ngspice/ngspice.h" #include "ngspice/ngspice.h"
#include "ngspice/cktdefs.h" #include "ngspice/cktdefs.h"
#include "ngspice/mif.h"
#include "ngspice/evt.h" #include "ngspice/evt.h"
#include "ngspice/evtproto.h" #include "ngspice/evtproto.h"
@ -74,6 +75,12 @@ void EVTcall_hybrids(
/* Call EVTload for all hybrids */ /* Call EVTload for all hybrids */
for(i = 0; i < num_hybrids; i++)
for(i = 0; i < num_hybrids; i++) {
EVTload_with_event(ckt, hybrids[i], MIF_STEP_PENDING); EVTload_with_event(ckt, hybrids[i], MIF_STEP_PENDING);
if (g_mif_info.breakpoint.current < ckt->CKTtime) {
/* An XSPICE instance rejected the time-step. */
break;
}
}
} }
Loading…
Cancel
Save