Do not set a breakpoint at current time,
as this may lead to trigger a "breakpoint in the past" message and stop the simulation, depending on double precision details during comparison.
This commit is contained in:
parent
9ee9f9262b
commit
7dd44f12e0
|
|
@ -27,6 +27,13 @@ CKTsetBreak(CKTcircuit *ckt, double time)
|
||||||
printf("[t:%e] \t want breakpoint for t = %e\n", ckt->CKTtime, time);
|
printf("[t:%e] \t want breakpoint for t = %e\n", ckt->CKTtime, time);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
if (AlmostEqualUlps(time, ckt->CKTtime, 3)) {
|
||||||
|
#ifdef TRACE_BREAKPOINT // #if (1)
|
||||||
|
fprintf(stderr, "Warning: Setting a new breakpoint at %e is ignored,\n as current time is %e\n", time, ckt->CKTtime);
|
||||||
|
#endif
|
||||||
|
return (OK);
|
||||||
|
}
|
||||||
|
|
||||||
if(ckt->CKTtime > time) {
|
if(ckt->CKTtime > time) {
|
||||||
SPfrontEnd->IFerrorf (ERR_PANIC, "breakpoint in the past - HELP!");
|
SPfrontEnd->IFerrorf (ERR_PANIC, "breakpoint in the past - HELP!");
|
||||||
return(E_INTERN);
|
return(E_INTERN);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue