mirror of
https://git.code.sf.net/p/ngspice/ngspice
synced 2026-09-06 03:51:27 +02:00
Change output event setup in evtload.c so that, when making an event call
to a code model, there is no longer a reference to the value of the event at the head of the free list. That allows all such free lists (with the same data type) to be combined, probably improving performance. This is in preparation for full implementation of inertial delay for digital nodes.
This commit is contained in:
committed by
Holger Vogt
parent
2d0561f386
commit
c1659a64c3
@@ -172,7 +172,7 @@ struct Evt_Output_Queue {
|
||||
Evt_Output_Event_t **head; /* Beginning of linked lists */
|
||||
Evt_Output_Event_t ***current; /* Beginning of pending events */
|
||||
Evt_Output_Event_t ***last_step; /* Values of 'current' at last accepted timepoint */
|
||||
Evt_Output_Event_t **free; /* Linked lists of items freed by backups */
|
||||
Evt_Output_Event_t ***free_list; /* Pointers to linked lists of items freed by backups */
|
||||
double last_time; /* Time at which last_step was set */
|
||||
double next_time; /* Earliest next event time in queue */
|
||||
int num_modified; /* Number modified since last accepted timepoint */
|
||||
|
||||
@@ -134,5 +134,6 @@ bool Evtcheck_nodes(
|
||||
struct INPtables *stab); /* Symbol table. */
|
||||
|
||||
struct dvec *EVTfindvec(char *node);
|
||||
void Evt_purge_free_outputs(void);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -99,20 +99,22 @@ NON-STANDARD FEATURES
|
||||
void **evt_ipc_val, \
|
||||
int *evt_ipc_val_size
|
||||
|
||||
/* Information about each Digital/User-defined type of node value. */
|
||||
|
||||
typedef struct {
|
||||
char *name;
|
||||
char *description;
|
||||
void ((*create)(CREATE_ARGS));
|
||||
void ((*dismantle)(DISMANTLE_ARGS));
|
||||
void ((*initialize)(INITIALIZE_ARGS));
|
||||
void ((*invert)(INVERT_ARGS));
|
||||
void ((*copy)(COPY_ARGS));
|
||||
void ((*resolve)(RESOLVE_ARGS));
|
||||
void ((*compare)(COMPARE_ARGS));
|
||||
void ((*plot_val)(PLOT_VAL_ARGS));
|
||||
void ((*print_val)(PRINT_VAL_ARGS));
|
||||
void ((*ipc_val)(IPC_VAL_ARGS));
|
||||
char *name;
|
||||
char *description;
|
||||
Evt_Output_Event_t *free_list; /* Event structs for these values. */
|
||||
void ((*create)(CREATE_ARGS));
|
||||
void ((*dismantle)(DISMANTLE_ARGS));
|
||||
void ((*initialize)(INITIALIZE_ARGS));
|
||||
void ((*invert)(INVERT_ARGS));
|
||||
void ((*copy)(COPY_ARGS));
|
||||
void ((*resolve)(RESOLVE_ARGS));
|
||||
void ((*compare)(COMPARE_ARGS));
|
||||
void ((*plot_val)(PLOT_VAL_ARGS));
|
||||
void ((*print_val)(PRINT_VAL_ARGS));
|
||||
void ((*ipc_val)(IPC_VAL_ARGS));
|
||||
} Evt_Udn_Info_t;
|
||||
|
||||
|
||||
|
||||
@@ -226,6 +226,7 @@ typedef struct Mif_Port_Data_s {
|
||||
Mif_Boolean_t is_null; /* Set to true if null in SPICE deck */
|
||||
Mif_Value_t input; /* The input value */
|
||||
Mif_Value_t output; /* The output value */
|
||||
struct Evt_Output_Event *next_event;
|
||||
Mif_Partial_t *partial; /* Partials for this port wrt inputs */
|
||||
Mif_AC_Gain_t *ac_gain; /* AC gains for this port wrt inputs */
|
||||
int old_input; /* Index into CKTstate for old input */
|
||||
|
||||
Reference in New Issue
Block a user