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

12

/netbsd-6-1-5-RELEASE/external/gpl3/gcc/dist/gcc/testsuite/gcc.dg/
H A Dattr-alloc_size-2.c3 char *foo() __attribute__((alloc_size(1))); /* { dg-warning "outside range" } */
H A Dattr-alloc_size.c8 extern char *mallocminus1(int size) __attribute__((alloc_size(-1))); /* { dg-warning "parameter outside range" } */
9 extern char *malloc0(int size) __attribute__((alloc_size(0))); /* { dg-warning "parameter outside range" } */
10 extern char *malloc1(int size) __attribute__((alloc_size(1)));
11 extern char *malloc2(int empty, int size) __attribute__((alloc_size(2)));
12 extern char *calloc1(int size, int elements) __attribute__((alloc_size(1,2)));
13 extern char *calloc2(int size, int empty, int elements) __attribute__((alloc_size(1,3)));
14 extern char *balloc1(void *size) __attribute__((alloc_size(1)));
/netbsd-6-1-5-RELEASE/external/lgpl3/mpfr/dist/
H A Dinp_str.c33 size_t alloc_size, str_size; local
41 alloc_size = 100;
42 str = (unsigned char *) (*__gmp_allocate_func) (alloc_size);
58 if (str_size >= alloc_size)
60 size_t old_alloc_size = alloc_size;
61 alloc_size = alloc_size * 3 / 2;
63 (*__gmp_reallocate_func) (str, old_alloc_size, alloc_size);
75 then necessarily str_size >= alloc_size was checked, so
76 now str_size < alloc_size */
[all...]
/netbsd-6-1-5-RELEASE/external/lgpl3/gmp/dist/mpf/
H A Dinp_str.c30 size_t alloc_size, str_size; local
38 alloc_size = 100;
39 str = (char *) (*__gmp_allocate_func) (alloc_size);
53 if (str_size >= alloc_size)
55 size_t old_alloc_size = alloc_size;
56 alloc_size = alloc_size * 3 / 2;
57 str = (char *) (*__gmp_reallocate_func) (str, old_alloc_size, alloc_size);
67 if (str_size >= alloc_size)
69 size_t old_alloc_size = alloc_size;
[all...]
H A Dget_str.c123 size_t alloc_size = 0; local
157 alloc_size = n_digits + 2;
311 if (alloc_size != 0)
313 __GMP_REALLOCATE_FUNC_MAYBE_TYPE (dbuf, alloc_size, n_digits + 1, char);
/netbsd-6-1-5-RELEASE/external/lgpl3/gmp/dist/mpbsd/
H A Dmtox.c34 size_t str_size, alloc_size, i; local
42 MPN_SIZEINBASE_16 (alloc_size, xp, xsize);
43 alloc_size += 1 + (xsign < 0);
45 str = (unsigned char *) (*__gmp_allocate_func) (alloc_size);
52 ASSERT (str_size <= alloc_size - (xsign < 0));
59 ASSERT (strlen (str) + 1 == alloc_size);
H A Dmin.c34 size_t alloc_size, str_size; local
42 alloc_size = 100;
43 str = (char *) (*__gmp_allocate_func) (alloc_size);
67 if (str_size >= alloc_size)
69 size_t old_alloc_size = alloc_size;
70 alloc_size = alloc_size * 3 / 2;
71 str = (char *) (*__gmp_reallocate_func) (str, old_alloc_size, alloc_size);
87 (*__gmp_free_func) (str, alloc_size);
/netbsd-6-1-5-RELEASE/external/gpl3/binutils/dist/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);
/netbsd-6-1-5-RELEASE/external/gpl3/gcc/dist/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);
/netbsd-6-1-5-RELEASE/external/gpl3/gdb/dist/libiberty/
H A Dxmemdup.c8 size_t @var{copy_size}, size_t @var{alloc_size})
10 Duplicates a region of memory without fail. First, @var{alloc_size} bytes
35 xmemdup (const PTR input, size_t copy_size, size_t alloc_size) argument
37 PTR output = xcalloc (1, alloc_size);
/netbsd-6-1-5-RELEASE/gnu/dist/gcc4/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);
/netbsd-6-1-5-RELEASE/external/lgpl3/gmp/dist/mpz/
H A Dget_str.c38 size_t alloc_size = 0; local
65 MPN_SIZEINBASE (alloc_size, PTR(x), ABS(x_size), base);
66 alloc_size += 1 + (x_size<0);
67 res_str = (char *) (*__gmp_allocate_func) (alloc_size);
87 ASSERT (alloc_size == 0 || str_size <= alloc_size - (SIZ(x) < 0));
107 if (alloc_size != 0)
111 __GMP_REALLOCATE_FUNC_MAYBE_TYPE (return_str, alloc_size, actual_size,
H A Dinp_str.c61 size_t alloc_size, str_size; local
123 alloc_size = 100;
124 str = (char *) (*__gmp_allocate_func) (alloc_size);
133 if (str_size >= alloc_size)
135 size_t old_alloc_size = alloc_size;
136 alloc_size = alloc_size * 3 / 2;
137 str = (char *) (*__gmp_reallocate_func) (str, old_alloc_size, alloc_size);
162 (*__gmp_free_func) (str, alloc_size);
/netbsd-6-1-5-RELEASE/external/lgpl3/gmp/dist/tests/devel/
H A Dtst-addsub.c46 mp_size_t alloc_size, max_size, size, i, cumul_size; local
62 alloc_size = max_size + 32;
63 s1 = malloc (alloc_size * BYTES_PER_MP_LIMB);
64 s2 = malloc (alloc_size * BYTES_PER_MP_LIMB);
65 dx = malloc (alloc_size * BYTES_PER_MP_LIMB);
66 dy = malloc (alloc_size * BYTES_PER_MP_LIMB);
86 for (i = 0; i < alloc_size; i++)
92 if (cx != cy || mpn_cmp (dx, dy, alloc_size) != 0)
/netbsd-6-1-5-RELEASE/usr.sbin/acpitools/aml/
H A Daml_memman.c74 size_t alloc_size; local
81 alloc_size = MEMMAN_BLOCKNODE_SIZE(entries);
85 realblock = (char *)block + alloc_size;
87 tmp = MEMMAN_SYSMALLOC(alloc_size);
93 memman->allocated_mem += alloc_size;
105 alloc_size += roundup(bmp->size * entries, ROUNDUP_UNIT);
107 memblock->allocated_mem = alloc_size;
139 size_t alloc_size; local
157 alloc_size = roundup(bmp->size * MEMMAN_INCR_SIZE,
159 block = MEMMAN_SYSMALLOC(alloc_size);
[all...]
/netbsd-6-1-5-RELEASE/sys/kern/
H A Dsys_generic.c525 size_t size, alloc_size; local
537 alloc_size = 0;
562 alloc_size = size;
607 alloc_size = IOCPARM_LEN(DIOCGDINFO);
623 if (alloc_size > sizeof(stkbuf)) {
624 memp = kmem_alloc(alloc_size, KM_SLEEP);
636 * The data between size and alloc_size has
640 if (__predict_false(size < alloc_size)) {
642 alloc_size - size);
696 kmem_free(memp, alloc_size);
[all...]
/netbsd-6-1-5-RELEASE/external/bsd/fetch/dist/libfetch/
H A Dfetch.h68 size_t alloc_size; member in struct:url_list
H A Dcommon.c759 if (ue->length + 1 >= ue->alloc_size) {
760 tmp = realloc(ue->urls, (ue->alloc_size * 2 + 1) * sizeof(*tmp));
767 ue->alloc_size = ue->alloc_size * 2 + 1;
813 ue->length = ue->alloc_size = 0;
823 if (len > dst->alloc_size) {
832 dst->alloc_size = len;
859 ue->length = ue->alloc_size = 0;
/netbsd-6-1-5-RELEASE/external/gpl3/gdb/dist/gdb/
H A Dobjfiles.c1263 int alloc_size, map_size, i;
1272 alloc_size = 0;
1276 alloc_size += 1;
1279 if (alloc_size == 0)
1286 map = xmalloc (alloc_size * sizeof (*map));
1294 qsort (map, alloc_size, sizeof (*map), qsort_cmp);
1295 map_size = filter_debuginfo_sections(map, alloc_size);
1298 if (map_size < alloc_size)
1302 gdb_assert (alloc_size == map_size);
1261 int alloc_size, map_size, i; local
/netbsd-6-1-5-RELEASE/external/gpl3/gcc/dist/gcc/
H A Dggc-zone.c2298 size_t alloc_size; member in struct:ggc_pch_data
2354 size_t alloc_size, total_size; local
2365 alloc_size = CEIL (d->d.total, BYTES_PER_ALLOC_BIT * 8);
2366 alloc_size = ROUND_UP (alloc_size, MAX_ALIGNMENT);
2367 d->alloc_size = alloc_size;
2369 return d->d.total + alloc_size;
2388 d->alloc_bits = XCNEWVAR (alloc_type, d->alloc_size);
2452 if (fwrite (d->alloc_bits, d->alloc_size,
2470 size_t alloc_size; local
[all...]
H A Dggc-page.c314 size_t alloc_size;
813 size_t alloc_size, head_slop, tail_slop;
817 alloc_size = GGC_QUIRE_SIZE * G.pagesize;
819 alloc_size = entry_size + G.pagesize - 1;
820 allocation = XNEWVEC (char, alloc_size);
825 tail_slop = ((size_t) allocation + alloc_size) & (G.pagesize - 1);
827 tail_slop = alloc_size - entry_size - head_slop;
828 enda = allocation + alloc_size - tail_slop;
852 group->alloc_size = alloc_size;
312 size_t alloc_size; member in struct:page_group
810 size_t alloc_size, head_slop, tail_slop; local
[all...]
/netbsd-6-1-5-RELEASE/gnu/dist/gcc4/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.c309 size_t alloc_size;
803 size_t alloc_size, head_slop, tail_slop;
807 alloc_size = GGC_QUIRE_SIZE * G.pagesize;
809 alloc_size = entry_size + G.pagesize - 1;
810 allocation = xmalloc (alloc_size);
815 tail_slop = ((size_t) allocation + alloc_size) & (G.pagesize - 1);
817 tail_slop = alloc_size - entry_size - head_slop;
818 enda = allocation + alloc_size - tail_slop;
842 group->alloc_size = alloc_size;
307 size_t alloc_size; member in struct:page_group
800 size_t alloc_size, head_slop, tail_slop; local
[all...]
/netbsd-6-1-5-RELEASE/sys/arch/shark/ofw/
H A Dofw.c1888 vsize_t alloc_size = (size + PAGE_SIZE - 1) & ~(PAGE_SIZE - 1); local
1893 if (alloc_size == 0)
1896 for (aligned_size = 1; aligned_size < alloc_size; aligned_size <<= 1)
1904 if (ofw_claimvirt(va, alloc_size, 0) != va)
1906 pa = ofw_claimphys(0, alloc_size, aligned_size);
1910 ofw_settranslation(va, pa, alloc_size, -1);
1913 memset((char *)va, 0, alloc_size);
1926 vsize_t alloc_size = (size + PAGE_SIZE - 1) & ~(PAGE_SIZE - 1); local
1927 int npages = alloc_size / PAGE_SIZE;
/netbsd-6-1-5-RELEASE/gnu/dist/texinfo/info/
H A Dfilesys.c341 int alloc_size; local
344 alloc_size = names_and_files_slots * sizeof (FILENAME_LIST *);
347 (FILENAME_LIST **) xrealloc (names_and_files, alloc_size);

Completed in 403 milliseconds

12