Home
last modified time | relevance | path

Searched refs:size (Results 1 – 25 of 42) sorted by relevance

12

/memcached-1.6.32/
Dbipbuffer.c34 return me->size; in bipbuf_size()
45 me->size = size; in bipbuf_init()
54 bipbuf_init(me, size); in bipbuf_new()
98 me->b_end += size; in bipbuf_push()
102 me->a_end += size; in bipbuf_push()
106 return size; in bipbuf_push()
118 me->b_end += size; in bipbuf_offer()
127 return size; in bipbuf_offer()
133 if (me->size < me->a_start + size) in bipbuf_peek()
157 if (me->size < me->a_start + size) in bipbuf_poll()
[all …]
Dmemcached_dtrace.d69 probe slabs__allocate(int size, int slabclass, int slabsize, void* ptr);
76 probe slabs__allocate__failed(int size, int slabclass);
96 probe slabs__free(int size, int slabclass, void* ptr);
130 probe item__link(const char *key, int keylen, int size);
138 probe item__unlink(const char *key, int keylen, int size);
146 probe item__remove(const char *key, int keylen, int size);
154 probe item__update(const char *key, int keylen, int size);
174 probe process__command__start(int connid, const void *request, int size);
182 probe process__command__end(int connid, const void *response, int size);
192 probe command__get(int connid, const char *key, int keylen, int size, int64_t casid);
[all …]
Dbipbuffer.h6 unsigned long int size; member
26 bipbuf_t *bipbuf_new(const unsigned int size);
34 void bipbuf_init(bipbuf_t* me, const unsigned int size);
41 unsigned char *bipbuf_request(bipbuf_t* me, const int size);
42 int bipbuf_push(bipbuf_t* me, const int size);
48 int bipbuf_offer(bipbuf_t *me, const unsigned char *data, const int size);
69 unsigned char *bipbuf_poll(bipbuf_t* me, const unsigned int size);
Dslabs.c93 if (size == 0 || size > settings.item_size_max) in slabs_clsid()
95 while (size > slabclass[res].size) in slabs_clsid()
201 return p->size; in slabs_fixup()
259 size += CHUNK_ALIGN_BYTES - (size % CHUNK_ALIGN_BYTES); in slabs_init()
261 slabclass[i].size = size; in slabs_init()
264 size *= factor; in slabs_init()
354 ptr += p->size; in split_slab_page_into_freelist()
419 assert(size <= p->size); in do_slabs_alloc()
442 MEMCACHED_SLABS_ALLOCATE(size, id, p->size, ret); in do_slabs_alloc()
625 size += CHUNK_ALIGN_BYTES - (size % CHUNK_ALIGN_BYTES); in memory_allocate()
[all …]
Dslabs.h21 unsigned int slabs_clsid(const size_t size);
26 void *slabs_alloc(const size_t size, unsigned int id, unsigned int flags);
29 void slabs_free(void *ptr, size_t size, unsigned int id);
Dstats_prefix.c130 size_t size = 0, written = 0; in stats_prefix_dump() local
141 size = strlen(format) + total_prefix_size + in stats_prefix_dump()
145 buf = malloc(size); in stats_prefix_dump()
155 written = snprintf(buf + pos, size-pos, format, in stats_prefix_dump()
161 assert(total_written < size); in stats_prefix_dump()
Dproxy_config.c13 size_t size; member
24 if (db->used + sz > db->size) { in _dump_helper()
26 db->size += MCP_LUAFILE_SIZE; in _dump_helper()
27 char *nb = realloc(db->buf, db->size); in _dump_helper()
42 *size = 0; in _load_helper()
45 *size = db->used; in _load_helper()
422 db->size = MCP_LUAFILE_SIZE; in proxy_init_startfiles()
423 db->buf = calloc(db->size, 1); in proxy_init_startfiles()
455 memset(db->buf, 0, db->size); in proxy_load_files()
518 size_t size = sizeof(mcp_pool_proxy_t); in _copy_pool() local
[all …]
Dlogger.c60 e->size = total + 1; // null byte in _logger_log_text()
111 e->size = sizeof(struct logentry_item_get) + nkey; in _logger_log_item_get()
165 e->size = sizeof(struct logentry_conn_event); in _logger_log_conn_event()
724 unsigned int size; in logger_thread_read() local
730 data = bipbuf_peek_all(l->buf, &size); in logger_thread_read()
739 while (pos < size && watcher_count > 0) { in logger_thread_read()
750 pos += sizeof(logentry) + e->size + e->pad; in logger_thread_read()
752 assert(pos <= size); in logger_thread_read()
755 data = bipbuf_poll(l->buf, size); in logger_thread_read()
1056 if (sizeof(logentry) + e->size % 8 != 0) { in logger_log()
[all …]
Dsizes.c5 static void display(const char *name, size_t size) { in display() argument
6 printf("%s\t%d\n", name, (int)size); in display()
Drestart.c371 int size = slabs_fixup((char *)mmap_base + checked, in restart_fixup() local
375 if (size == -1) { in restart_fixup()
406 size = slabs_size(ch->orig_clsid); in restart_fixup()
427 checked += size; in restart_fixup()
428 page_remain -= size; in restart_fixup()
429 if (size > page_remain) { in restart_fixup()
Dextstore.c50 unsigned int size; member
127 static _store_wbuf *wbuf_new(size_t size) { in wbuf_new() argument
131 b->buf = calloc(size, sizeof(char)); in wbuf_new()
137 b->free = size; in wbuf_new()
138 b->size = size; in wbuf_new()
511 p->allocated += wbuf->size; in _allocate_wbuf()
512 wbuf->free = wbuf->size; in _allocate_wbuf()
538 p->written += w->size; in _wbuf_cb()
567 memset(w->buf + (w->size - w->free), 0, w->free); in _submit_wbuf()
574 io->len = w->size; in _submit_wbuf()
[all …]
Ditems.c216 if (size > settings.slab_chunk_size_max) in do_item_alloc_chunk()
217 size = settings.slab_chunk_size_max; in do_item_alloc_chunk()
218 unsigned int id = slabs_clsid(size); in do_item_alloc_chunk()
231 id = slabs_clsid(size); in do_item_alloc_chunk()
248 nch->size = size - sizeof(item_chunk); in do_item_alloc_chunk()
346 chunk->size = 0; in do_item_alloc()
797 unsigned int size = 0; in item_stats() local
825 size += sizes[i]; in item_stats()
852 if (size == 0) in item_stats()
1346 unsigned int size; in lru_maintainer_bumps() local
[all …]
Dproxy_inspector.c403 int size = mcp_inspector_string_c_g(L, tidx); in mcp_inspector_flagstr_c() local
404 return size; in mcp_inspector_flagstr_c()
524 size_t size = 0; in mcp_inspector_new() local
539 size += e->c(L, x); in mcp_inspector_new()
556 ins->arena = malloc(size); in mcp_inspector_new()
588 if (size != ins->aused) { in mcp_inspector_new()
Dslab_automove.c61 static void window_sum(struct window_data *wd, struct window_data *w, uint32_t size) { in window_sum() argument
63 for (x = 0; x < size; x++) { in window_sum()
Dmemcached.c426 size_t size = c->rsize * 2; in rbuf_switch_to_malloc() local
427 char *tmp = malloc(size); in rbuf_switch_to_malloc()
435 c->rsize = size; in rbuf_switch_to_malloc()
1362 size_t nsize = c->stats.size; in grow_stats_buf()
1378 if (nsize != c->stats.size) { in grow_stats_buf()
1382 c->stats.size = nsize; in grow_stats_buf()
4399 uint32_t size = 0; local
4409 if (!safe_strtoul(p, &size) || size < settings.chunk_size
4414 if (last_size >= size) {
4423 slab_sizes[i++] = size;
[all …]
Dslab_automove_extstore.c75 uint32_t size) { in window_sum() argument
76 for (int x = 0; x < size; x++) { in window_sum()
Dproxy_ring_hash.c289 size_t size = sizeof(ketama_t) + sizeof(cpoint) * (total * bucket_size); in ketama_new() local
290 ketama_t *kt = lua_newuserdatauv(L, size, 0); in ketama_new()
/memcached-1.6.32/t/
Dmultiversioning.t16 my $size = 256 * 1024; # 256 kB
17 my $bigval = "0123456789abcdef" x ($size / 16);
21 print $sock "set big 0 0 $size\r\n$bigval\r\n";
28 my $to_read = $size / 2;
37 is($read, $size / 2, "read half the answer back");
46 print $sock2 "set big 0 0 $size\r\n$bigval2\r\n";
Derror-extstore.t54 my $size = 3000 * 1024;
55 my $data = "x" x $size;
56 print $sock "set foo$_ 0 0 $size\r\n$data\r\n";
74 my $size = 3000 * 1024;
75 my $data = "x" x $size;
D64bit.t35 my $size = 400 * 1024;
36 my $data = "a" x $size;
37 print $sock "set big$_ 0 0 $size\r\n$data\r\n";
Dchunked-items.t31 my $size = 400 * 1024;
32 my $data = "x" x $size;
33 print $sock "set foo$_ 0 0 $size\r\n$data\r\n";
35 is($res, "STORED\r\n", "stored some big items: $size");
Dchunked-extstore.t64 my $size = 400 * 1024;
65 my $data = "x" x $size;
66 print $sock "set foo$_ 0 0 $size\r\n$data\r\n";
Dmetaget.t478 is($res->{size}, 0, "got zero size: autovivified response");
539 ok($res->{size} == 4, "Size returned correctly");
654 ok($res->{size} == 3, "Size returned correctly");
686 is($res->{size}, 1, "size updated");
928 $r{size} = $1;
/memcached-1.6.32/devtools/
Dslab_loadgen37 size = int(test[1]) variable
40 value = 'x'*size
43 s.write('set {}{} 0 0 {} noreply\r\n{}\r\n'.format(prefix,global_counter,size,value))
/memcached-1.6.32/scripts/
Dmemcached-tool266 my $size = $it->{chunk_size} < 1024 ?
271 $n, $size, $it->{age}, $it->{total_pages},

12