Lines Matching defs:_cnt

56   uint _cnt, _max;              // Size of bucket
83 _cnt = 0; // Dictionary is empty
104 _cnt = 0; // Dictionary is empty
113 tty->print("~Dict %d/%d: ",_cnt,_size);
115 tty->print("%d ",_bin[i]._cnt);
125 _cnt = 0; // Empty contents
127 _bin[i]._cnt = 0; // Empty buckets, but leave allocated
150 while( j > b->_cnt ) j >>= 1; // above old bucket _cnt
157 for( j=0; j<b->_cnt; j++ ) { // Rehash all keys in this bucket
162 nb->_cnt = nbcnt = nbcnt+1;
163 b->_cnt--; // Remove key/value from lo bucket
164 b->_keyvals[j+j ] = b->_keyvals[b->_cnt+b->_cnt ];
165 b->_keyvals[j+j+1] = b->_keyvals[b->_cnt+b->_cnt+1];
176 Dict::Dict( const Dict &d ) : _size(d._size), _cnt(d._cnt), _hash(d._hash),_cmp(d._cmp), _arena(d._arena) {
182 memcpy( _bin[i]._keyvals, d._bin[i]._keyvals,_bin[i]._cnt*2*sizeof(void*));
197 _bin[i]._cnt = 0; // But leave bucket allocations alone
198 _cnt = d._cnt;
203 for( uint j=0; j<b->_cnt; j++ )
219 for( uint j=0; j<b->_cnt; j++ ) {
231 if( ++_cnt > _size ) { // Hash table is full
236 if( b->_cnt == b->_max ) { // Must grow bucket?
245 b->_keyvals[b->_cnt+b->_cnt ] = key;
246 b->_keyvals[b->_cnt+b->_cnt+1] = val;
247 b->_cnt++;
256 for( uint j=0; j<b->_cnt; j++ )
259 b->_cnt--; // Remove key/value from lo bucket
260 b->_keyvals[j+j ] = b->_keyvals[b->_cnt+b->_cnt ];
261 b->_keyvals[j+j+1] = b->_keyvals[b->_cnt+b->_cnt+1];
262 _cnt--; // One less thing in table
274 for( uint j=0; j<b->_cnt; j++ )
285 if( _cnt != d2._cnt ) return 0;
290 if( b->_cnt != d2._bin[i]._cnt ) return 0;
291 if( memcmp(b->_keyvals, d2._bin[i]._keyvals, b->_cnt*2*sizeof(void*) ) )
301 tty->print("Dict@0x%lx[%d] = {", this, _cnt);
381 _j = _d->_bin[_i]._cnt;