![]() |
NEURON
|
#include <../../nrnconf.h>
#include "bbsavestate.h"
#include "cabcode.h"
#include "classreg.h"
#include "nrncvode.h"
#include "nrnoc2iv.h"
#include "nrnran123.h"
#include "ocfile.h"
#include <cmath>
#include <nrnmpiuse.h>
#include <stdio.h>
#include <stdlib.h>
#include <string>
#include <sys/stat.h>
#include <unordered_map>
#include <unordered_set>
#include "netcon.h"
#include "nrniv_mf.h"
#include "tqueue.hpp"
#include "vrecitem.h"
#include "membfunc.h"
#include <ivocvect.h>
Go to the source code of this file.
Classes | |
class | BBSS_Cnt |
class | BBSS_TxtFileOut |
class | BBSS_TxtFileIn |
class | BBSS_BufferOut |
class | BBSS_BufferIn |
struct | StateStructInfo |
struct | DEList |
class | SEWrap |
Macros | |
#define | QUEUECHECK 1 |
#define | DEBUG 0 |
#define | PDEBUG f->s(dbuf, 1) |
Typedefs | |
typedef void(* | ReceiveFunc) (Point_process *, double *, double) |
typedef void(* | PFIO) (int, Object *) |
typedef std::vector< TQItem * > | TQItemList |
typedef std::unordered_map< Point_process *, int > | PointProcessMap |
typedef struct DEList | DEList |
typedef std::unordered_map< Point_process *, DEList * > | PP2DE |
typedef std::vector< double > | DblList |
typedef std::unordered_map< NetCon *, DblList * > | NetCon2DblList |
typedef std::vector< SEWrap * > | SEWrapList |
typedef std::unordered_map< int, int > | Int2Int |
typedef std::unordered_map< int, DblList * > | Int2DblList |
typedef std::unordered_map< std::string, Section * > | SecName2Sec |
Functions | |
static void | bbss_early (double td, TQItem *tq) |
void | nrn_shape_update () |
TQueue * | net_cvode_instance_event_queue (NrnThread *) |
void | nrn_netcon_event (NetCon *, double) |
void | nrn_gidout_iter (PFIO) |
Object * | nrn_gid2obj (int gid) |
PreSyn * | nrn_gid2presyn (int gid) |
int | nrn_gid_exists (int gid) |
static void | nrnmpi_barrier () |
static void | nrnmpi_int_alltoallv (const int *s, const int *scnt, const int *sdispl, int *r, int *rcnt, int *rdispl) |
static void | nrnmpi_dbl_alltoallv (const double *s, const int *scnt, const int *sdispl, double *r, int *rcnt, int *rdispl) |
static int | nrnmpi_int_allmax (int x) |
static void | nrnmpi_int_allgather (int *s, int *r, int n) |
static void | nrnmpi_int_allgatherv (int *s, int *r, int *n, int *dspl) |
static void | nrnmpi_dbl_allgatherv (double *s, double *r, int *n, int *dspl) |
void | nrn_play_init () |
static void | tqcallback (const TQItem *tq, int i) |
static void | bbss_queuecheck () |
static void * | cons (Object *) |
static void | destruct (void *v) |
static double | save (void *v) |
static void | bbss_restore_begin () |
static double | restore (void *v) |
static double | save_request (void *v) |
static double | save_gid (void *v) |
static double | restore_gid (void *v) |
static void | pycell_name2sec_maps_clear () |
static double | save_test (void *v) |
static double | save_test_bin (void *v) |
static double | ppignore (void *v) |
static int | ignored (Prop *p) |
void * | bbss_buffer_counts (int *len, int **gids, int **sizes, int *global_size) |
BBSaveState API See save_test_bin and restore_test_bin for an example of the use of this following interface. More... | |
void | bbss_save_global (void *bbss, char *buffer, int sz) |
Call only on host 0 with a buffer of size equal to the global_size returned from the bbss_buffer_counts call on host 0 sz is the size of the buffer (for error checking only, buffer+sz is out of bounds) More... | |
void | bbss_restore_global (void *bbss, char *buffer, int sz) |
Call on all hosts with the buffer contents returned from the call to bbss_save_global. More... | |
void | bbss_save (void *bbss, int gid, char *buffer, int sz) |
Call this for each item of the gids from bbss_buffer_counts along with a buffer of size from the corresponding sizes array. More... | |
void | bbss_restore (void *bbss, int gid, int ngroup, char *buffer, int sz) |
Call this for each item of the gids from bbss_buffer_counts, the number of buffers that were concatenated for the gid, and the concatenated buffer (the concatenated buffer does NOT contain npiece as the first value in the char* buffer pointer). More... | |
void | bbss_save_done (void *bbss) |
At the end of the save process, call this to cleanup. More... | |
static void | bbss_remove_delivered () |
void | bbss_restore_done (void *bbss) |
At the end of the restore process, call this to do some extra setting up and cleanup. More... | |
static double | restore_test (void *v) |
static double | restore_test_bin (void *v) |
static double | vector_play_init (void *v) |
void | BBSaveState_reg () |
static void | ssi_def () |
static double | binq_time (double tt) |
static void | del_presyn_info () |
static void | base2spgid_item (int spgid, Object *obj) |
static void | cb_gidobj (int gid, Object *obj) |
static void | pycell_name2sec_maps_fill () |
static SecName2Sec & | pycell_name2sec_map (Object *c) |
static void | all2allv_helper (int *scnt, int *sdispl, int *rcnt, int *rdispl) |
static void | all2allv_int2 (int *scnt, int *sdispl, int *gidsrc, int *ndsrc) |
static void | all2allv_dbl1 (int *scnt, int *sdispl, double *tssrc) |
static void | scatteritems () |
static void | allgatherv_helper (int cnt, int *rcnt, int *rdspl) |
static void | spikes_on_correct_host (int cnt, int *g, int *dcnts, int tscnt, double *ts, Int2DblList *m) |
static void | construct_presyn_queue () |
#define DEBUG 0 |
Definition at line 297 of file bbsavestate.cpp.
Definition at line 303 of file bbsavestate.cpp.
#define QUEUECHECK 1 |
Definition at line 291 of file bbsavestate.cpp.
typedef std::vector<double> DblList |
Definition at line 1095 of file bbsavestate.cpp.
typedef std::unordered_map<int, DblList*> Int2DblList |
Definition at line 1141 of file bbsavestate.cpp.
typedef std::unordered_map<int, int> Int2Int |
Definition at line 1137 of file bbsavestate.cpp.
typedef std::unordered_map<NetCon*, DblList*> NetCon2DblList |
Definition at line 1096 of file bbsavestate.cpp.
typedef void(* PFIO) (int, Object *) |
Definition at line 212 of file bbsavestate.cpp.
typedef std::unordered_map<Point_process*, int> PointProcessMap |
Definition at line 746 of file bbsavestate.cpp.
typedef std::unordered_map<Point_process*, DEList*> PP2DE |
Definition at line 1092 of file bbsavestate.cpp.
typedef void(* ReceiveFunc) (Point_process *, double *, double) |
Definition at line 200 of file bbsavestate.cpp.
typedef std::unordered_map<std::string, Section*> SecName2Sec |
Definition at line 1718 of file bbsavestate.cpp.
typedef std::vector<SEWrap*> SEWrapList |
Definition at line 1134 of file bbsavestate.cpp.
typedef std::vector<TQItem*> TQItemList |
Definition at line 287 of file bbsavestate.cpp.
|
static |
Definition at line 2370 of file bbsavestate.cpp.
|
static |
Definition at line 2329 of file bbsavestate.cpp.
|
static |
Definition at line 2346 of file bbsavestate.cpp.
|
static |
Definition at line 2485 of file bbsavestate.cpp.
|
static |
Definition at line 1518 of file bbsavestate.cpp.
void BBSaveState_reg | ( | ) |
Definition at line 1012 of file bbsavestate.cpp.
void* bbss_buffer_counts | ( | int * | len, |
int ** | gids, | ||
int ** | sizes, | ||
int * | global_size | ||
) |
BBSaveState API See save_test_bin and restore_test_bin for an example of the use of this following interface.
Note in particular the use in restore_test_bin of a prior clear_event_queue() in order to allow bbss_buffer_counts to pass an assert during the restore process. First call to return the information needed to make the other calls. Returns a pointer used by the other methods. Caller is reponsible for freeing (using free() and not delete []) the returned gids and sizes arrays when finished. The sizes array and global_size are needed for the caller to construct proper buffer sizes to pass to bbss_save_global and bbss_save for filling in. The size of these arrays is returned in *len. They are not needed for restoring (since the caller is passing already filled in buffers that are read by bbss_restore_global and bbss_restore. The gids returned are base gids. It is the callers responsibility to somehow concatenate buffers with the same gid (from different hosts) either after save or before restore and preserve the piece count of the number of concatenated buffers for each base gid. Global_size will only be non_zero for host 0.
Definition at line 773 of file bbsavestate.cpp.
|
static |
Definition at line 1189 of file bbsavestate.cpp.
|
static |
Definition at line 2816 of file bbsavestate.cpp.
|
static |
Definition at line 823 of file bbsavestate.cpp.
void bbss_restore | ( | void * | bbss, |
int | gid, | ||
int | npiece, | ||
char * | buffer, | ||
int | sz | ||
) |
Call this for each item of the gids from bbss_buffer_counts, the number of buffers that were concatenated for the gid, and the concatenated buffer (the concatenated buffer does NOT contain npiece as the first value in the char* buffer pointer).
sz is the size of the buffer (error checking only).
Definition at line 807 of file bbsavestate.cpp.
|
static |
Definition at line 606 of file bbsavestate.cpp.
void bbss_restore_done | ( | void * | bbss | ) |
At the end of the restore process, call this to do some extra setting up and cleanup.
When this call returns, bbss will be invalid.
Definition at line 856 of file bbsavestate.cpp.
void bbss_restore_global | ( | void * | bbss, |
char * | buffer, | ||
int | sz | ||
) |
Call on all hosts with the buffer contents returned from the call to bbss_save_global.
This must be called prior to any calls to bbss_restore sz is the size of the buffer (error checking only). This also does some other important restore initializations.
Definition at line 791 of file bbsavestate.cpp.
void bbss_save | ( | void * | bbss, |
int | gid, | ||
char * | buffer, | ||
int | sz | ||
) |
Call this for each item of the gids from bbss_buffer_counts along with a buffer of size from the corresponding sizes array.
The buffer will be filled in with savestate information. The gid may be the same on different hosts, in which case it is the callers responsibility to concatentate buffers at some point to allow calling of bbss_restore. sz is the size of the buffer (error checking only).
Definition at line 799 of file bbsavestate.cpp.
void bbss_save_done | ( | void * | bbss | ) |
At the end of the save process, call this to cleanup.
When this call returns, bbss will be invalid.
Definition at line 818 of file bbsavestate.cpp.
void bbss_save_global | ( | void * | bbss, |
char * | buffer, | ||
int | sz | ||
) |
Call only on host 0 with a buffer of size equal to the global_size returned from the bbss_buffer_counts call on host 0 sz is the size of the buffer (for error checking only, buffer+sz is out of bounds)
Definition at line 785 of file bbsavestate.cpp.
|
static |
Definition at line 1175 of file bbsavestate.cpp.
|
static |
Definition at line 1634 of file bbsavestate.cpp.
|
static |
Definition at line 586 of file bbsavestate.cpp.
|
static |
Definition at line 2550 of file bbsavestate.cpp.
|
static |
Definition at line 1426 of file bbsavestate.cpp.
|
static |
Definition at line 591 of file bbsavestate.cpp.
|
static |
Definition at line 763 of file bbsavestate.cpp.
Definition at line 270 of file netcvode.cpp.
Object * nrn_gid2obj | ( | int | gid | ) |
Definition at line 1564 of file netpar.cpp.
PreSyn * nrn_gid2presyn | ( | int | gid | ) |
Definition at line 1568 of file netpar.cpp.
int nrn_gid_exists | ( | int | gid | ) |
Definition at line 1039 of file netpar.cpp.
void nrn_gidout_iter | ( | PFIO | callback | ) |
Definition at line 1574 of file netpar.cpp.
void nrn_netcon_event | ( | NetCon * | nc, |
double | td | ||
) |
Definition at line 147 of file netcvode.cpp.
void nrn_play_init | ( | ) |
Definition at line 76 of file cvodestb.cpp.
void nrn_shape_update | ( | ) |
Definition at line 915 of file treeset.cpp.
|
static |
Definition at line 228 of file bbsavestate.cpp.
|
static |
Definition at line 262 of file bbsavestate.cpp.
|
static |
Definition at line 239 of file bbsavestate.cpp.
|
static |
Definition at line 252 of file bbsavestate.cpp.
|
static |
Definition at line 257 of file bbsavestate.cpp.
|
static |
Definition at line 249 of file bbsavestate.cpp.
|
static |
Definition at line 229 of file bbsavestate.cpp.
|
static |
Definition at line 749 of file bbsavestate.cpp.
|
static |
Definition at line 1761 of file bbsavestate.cpp.
|
static |
Definition at line 1722 of file bbsavestate.cpp.
|
static |
Definition at line 1726 of file bbsavestate.cpp.
|
static |
Definition at line 625 of file bbsavestate.cpp.
|
static |
Definition at line 664 of file bbsavestate.cpp.
|
static |
Definition at line 898 of file bbsavestate.cpp.
|
static |
Definition at line 930 of file bbsavestate.cpp.
|
static |
Definition at line 596 of file bbsavestate.cpp.
|
static |
Definition at line 659 of file bbsavestate.cpp.
|
static |
Definition at line 640 of file bbsavestate.cpp.
|
static |
Definition at line 671 of file bbsavestate.cpp.
|
static |
Definition at line 703 of file bbsavestate.cpp.
|
static |
Definition at line 2392 of file bbsavestate.cpp.
|
static |
Definition at line 2493 of file bbsavestate.cpp.
|
static |
Definition at line 1024 of file bbsavestate.cpp.
|
static |
Definition at line 1202 of file bbsavestate.cpp.
|
static |
Definition at line 990 of file bbsavestate.cpp.
Definition at line 1138 of file bbsavestate.cpp.
|
static |
Definition at line 306 of file bbsavestate.cpp.
|
static |
Definition at line 285 of file bbsavestate.cpp.
|
static |
Definition at line 299 of file bbsavestate.cpp.
|
static |
Definition at line 298 of file bbsavestate.cpp.
|
static |
Definition at line 2324 of file bbsavestate.cpp.
|
static |
Definition at line 2323 of file bbsavestate.cpp.
|
extern |
Definition at line 28 of file symbol.cpp.
|
static |
Definition at line 995 of file bbsavestate.cpp.
|
static |
Definition at line 1097 of file bbsavestate.cpp.
|
static |
Definition at line 1023 of file bbsavestate.cpp.
|
extern |
Definition at line 26 of file cvodestb.cpp.
Definition at line 44 of file tqueue.cpp.
|
extern |
Definition at line 225 of file netcvode.cpp.
|
extern |
|
static |
Definition at line 1093 of file bbsavestate.cpp.
|
static |
Definition at line 747 of file bbsavestate.cpp.
|
static |
Definition at line 1424 of file bbsavestate.cpp.
|
static |
Definition at line 1719 of file bbsavestate.cpp.
|
static |
Definition at line 1172 of file bbsavestate.cpp.
|
static |
Definition at line 1135 of file bbsavestate.cpp.
|
static |
Definition at line 1142 of file bbsavestate.cpp.
|
static |
Definition at line 1144 of file bbsavestate.cpp.
|
static |
Definition at line 1022 of file bbsavestate.cpp.
|
extern |
Definition at line 57 of file cvodeobj.cpp.
|
static |
Definition at line 288 of file bbsavestate.cpp.
|
static |
Definition at line 289 of file bbsavestate.cpp.
|
static |
Definition at line 2326 of file bbsavestate.cpp.
|
static |
Definition at line 2325 of file bbsavestate.cpp.
|
static |
Definition at line 283 of file bbsavestate.cpp.
|
static |
Definition at line 282 of file bbsavestate.cpp.
|
static |
Definition at line 310 of file bbsavestate.cpp.