Searched refs:alloc_size (Results 1 - 25 of 35) sorted by relevance

12

/freebsd-11-stable/contrib/gcclibs/libiberty/
H A Dxmemdup.c7 @deftypefn Replacement void* xmemdup (void *@var{input}, size_t @var{copy_size}, size_t @var{alloc_size})
9 Duplicates a region of memory without fail. First, @var{alloc_size} bytes
34 xmemdup (const PTR input, size_t copy_size, size_t alloc_size) argument
36 PTR output = xcalloc (1, alloc_size);
/freebsd-11-stable/contrib/binutils/libiberty/
H A Dxmemdup.c7 @deftypefn Replacement void* xmemdup (void *@var{input}, size_t @var{copy_size}, size_t @var{alloc_size})
9 Duplicates a region of memory without fail. First, @var{alloc_size} bytes
34 xmemdup (const PTR input, size_t copy_size, size_t alloc_size) argument
36 PTR output = xcalloc (1, alloc_size);
/freebsd-11-stable/contrib/jemalloc/src/
H A Dchunk_mmap.c10 size_t alloc_size; local
12 alloc_size = size + alignment - PAGE;
14 if (alloc_size < size)
19 pages = pages_map(NULL, alloc_size, commit);
24 ret = pages_trim(pages, alloc_size, leadsize, size, commit);
H A Dpages.c90 pages_trim(void *addr, size_t alloc_size, size_t leadsize, size_t size, argument
95 assert(alloc_size >= leadsize + size);
100 pages_unmap(addr, alloc_size);
110 size_t trailsize = alloc_size - leadsize - size;
H A Dchunk.c209 size_t alloc_size, leadsize, trailsize; local
220 alloc_size = CHUNK_CEILING(s2u(size + alignment - chunksize));
222 if (alloc_size < size)
228 extent_node_init(&key, arena, new_addr, alloc_size, false,
233 alloc_size);
/freebsd-11-stable/contrib/jemalloc/include/jemalloc/internal/
H A Dpages.h14 void *pages_trim(void *addr, size_t alloc_size, size_t leadsize,
/freebsd-11-stable/lib/libc/tests/string/
H A Dstpncpy_test.c43 size_t alloc_size = roundup2(len, PAGE_SIZE) + PAGE_SIZE; local
45 buf = mmap(NULL, alloc_size, PROT_READ | PROT_WRITE, MAP_ANON, -1, 0);
48 assert(munmap(buf + alloc_size - PAGE_SIZE, PAGE_SIZE) == 0);
49 return (buf + alloc_size - PAGE_SIZE - len);
H A Dwcsnlen_test.c44 size_t alloc_size = roundup2(len, PAGE_SIZE) + PAGE_SIZE; local
46 buf = mmap(NULL, alloc_size, PROT_READ | PROT_WRITE, MAP_ANON, -1, 0);
49 ATF_CHECK(munmap(buf + alloc_size - PAGE_SIZE, PAGE_SIZE) == 0);
50 return (buf + alloc_size - PAGE_SIZE - len);
/freebsd-11-stable/sys/dev/usb/
H A Dusb_mbuf.c69 usb_size_t alloc_size; local
76 alloc_size = (block_size + sizeof(struct usb_mbuf)) * nblocks;
78 free_ptr = malloc(alloc_size, type, M_WAITOK | M_ZERO);
/freebsd-11-stable/sys/dev/ixl/
H A Dixl_pf_qmgr.c61 u16 alloc_size; local
67 alloc_size = (u16)next_power_of_two(num);
71 if (avail < alloc_size)
74 block_start = ixl_pf_qmgr_find_free_contiguous_block(qmgr, alloc_size);
79 for (i = block_start; i < block_start + alloc_size; i++)
86 qtag->num_allocated = alloc_size;
100 u16 alloc_size; local
106 alloc_size = (u16)next_power_of_two(num);
109 if (avail < alloc_size)
116 qtag->num_allocated = alloc_size;
[all...]
/freebsd-11-stable/sys/compat/linuxkpi/common/include/linux/
H A Dscatterlist.h208 unsigned int alloc_size = table->orig_nents; local
211 if (alloc_size > max_ents) {
213 alloc_size = max_ents;
214 sg_size = alloc_size - 1;
216 sg_size = alloc_size;
224 free_fn(sgl, alloc_size);
253 unsigned int alloc_size = left; local
255 if (alloc_size > max_ents) {
256 alloc_size = max_ents;
257 sg_size = alloc_size
[all...]
/freebsd-11-stable/contrib/apr/include/
H A Dapr_strings.h111 __attribute__((alloc_size(3)))
137 __attribute__((alloc_size(3)))
H A Dapr_pools.h432 __attribute__((alloc_size(2)))
447 __attribute__((alloc_size(2)))
/freebsd-11-stable/sys/dev/smartpqi/
H A Dsmartpqi_queue.c149 uint32_t alloc_size = 0; local
160 alloc_size = ib_array_size + ob_array_size +
164 softs->admin_queue_dma_mem.size = alloc_size;
674 uint32_t alloc_size = 0; local
700 alloc_size = num_elem * PQISRC_EVENT_Q_ELEM_SIZE;
701 event_q_pi_dma_start_offset = alloc_size;
702 event_q_pi_virt_start_offset = alloc_size;
703 alloc_size += sizeof(uint32_t); /*For IBQ CI*/
707 softs->event_q_dma_mem.size = alloc_size;
756 uint32_t alloc_size local
878 uint32_t alloc_size = 0; local
[all...]
H A Dsmartpqi_event.c323 uint32_t alloc_size = sizeof(pqi_event_config_t) ; local
330 buf_report_event.size = alloc_size;
383 uint32_t alloc_size = sizeof(pqi_event_config_t); local
390 buf_set_event.size = alloc_size;
H A Dsmartpqi_init.c160 uint64_t alloc_size = 0; local
174 alloc_size = num_req * sizeof(rcb_t);
177 rcb = os_mem_alloc(softs, alloc_size);
/freebsd-11-stable/sys/contrib/octeon-sdk/
H A Docteon-pci-console.c455 int alloc_size = num_consoles * (buffer_size * 2 + sizeof(octeon_pci_console_t) + sizeof(uint64_t)) + sizeof(octeon_pci_console_desc_t); local
460 int64_t console_block_addr = cvmx_bootmem_phy_named_block_alloc(alloc_size, OCTEON_DDR0_SIZE - alloc_size - 128, OCTEON_DDR0_SIZE, 128, OCTEON_PCI_CONSOLE_BLOCK_NAME, CVMX_BOOTMEM_FLAG_END_ALLOC);
462 console_block_addr = cvmx_bootmem_phy_named_block_alloc(alloc_size, OCTEON_DDR2_BASE + 1, OCTEON_DDR2_BASE + alloc_size + 128, 128, OCTEON_PCI_CONSOLE_BLOCK_NAME, CVMX_BOOTMEM_FLAG_END_ALLOC);
464 console_block_addr = cvmx_bootmem_phy_named_block_alloc(alloc_size, 0, 0x7fffffff, 128, OCTEON_PCI_CONSOLE_BLOCK_NAME, CVMX_BOOTMEM_FLAG_END_ALLOC);
470 memset(cons_desc_ptr, 0, alloc_size); /* Clear entire alloc'ed memory */
/freebsd-11-stable/sys/dev/drm2/ttm/
H A Dttm_page_alloc.c85 unsigned alloc_size; member in struct:ttm_pool_opts
248 m->options.alloc_size = val;
264 val = m->options.alloc_size;
622 unsigned alloc_size = _manager->options.alloc_size; local
632 ttm_flags, cstate, alloc_size);
638 pool->npages += alloc_size;
826 _manager->options.alloc_size = NUM_PAGES_TO_ALLOC;
H A Dttm_page_alloc_dma.c144 unsigned alloc_size; member in struct:ttm_pool_opts
237 m->options.alloc_size = val;
255 val = m->options.alloc_size;
1073 _manager->options.alloc_size = NUM_PAGES_TO_ALLOC;
/freebsd-11-stable/contrib/ofed/opensm/complib/
H A Dcl_vector.c337 size_t alloc_size; local
376 alloc_size = new_elements * p_vector->element_size;
378 p_buf = (cl_list_item_t *) malloc(alloc_size + sizeof(cl_list_item_t));
382 memset(p_buf, 0, alloc_size + sizeof(cl_list_item_t));
/freebsd-11-stable/contrib/gcc/
H A Dggc-zone.c2147 size_t alloc_size; member in struct:ggc_pch_data
2203 size_t alloc_size, total_size; local
2214 alloc_size = CEIL (d->d.total, BYTES_PER_ALLOC_BIT * 8);
2215 alloc_size = ROUND_UP (alloc_size, MAX_ALIGNMENT);
2216 d->alloc_size = alloc_size;
2218 return d->d.total + alloc_size;
2237 d->alloc_bits = xcalloc (1, d->alloc_size);
2301 if (fwrite (d->alloc_bits, d->alloc_size,
2319 size_t alloc_size; local
[all...]
H A Dggc-page.c317 size_t alloc_size;
811 size_t alloc_size, head_slop, tail_slop;
815 alloc_size = GGC_QUIRE_SIZE * G.pagesize;
817 alloc_size = entry_size + G.pagesize - 1;
818 allocation = xmalloc (alloc_size);
823 tail_slop = ((size_t) allocation + alloc_size) & (G.pagesize - 1);
825 tail_slop = alloc_size - entry_size - head_slop;
826 enda = allocation + alloc_size - tail_slop;
850 group->alloc_size = alloc_size;
315 size_t alloc_size; member in struct:page_group
808 size_t alloc_size, head_slop, tail_slop; local
[all...]
/freebsd-11-stable/sys/geom/
H A Dgeom_dev.c587 size_t alloc_size; local
592 alloc_size = 0;
599 alloc_size = rep->entries_allocated *
601 if (alloc_size != 0)
602 new_entries = g_malloc(alloc_size,
609 alloc_size != 0 && error == 0)
610 error = copyout(new_entries, old_entries, alloc_size);
/freebsd-11-stable/contrib/jemalloc/include/jemalloc/
H A Djemalloc.h10 /* Defined if alloc_size attribute is supported. */
153 # define JEMALLOC_ALLOC_SIZE(s) JEMALLOC_ATTR(alloc_size(s))
154 # define JEMALLOC_ALLOC_SIZE2(s1, s2) JEMALLOC_ATTR(alloc_size(s1, s2))
/freebsd-11-stable/contrib/llvm-project/lldb/source/Expression/
H A DIRMemoryMap.cpp90 size_t alloc_size = back->second.m_size; local
91 ret = llvm::alignTo(addr + alloc_size, 4096);
157 size_t alloc_size = back->second.m_size; local
158 ret = llvm::alignTo(addr + alloc_size, 4096);

Completed in 341 milliseconds

12