/external/libmicrohttpd/src/microhttpd/ |
D | memorypool.c | 89 struct MemoryPool *pool; in MHD_pool_create() local 91 pool = malloc (sizeof (struct MemoryPool)); in MHD_pool_create() 92 if (NULL == pool) in MHD_pool_create() 96 pool->memory = MAP_FAILED; in MHD_pool_create() 99 pool->memory = mmap (NULL, max, PROT_READ | PROT_WRITE, in MHD_pool_create() 102 pool->memory = VirtualAlloc(NULL, max, MEM_COMMIT | MEM_RESERVE, in MHD_pool_create() 106 pool->memory = MAP_FAILED; in MHD_pool_create() 108 if ((pool->memory == MAP_FAILED) || (pool->memory == NULL)) in MHD_pool_create() 110 pool->memory = malloc (max); in MHD_pool_create() 111 if (pool->memory == NULL) in MHD_pool_create() [all …]
|
/external/mesa3d/src/gallium/auxiliary/util/ |
D | u_slab.c | 46 util_slab_get_block(struct util_slab_mempool *pool, in util_slab_get_block() argument 51 (pool->block_size * index)); in util_slab_get_block() 54 static void util_slab_add_new_page(struct util_slab_mempool *pool) in util_slab_add_new_page() argument 60 page = MALLOC(pool->page_size); in util_slab_add_new_page() 61 insert_at_tail(&pool->list, page); in util_slab_add_new_page() 64 for (i = 0; i < pool->num_blocks-1; i++) { in util_slab_add_new_page() 65 block = util_slab_get_block(pool, page, i); in util_slab_add_new_page() 66 block->next_free = util_slab_get_block(pool, page, i+1); in util_slab_add_new_page() 70 block = util_slab_get_block(pool, page, pool->num_blocks-1); in util_slab_add_new_page() 71 block->next_free = pool->first_free; in util_slab_add_new_page() [all …]
|
D | u_slab.h | 57 void *(*alloc)(struct util_slab_mempool *pool); 58 void (*free)(struct util_slab_mempool *pool, void *ptr); 74 void util_slab_create(struct util_slab_mempool *pool, 79 void util_slab_destroy(struct util_slab_mempool *pool); 81 void util_slab_set_thread_safety(struct util_slab_mempool *pool, 84 #define util_slab_alloc(pool) (pool)->alloc(pool) argument 85 #define util_slab_free(pool, ptr) (pool)->free(pool, ptr) argument
|
/external/mesa3d/src/gallium/auxiliary/pipebuffer/ |
D | pb_bufmgr_pool.c | 109 struct pool_pb_manager *pool = pool_buf->mgr; in pool_buffer_destroy() local 113 pipe_mutex_lock(pool->mutex); in pool_buffer_destroy() 114 LIST_ADD(&pool_buf->head, &pool->free); in pool_buffer_destroy() 115 pool->numFree++; in pool_buffer_destroy() 116 pipe_mutex_unlock(pool->mutex); in pool_buffer_destroy() 124 struct pool_pb_manager *pool = pool_buf->mgr; in pool_buffer_map() local 129 pipe_mutex_lock(pool->mutex); in pool_buffer_map() 130 map = (unsigned char *) pool->map + pool_buf->start; in pool_buffer_map() 131 pipe_mutex_unlock(pool->mutex); in pool_buffer_map() 149 struct pool_pb_manager *pool = pool_buf->mgr; in pool_buffer_validate() local [all …]
|
/external/deqp/framework/delibs/depool/ |
D | deMemPool.c | 171 deMemPool* pool; in createPoolInternal() local 189 pool = (deMemPool*)(initialPage + 1); in createPoolInternal() 192 memset(pool, 0, sizeof(deMemPool)); in createPoolInternal() 193 pool->currentPage = initialPage; in createPoolInternal() 196 pool->parent = parent; in createPoolInternal() 200 if (parent->firstChild) parent->firstChild->prevPool = pool; in createPoolInternal() 201 pool->nextPool = parent->firstChild; in createPoolInternal() 202 parent->firstChild = pool; in createPoolInternal() 206 pool->util = parent ? parent->util : DE_NULL; in createPoolInternal() 209 pool->allowFailing = parent ? parent->allowFailing : DE_FALSE; in createPoolInternal() [all …]
|
/external/fio/ |
D | smalloc.c | 37 struct pool { struct 54 static struct pool mp[MAX_POOLS]; argument 59 static inline void pool_lock(struct pool *pool) in pool_lock() argument 61 fio_mutex_down(pool->lock); in pool_lock() 64 static inline void pool_unlock(struct pool *pool) in pool_unlock() argument 66 fio_mutex_up(pool->lock); in pool_unlock() 89 static inline int ptr_valid(struct pool *pool, void *ptr) in ptr_valid() argument 91 unsigned int pool_size = pool->nr_blocks * SMALLOC_BPL; in ptr_valid() 93 return (ptr >= pool->map) && (ptr < pool->map + pool_size); in ptr_valid() 101 static int blocks_iter(struct pool *pool, unsigned int pool_idx, in blocks_iter() argument [all …]
|
/external/mesa3d/src/gallium/drivers/r600/ |
D | compute_memory_pool.c | 79 struct compute_memory_pool* pool = (struct compute_memory_pool*) in compute_memory_pool_new() local 84 pool->screen = rscreen; in compute_memory_pool_new() 85 return pool; in compute_memory_pool_new() 88 static void compute_memory_pool_init(struct compute_memory_pool * pool, in compute_memory_pool_init() argument 99 pool->next_id = 1; in compute_memory_pool_init() 100 pool->size_in_dw = initial_size_in_dw; in compute_memory_pool_init() 101 pool->bo = (struct r600_resource*)create_pool_texture(pool->screen, in compute_memory_pool_init() 102 pool->size_in_dw); in compute_memory_pool_init() 108 void compute_memory_pool_delete(struct compute_memory_pool* pool) in compute_memory_pool_delete() argument 111 free(pool->shadow); in compute_memory_pool_delete() [all …]
|
D | compute_memory_pool.h | 41 struct compute_memory_pool* pool; member 61 void compute_memory_pool_delete(struct compute_memory_pool* pool); ///Frees all stuff in the pool a… 63 int64_t compute_memory_prealloc_chunk(struct compute_memory_pool* pool, int64_t size_in_dw); ///sea… 65 struct compute_memory_item* compute_memory_postalloc_chunk(struct compute_memory_pool* pool, int64_… 70 void compute_memory_grow_pool(struct compute_memory_pool* pool, struct pipe_context * pipe, 76 void compute_memory_shadow(struct compute_memory_pool* pool, 82 void compute_memory_finalize_pending(struct compute_memory_pool* pool, 84 void compute_memory_defrag(struct compute_memory_pool* pool); ///Defragment the memory pool, always… 85 void compute_memory_free(struct compute_memory_pool* pool, int64_t id); 86 struct compute_memory_item* compute_memory_alloc(struct compute_memory_pool* pool, int64_t size_in_… [all …]
|
/external/okhttp/okhttp-tests/src/test/java/com/squareup/okhttp/ |
D | ConnectionPoolTest.java | 48 ConnectionPool pool = new ConnectionPool(Integer.MAX_VALUE, 100L, TimeUnit.NANOSECONDS); in connectionsEvictedWhenIdleLongEnough() local 49 pool.setCleanupRunnableForTest(emptyRunnable); in connectionsEvictedWhenIdleLongEnough() 51 RealConnection c1 = newConnection(pool, routeA1, 50L); in connectionsEvictedWhenIdleLongEnough() 54 assertEquals(100L, pool.cleanup(50L)); in connectionsEvictedWhenIdleLongEnough() 55 assertEquals(1, pool.getConnectionCount()); in connectionsEvictedWhenIdleLongEnough() 59 assertEquals(90L, pool.cleanup(60L)); in connectionsEvictedWhenIdleLongEnough() 60 assertEquals(1, pool.getConnectionCount()); in connectionsEvictedWhenIdleLongEnough() 64 assertEquals(1L, pool.cleanup(149L)); in connectionsEvictedWhenIdleLongEnough() 65 assertEquals(1, pool.getConnectionCount()); in connectionsEvictedWhenIdleLongEnough() 69 assertEquals(0, pool.cleanup(150L)); in connectionsEvictedWhenIdleLongEnough() [all …]
|
/external/boringssl/src/crypto/pool/ |
D | pool.c | 41 CRYPTO_BUFFER_POOL *pool = OPENSSL_malloc(sizeof(CRYPTO_BUFFER_POOL)); in CRYPTO_BUFFER_POOL_new() local 42 if (pool == NULL) { in CRYPTO_BUFFER_POOL_new() 46 OPENSSL_memset(pool, 0, sizeof(CRYPTO_BUFFER_POOL)); in CRYPTO_BUFFER_POOL_new() 47 pool->bufs = lh_CRYPTO_BUFFER_new(CRYPTO_BUFFER_hash, CRYPTO_BUFFER_cmp); in CRYPTO_BUFFER_POOL_new() 48 if (pool->bufs == NULL) { in CRYPTO_BUFFER_POOL_new() 49 OPENSSL_free(pool); in CRYPTO_BUFFER_POOL_new() 53 CRYPTO_MUTEX_init(&pool->lock); in CRYPTO_BUFFER_POOL_new() 55 return pool; in CRYPTO_BUFFER_POOL_new() 58 void CRYPTO_BUFFER_POOL_free(CRYPTO_BUFFER_POOL *pool) { in CRYPTO_BUFFER_POOL_free() argument 59 if (pool == NULL) { in CRYPTO_BUFFER_POOL_free() [all …]
|
/external/libunwind/src/mi/ |
D | mempool.c | 86 free_object (struct mempool *pool, void *object) in free_object() argument 90 obj->next = pool->free_list; in free_object() 91 pool->free_list = obj; in free_object() 92 ++pool->num_free; in free_object() 96 add_memory (struct mempool *pool, char *mem, size_t size, size_t obj_size) in add_memory() argument 101 free_object (pool, obj); in add_memory() 105 expand (struct mempool *pool) in expand() argument 110 size = pool->chunk_size; in expand() 114 size = UNW_ALIGN(pool->obj_size, pg_size); in expand() 119 size = pool->obj_size; in expand() [all …]
|
/external/mesa3d/src/gallium/drivers/r300/compiler/ |
D | memory_pool.c | 38 void memory_pool_init(struct memory_pool * pool) in memory_pool_init() argument 40 memset(pool, 0, sizeof(struct memory_pool)); in memory_pool_init() 44 void memory_pool_destroy(struct memory_pool * pool) in memory_pool_destroy() argument 46 while(pool->blocks) { in memory_pool_destroy() 47 struct memory_block * block = pool->blocks; in memory_pool_destroy() 48 pool->blocks = block->next; in memory_pool_destroy() 53 static void refill_pool(struct memory_pool * pool) in refill_pool() argument 55 unsigned int blocksize = pool->total_allocated; in refill_pool() 62 newblock->next = pool->blocks; in refill_pool() 63 pool->blocks = newblock; in refill_pool() [all …]
|
/external/skia/tests/ |
D | GrMemoryPoolTest.cpp | 50 GrMemoryPool* pool = new GrMemoryPool(preallocSize, minAllocSize); in SetAllocator() local 51 gPool.reset(pool); in SetAllocator() 235 AutoPoolReleaser(GrMemoryPool& pool): fPool(pool) { in AutoPoolReleaser() argument 254 auto allocateMemory = [](GrMemoryPool& pool, AutoPoolReleaser& r) { in DEF_TEST() argument 255 size_t origPoolSize = pool.size(); in DEF_TEST() 256 while (pool.size() == origPoolSize) { in DEF_TEST() 257 r.add(pool.allocate(31)); in DEF_TEST() 263 GrMemoryPool pool(0, 0); in DEF_TEST() local 264 REPORTER_ASSERT(reporter, pool.preallocSize() == kSmallestMinAllocSize); in DEF_TEST() 270 GrMemoryPool pool(kSmallestMinAllocSize, kMinAllocSize); in DEF_TEST() local [all …]
|
D | DiscardableMemoryPoolTest.cpp | 12 sk_sp<SkDiscardableMemoryPool> pool( in DEF_TEST() local 14 pool->setRAMBudget(3); in DEF_TEST() 15 REPORTER_ASSERT(reporter, 0 == pool->getRAMUsed()); in DEF_TEST() 17 std::unique_ptr<SkDiscardableMemory> dm1(pool->create(100)); in DEF_TEST() 19 REPORTER_ASSERT(reporter, 100 == pool->getRAMUsed()); in DEF_TEST() 21 REPORTER_ASSERT(reporter, 0 == pool->getRAMUsed()); in DEF_TEST() 25 std::unique_ptr<SkDiscardableMemory> dm2(pool->create(200)); in DEF_TEST() 26 REPORTER_ASSERT(reporter, 200 == pool->getRAMUsed()); in DEF_TEST() 27 pool->setRAMBudget(400); in DEF_TEST() 29 REPORTER_ASSERT(reporter, 200 == pool->getRAMUsed()); in DEF_TEST() [all …]
|
/external/volley/src/test/java/com/android/volley/toolbox/ |
D | ByteArrayPoolTest.java | 28 ByteArrayPool pool = new ByteArrayPool(32); in reusesBuffer() local 30 byte[] buf1 = pool.getBuf(16); in reusesBuffer() 31 byte[] buf2 = pool.getBuf(16); in reusesBuffer() 33 pool.returnBuf(buf1); in reusesBuffer() 34 pool.returnBuf(buf2); in reusesBuffer() 36 byte[] buf3 = pool.getBuf(16); in reusesBuffer() 37 byte[] buf4 = pool.getBuf(16); in reusesBuffer() 44 ByteArrayPool pool = new ByteArrayPool(32); in obeysSizeLimit() local 46 byte[] buf1 = pool.getBuf(16); in obeysSizeLimit() 47 byte[] buf2 = pool.getBuf(16); in obeysSizeLimit() [all …]
|
D | PoolingByteArrayOutputStreamTest.java | 28 ByteArrayPool pool = new ByteArrayPool(32768); in pooledOneBuffer() local 29 writeOneBuffer(pool); in pooledOneBuffer() 30 writeOneBuffer(pool); in pooledOneBuffer() 31 writeOneBuffer(pool); in pooledOneBuffer() 35 ByteArrayPool pool = new ByteArrayPool(32768); in pooledIndividualWrites() local 36 writeBytesIndividually(pool); in pooledIndividualWrites() 37 writeBytesIndividually(pool); in pooledIndividualWrites() 38 writeBytesIndividually(pool); in pooledIndividualWrites() 42 ByteArrayPool pool = new ByteArrayPool(0); in unpooled() local 43 writeOneBuffer(pool); in unpooled() [all …]
|
/external/zopfli/src/zopfli/ |
D | katajainen.c | 67 static Node* GetFreeNode(Node* (*lists)[2], int maxbits, NodePool* pool) { in GetFreeNode() argument 69 if (pool->next >= &pool->nodes[pool->size]) { in GetFreeNode() 72 for (i = 0; i < pool->size; i++) { in GetFreeNode() 73 pool->nodes[i].inuse = 0; in GetFreeNode() 83 pool->next = &pool->nodes[0]; in GetFreeNode() 85 if (!pool->next->inuse) break; /* Found one. */ in GetFreeNode() 86 pool->next++; in GetFreeNode() 88 return pool->next++; in GetFreeNode() 106 Node* leaves, int numsymbols, NodePool* pool, int index, char final) { in BoundaryPM() argument 113 newchain = GetFreeNode(lists, maxbits, pool); in BoundaryPM() [all …]
|
/external/javassist/src/main/javassist/bytecode/ |
D | InstructionPrinter.java | 41 ConstPool pool = info.getConstPool(); in print() local 55 stream.println(pos + ": " + instructionString(iterator, pos, pool)); in print() 59 public static String instructionString(CodeIterator iter, int pos, ConstPool pool) { in instructionString() argument 72 return opstring + " " + ldc(pool, iter.byteAt(pos + 1)); in instructionString() 75 return opstring + " " + ldc(pool, iter.u16bitAt(pos + 1)); in instructionString() 119 return opstring + " " + fieldInfo(pool, iter.u16bitAt(pos + 1)); in instructionString() 123 return opstring + " " + methodInfo(pool, iter.u16bitAt(pos + 1)); in instructionString() 125 return opstring + " " + interfaceMethodInfo(pool, iter.u16bitAt(pos + 1)); in instructionString() 129 return opstring + " " + classInfo(pool, iter.u16bitAt(pos + 1)); in instructionString() 134 return opstring + " " + classInfo(pool, iter.u16bitAt(pos + 1)); in instructionString() [all …]
|
/external/protobuf/python/google/protobuf/internal/ |
D | descriptor_pool_test.py | 65 self.pool = descriptor_pool.DescriptorPool() 70 self.pool.Add(self.factory_test1_fd) 71 self.pool.Add(self.factory_test2_fd) 75 file_desc1 = self.pool.FindFileByName(name1) 82 file_desc2 = self.pool.FindFileByName(name2) 90 self.pool.FindFileByName('Does not exist') 93 file_desc1 = self.pool.FindFileContainingSymbol( 101 file_desc2 = self.pool.FindFileContainingSymbol( 111 self.pool.FindFileContainingSymbol('Does not exist') 114 msg1 = self.pool.FindMessageTypeByName( [all …]
|
/external/pdfium/core/fxcrt/ |
D | cfx_string_pool_template_unittest.cpp | 11 CFX_ByteStringPool pool; in TEST() local 23 CFX_ByteString interned_null1 = pool.Intern(null1); in TEST() 24 CFX_ByteString interned_null2 = pool.Intern(null2); in TEST() 25 CFX_ByteString interned_goats1 = pool.Intern(goats1); in TEST() 26 CFX_ByteString interned_goats2 = pool.Intern(goats2); in TEST() 40 pool.Clear(); in TEST() 41 CFX_ByteString reinterned_null2 = pool.Intern(null2); in TEST() 42 CFX_ByteString reinterned_null1 = pool.Intern(null2); in TEST() 43 CFX_ByteString reinterned_goats2 = pool.Intern(goats2); in TEST() 44 CFX_ByteString reinterned_goats1 = pool.Intern(goats2); in TEST() [all …]
|
/external/autotest/site_utils/ |
D | balance_pools.py | 173 def __init__(self, afe, board, pool, start_time, end_time): argument 175 self.pool = pool 180 self._labels = [_POOL_PREFIX + self.pool] 187 board=self.board, pool=self.pool)) 242 self.board, self.pool, 298 len(hosts), spare_pool.pool, target_pool.pool) 313 def _balance_board(arguments, afe, board, pool, start_time, end_time): argument 330 main_pool = _DUTPool(afe, board, pool, 355 _log_info(dry_run, 'Balancing %s %s pool:', board, main_pool.pool) 372 board, main_pool.pool, len(spare_pool.working_hosts)) [all …]
|
/external/libevent/ |
D | evrpc.c | 200 static void evrpc_pool_schedule(struct evrpc_pool *pool); 512 struct evrpc_pool *pool = mm_calloc(1, sizeof(struct evrpc_pool)); in evrpc_pool_new() local 513 if (pool == NULL) in evrpc_pool_new() 516 TAILQ_INIT(&pool->connections); in evrpc_pool_new() 517 TAILQ_INIT(&pool->requests); in evrpc_pool_new() 519 TAILQ_INIT(&pool->paused_requests); in evrpc_pool_new() 521 TAILQ_INIT(&pool->input_hooks); in evrpc_pool_new() 522 TAILQ_INIT(&pool->output_hooks); in evrpc_pool_new() 524 pool->base = base; in evrpc_pool_new() 525 pool->timeout = -1; in evrpc_pool_new() [all …]
|
/external/libxml2/ |
D | dict.c | 242 xmlDictStringsPtr pool; in xmlDictAddString() local 250 pool = dict->strings; in xmlDictAddString() 251 while (pool != NULL) { in xmlDictAddString() 252 if (pool->end - pool->free > namelen) in xmlDictAddString() 254 if (pool->size > size) size = pool->size; in xmlDictAddString() 255 limit += pool->size; in xmlDictAddString() 256 pool = pool->next; in xmlDictAddString() 261 if (pool == NULL) { in xmlDictAddString() 270 pool = (xmlDictStringsPtr) xmlMalloc(sizeof(xmlDictStrings) + size); in xmlDictAddString() 271 if (pool == NULL) in xmlDictAddString() [all …]
|
/external/llvm/test/CodeGen/XCore/ |
D | atomic.ll | 18 @pool = external global i64 24 ; CHECK: ldw r[[R0:[0-9]+]], dp[pool] 25 ; CHECK-NEXT: ldaw r[[R1:[0-9]+]], dp[pool] 28 %0 = load atomic i32, i32* bitcast (i64* @pool to i32*) acquire, align 4 32 %1 = load atomic i16, i16* bitcast (i64* @pool to i16*) acquire, align 2 36 %2 = load atomic i8, i8* bitcast (i64* @pool to i8*) acquire, align 1 38 ; CHECK-NEXT: ldw r4, dp[pool] 40 %3 = load atomic i32, i32* bitcast (i64* @pool to i32*) seq_cst, align 4 44 %4 = load atomic i16, i16* bitcast (i64* @pool to i16*) seq_cst, align 2 48 %5 = load atomic i8, i8* bitcast (i64* @pool to i8*) seq_cst, align 1 [all …]
|
/external/javassist/src/main/javassist/bytecode/annotation/ |
D | AnnotationsWriter.java | 61 private ConstPool pool; field in AnnotationsWriter 71 pool = cp; in AnnotationsWriter() 78 return pool; in getConstPool() 121 annotation(pool.addUtf8Info(type), numMemberValuePairs); in annotation() 150 memberValuePair(pool.addUtf8Info(memberName)); in memberValuePair() 174 constValueIndex('Z', pool.addIntegerInfo(value ? 1 : 0)); in constValueIndex() 184 constValueIndex('B', pool.addIntegerInfo(value)); in constValueIndex() 194 constValueIndex('C', pool.addIntegerInfo(value)); in constValueIndex() 204 constValueIndex('S', pool.addIntegerInfo(value)); in constValueIndex() 214 constValueIndex('I', pool.addIntegerInfo(value)); in constValueIndex() [all …]
|