| /src/ |
| A D | slab.c | 499 if (size == 0) in rt_slab_alloc() 508 size = RT_ALIGN(size, RT_MM_PAGE_SIZE); in rt_slab_alloc() 517 kup->size = size >> RT_MM_PAGE_BITS; in rt_slab_alloc() 520 size, in rt_slab_alloc() 630 if ((size | (size - 1)) + 1 == (size << 1)) in rt_slab_alloc() 631 off = (off + size - 1) & ~(size - 1); in rt_slab_alloc() 679 if (size == 0) in rt_slab_realloc() 697 rt_memcpy(nptr, ptr, size > osize ? osize : size); in rt_slab_realloc() 720 rt_memcpy(nptr, ptr, size > z->z_chunksize ? z->z_chunksize : size); in rt_slab_realloc() 767 size = kup->size; in rt_slab_free() [all …]
|
| A D | mem.c | 172 rt_size_t size) in rt_smem_init() argument 277 if (size == 0) in rt_smem_alloc() 286 size = RT_ALIGN(size, RT_ALIGN_SIZE); in rt_smem_alloc() 289 if (size < MIN_SIZE_ALIGNED) in rt_smem_alloc() 290 size = MIN_SIZE_ALIGNED; in rt_smem_alloc() 405 rt_size_t size; in rt_smem_realloc() local 443 if (size == newsize) in rt_smem_realloc() 483 rt_memcpy(nmem, rmem, size < newsize ? size : newsize); in rt_smem_realloc() 642 int size = MEM_SIZE(m, mem); in memtrace() local 645 if (size < 1024) in memtrace() [all …]
|
| A D | memheap.c | 82 rt_size_t size) in rt_memheap_init() argument 197 size = RT_ALIGN(size, RT_ALIGN_SIZE); in rt_memheap_alloc() 198 if (size < RT_MEMHEAP_MINIALLOC) in rt_memheap_alloc() 199 size = RT_MEMHEAP_MINIALLOC; in rt_memheap_alloc() 202 size, RT_NAME_MAX, heap->parent.name); in rt_memheap_alloc() 204 if (size < heap->available_size) in rt_memheap_alloc() 227 if (free_size < size) in rt_memheap_alloc() 235 if (free_size >= size) in rt_memheap_alloc() 287 size - in rt_memheap_alloc() 331 size); in rt_memheap_alloc() [all …]
|
| A D | kservice.c | 586 static void (*rt_malloc_hook)(void **ptr, rt_size_t size); 588 static void (*rt_realloc_exit_hook)(void **ptr, rt_size_t size); 602 void rt_malloc_sethook(void (*hook)(void **ptr, rt_size_t size)) in rt_malloc_sethook() argument 722 void *_memheap_alloc(struct rt_memheap *heap, rt_size_t size); 807 rt_weak void *rt_malloc(rt_size_t size) in rt_malloc() argument 815 ptr = _MEM_MALLOC(size); in rt_malloc() 819 RT_OBJECT_HOOK_CALL(rt_malloc_hook, (&ptr, size)); in rt_malloc() 865 rt_weak void *rt_calloc(rt_size_t count, rt_size_t size) in rt_calloc() argument 870 p = rt_malloc(count * size); in rt_calloc() 874 rt_memset(p, 0, count * size); in rt_calloc() [all …]
|
| A D | ipc.c | 2363 mb->size = (rt_uint16_t)size; in rt_mb_init() 2470 mb->size = (rt_uint16_t)size; in rt_mb_create() 2598 while (mb->entry == mb->size) in _rt_mb_send_wait() 2780 if (mb->entry == mb->size) in rt_mb_urgent() 3395 RT_ASSERT(size != 0); in _rt_mq_send_wait() 3401 if (size > mq->msg_size) in _rt_mq_send_wait() 3660 RT_ASSERT(size != 0); in rt_mq_urgent() 3663 if (size > mq->msg_size) in rt_mq_urgent() 3778 RT_ASSERT(size != 0); in _rt_mq_recv() 3885 if (len > size) in _rt_mq_recv() [all …]
|
| A D | Kconfig | 6 int "The maximal size of kernel object name" 11 the RT_NAME_MAX is the maximal size of this object name. 87 int "Alignment size for CPU architecture data access" 90 Alignment size for CPU architecture data access 153 int "The max size of idle hook list" 157 The system has a hook list. This is the hook list size. 161 int "The stack size of idle thread" 166 int "The stack size of system thread (for defunct etc.)" 183 int "The stack size of timer thread" 328 Best size first. [all …]
|
| A D | mempool.c | 87 rt_size_t size, in rt_mp_init() argument 97 RT_ASSERT(size > 0 && block_size > 0); in rt_mp_init() 104 mp->size = RT_ALIGN_DOWN(size, RT_ALIGN_SIZE); in rt_mp_init() 111 mp->block_total_count = mp->size / (mp->block_size + sizeof(rt_uint8_t *)); in rt_mp_init() 199 mp->size = (block_size + sizeof(rt_uint8_t *)) * block_count; in rt_mp_create()
|
| /src/klibc/ |
| A D | rt_vsnprintf_tiny.c | 85 int size = 0; in print_number() local 87 size = s; in print_number() 145 size -= 2; in print_number() 149 size--; in print_number() 168 size -= precision; in print_number() 174 size--; in print_number() 177 while (size-- > 0) in print_number() 194 -- size; in print_number() 266 while (size-- > 0) in print_number() 316 end = buf + size; in rt_vsnprintf() [all …]
|
| A D | kstdio.c | 28 int rt_snprintf(char *buf, rt_size_t size, const char *fmt, ...) in rt_snprintf() argument 34 n = rt_vsnprintf(buf, size, fmt, args); in rt_snprintf() 81 int rt_vsnprintf(char *buf, rt_size_t size, const char *fmt, va_list args) in rt_vsnprintf() argument 83 return vsnprintf(buf, size, fmt, args); in rt_vsnprintf()
|
| A D | Kconfig | 64 int "'ntoa' conversion buffer size" 67 'ntoa' conversion buffer size, this must be big enough to hold one converted 71 int "printing individual decimal numbers buffer size" 74 size of the fixed (on-stack) buffer for printing individual decimal numbers.
|
| A D | rt_vsnprintf_std.c | 1347 int rt_vsnprintf(char *buf, rt_size_t size, const char *fmt, va_list args) in rt_vsnprintf() argument 1349 output_gadget_t gadget = buffer_gadget(buf, size); in rt_vsnprintf()
|