68 void grow_(
long ninc);
92 items_ =
new T*[count_];
93 for (
long i = 0;
i < count_; ++
i) {
94 items_[
i] = pool_ +
i * d2_;
105 template <
typename T>
111 template <
typename T>
115 chainlast_->chain_ =
p;
117 long newcnt = count_ + ninc;
118 T** itms =
new T*[newcnt];
121 for (
i = 0;
i < get_; ++
i) {
124 for (
i = get_,
j = 0;
j < ninc; ++
i, ++
j) {
125 itms[
i] =
p->items_[
j];
127 for (
i = put_,
j = get_;
j < count_; ++
i, ++
j) {
137 template <
typename T>
148 template <
typename T>
150 if (nget_ >= count_) {
153 T* item = items_[get_];
154 get_ = (get_ + 1) % count_;
157 if (nget_ > maxget_) {
163 template <
typename T>
167 put_ = (put_ + 1) % count_;
171 template <
typename T>
178 for (pp =
this; pp; pp = pp->
chain_) {
180 items_[put_++] = pp->
pool_ +
i * d2_;
ArrayPool(long count, long d2)
void * nrn_cacheline_calloc(void **memptr, std::size_t nmemb, std::size_t size)
HOC interpreter function declarations (included by hocdec.h)