/third_party/musl/src/thread/ |
H A D | pthread_getattr_np.c | 17 size_t l = PAGE_SIZE; in pthread_getattr_np() 18 p += -(uintptr_t)p & PAGE_SIZE-1; in pthread_getattr_np() 20 while (mremap(p-l-PAGE_SIZE, PAGE_SIZE, 2*PAGE_SIZE, 0)==MAP_FAILED && errno==ENOMEM) in pthread_getattr_np() 21 l += PAGE_SIZE; in pthread_getattr_np()
|
/third_party/musl/src/malloc/oldmalloc/ |
H A D | malloc.c | 176 if (n > SIZE_MAX/2 - PAGE_SIZE) { in __expand_heap() 180 n += -n & PAGE_SIZE-1; in __expand_heap() 184 brk += -brk & PAGE_SIZE-1; in __expand_heap() 194 size_t min = (size_t)PAGE_SIZE << mmap_step/2; in __expand_heap() 256 if (*n-1 > PTRDIFF_MAX - SIZE_ALIGN - PAGE_SIZE) { in adjust_size() 330 size_t len = n + OVERHEAD + PAGE_SIZE - 1 & -PAGE_SIZE; in malloc() 334 len += PAGE_SIZE << 1; in malloc() 342 if (mprotect(base, PAGE_SIZE, PROT_NONE) || in malloc() 343 mprotect(base + len - PAGE_SIZE, PAGE_SIZ in malloc() [all...] |
/third_party/musl/porting/liteos_a/user_debug/src/malloc/oldmalloc/ |
H A D | malloc.c | 170 if (n > SIZE_MAX/2 - PAGE_SIZE) { in __expand_heap() 174 n += -n & PAGE_SIZE-1; in __expand_heap() 178 brk += -brk & PAGE_SIZE-1; in __expand_heap() 188 size_t min = (size_t)PAGE_SIZE << mmap_step/2; in __expand_heap() 244 if (*n-1 > PTRDIFF_MAX - SIZE_ALIGN - PAGE_SIZE) { in adjust_size() 312 size_t len = n + OVERHEAD + PAGE_SIZE - 1 & -PAGE_SIZE; in malloc() 315 len += PAGE_SIZE << 1; in malloc() 321 if (mprotect(base, PAGE_SIZE, PROT_NONE) || in malloc() 322 mprotect(base + len - PAGE_SIZE, PAGE_SIZ in malloc() [all...] |
/third_party/libunwind/libunwind/tests/ |
H A D | Ltest-mem-validate.c | 46 #define PAGE_SIZE 4096 macro 55 mprotect((void*)((uintptr_t)stack_start & ~(PAGE_SIZE - 1)), in do_backtrace() 56 PAGE_SIZE, PROT_NONE); in do_backtrace() 90 mprotect((void*)((uintptr_t)stack_start & ~(PAGE_SIZE - 1)), in do_backtrace() 91 PAGE_SIZE, PROT_READ|PROT_WRITE); in do_backtrace() 122 char string[PAGE_SIZE]; in main()
|
/third_party/musl/src/malloc/ |
H A D | lite_malloc.c | 63 size_t req = n - (end-cur) + PAGE_SIZE-1 & -PAGE_SIZE; in __simple_malloc() 67 brk += -brk & PAGE_SIZE-1; in __simple_malloc() 77 req = n + PAGE_SIZE-1 & -PAGE_SIZE; in __simple_malloc() 83 size_t min = PAGE_SIZE<<(mmap_step/2); in __simple_malloc()
|
/third_party/musl/porting/linux/user/src/malloc/ |
H A D | lite_malloc.c | 63 size_t req = n - (end-cur) + PAGE_SIZE-1 & -PAGE_SIZE; in __simple_malloc() 67 brk += -brk & PAGE_SIZE-1; in __simple_malloc() 77 req = n + PAGE_SIZE-1 & -PAGE_SIZE; in __simple_malloc() 83 size_t min = PAGE_SIZE<<(mmap_step/2); in __simple_malloc()
|
/third_party/ltp/testcases/kernel/controllers/memcg/control/ |
H A D | memcg_control_test.sh | 13 PAGE_SIZE=$(tst_getconf PAGESIZE) 15 TOT_MEM_LIMIT=$PAGE_SIZE 16 ACTIVE_MEM_LIMIT=$PAGE_SIZE 17 PROC_MEM=$((PAGE_SIZE * 2))
|
/third_party/musl/libc-test/src/common/ |
H A D | vmfill.c | 7 #ifndef PAGE_SIZE 8 #define PAGE_SIZE sysconf(_SC_PAGE_SIZE) macro 20 for (i=n=*start; i>=PAGE_SIZE; i/=2) { in mmax() 30 return n & -PAGE_SIZE; in mmax()
|
/third_party/libunwind/libunwind/src/s390x/ |
H A D | Ginit.c | 96 #define PAGE_SIZE 4096 macro 97 #define PAGE_START(a) ((a) & ~(PAGE_SIZE-1)) 166 for (i = 0; i < (len + PAGE_SIZE - 1) / PAGE_SIZE; i++) in mincore_validate() 189 while ((ret = mincore ((void*)addr, PAGE_SIZE, mvec)) == -1 && in tdep_init_mem_validate() 216 len = PAGE_SIZE; in validate_mem() 218 len = PAGE_SIZE * 2; in validate_mem()
|
/third_party/FreeBSD/sys/compat/linuxkpi/common/include/asm/ |
H A D | page.h | 40 #ifndef PAGE_SIZE 41 #define PAGE_SIZE (0x1000U) macro 43 #define PAGE_MASK (~(PAGE_SIZE - 1))
|
/third_party/ltp/testcases/commands/mkswap/ |
H A D | mkswap01.sh | 19 PAGE_SIZE=`tst_getconf PAGESIZE` 22 # multiple of $PAGE_SIZE and use that as the size for testing. 24 DEVICE_SIZE=$((($real_size/$PAGE_SIZE * $PAGE_SIZE)/1024)) 51 local pagesize=$PAGE_SIZE 60 if [ $pagesize -ne $PAGE_SIZE ]; then 143 2) mkswap_test "" "" "$TST_DEVICE" "$((DEVICE_SIZE-PAGE_SIZE/1024))";; 144 3) mkswap_test "-f" "" "$TST_DEVICE" "$((DEVICE_SIZE+PAGE_SIZE/1024))";;
|
/third_party/musl/src/mman/ |
H A D | mprotect.c | 8 start = (size_t)addr & -PAGE_SIZE; in __mprotect() 9 end = (size_t)((char *)addr + len + PAGE_SIZE-1) & -PAGE_SIZE; in __mprotect()
|
/third_party/elfio/examples/writer/ |
H A D | writer.cpp | 42 const Elf_Xword PAGE_SIZE = 0x1000; variable 43 const Elf64_Addr DATA_ADDR = CODE_ADDR + PAGE_SIZE; 83 text_seg->set_align( PAGE_SIZE ); in main() 106 data_seg->set_align( PAGE_SIZE ); in main()
|
/third_party/ltp/testcases/kernel/io/direct_io/ |
H A D | dma_thread_diotest.c | 117 #define PAGE_SIZE getpagesize() macro 119 #define MAX_WORKERS (READSIZE/PAGE_SIZE) 271 worker[j].offset = offset + j * PAGE_SIZE; in dma_thread_diotest_verify() 273 buffer + align + j * PAGE_SIZE; in dma_thread_diotest_verify() 274 worker[j].length = PAGE_SIZE; in dma_thread_diotest_verify() 278 READSIZE - PAGE_SIZE * (workers - 1); in dma_thread_diotest_verify() 350 if (align < 0 || align > PAGE_SIZE) in setup() 422 if (posix_memalign((void **)&buffer, PAGE_SIZE, READSIZE + align) != 0) in setup()
|
/third_party/musl/porting/liteos_a/user/src/malloc/oldmalloc/ |
H A D | malloc.c | 168 if (n > SIZE_MAX/2 - PAGE_SIZE) { in __expand_heap() 172 n += -n & PAGE_SIZE-1; in __expand_heap() 176 brk += -brk & PAGE_SIZE-1; in __expand_heap() 186 size_t min = (size_t)PAGE_SIZE << mmap_step/2; in __expand_heap() 237 if (*n-1 > PTRDIFF_MAX - SIZE_ALIGN - PAGE_SIZE) { in adjust_size() 302 size_t len = n + OVERHEAD + PAGE_SIZE - 1 & -PAGE_SIZE; in malloc() 374 if (newlen < PAGE_SIZE && (new = malloc(n-OVERHEAD))) { in realloc() 378 newlen = (newlen + PAGE_SIZE-1) & -PAGE_SIZE; in realloc() [all...] |
/third_party/libunwind/libunwind/src/x86/ |
H A D | Ginit.c | 77 #define PAGE_SIZE 4096 macro 78 #define PAGE_START(a) ((a) & ~(PAGE_SIZE-1)) 95 len = PAGE_SIZE; in validate_mem() 97 len = PAGE_SIZE * 2; in validate_mem()
|
/third_party/musl/porting/liteos_a/user/ldso/ |
H A D | dynlink.c | 178 size_t pgsz = PAGE_SIZE; in laddr_pg() 556 reclaim(dso, ph->p_vaddr & -PAGE_SIZE, ph->p_vaddr); in reclaim_gaps() 558 ph->p_vaddr+ph->p_memsz+PAGE_SIZE-1 & -PAGE_SIZE); in reclaim_gaps() 668 dso->relro_start = ph->p_vaddr & -PAGE_SIZE; in map_library() 669 dso->relro_end = (ph->p_vaddr + ph->p_memsz) & -PAGE_SIZE; in map_library() 701 map = mmap(0, ph->p_memsz + (ph->p_vaddr & PAGE_SIZE-1), in map_library() 703 fd, ph->p_offset & -PAGE_SIZE); in map_library() 709 (ph->p_vaddr & PAGE_SIZE-1); in map_library() 714 size_t brk = (ph->p_vaddr & PAGE_SIZE in map_library() [all...] |
/third_party/musl/porting/liteos_a/user_debug/ldso/ |
H A D | dynlink.c | 178 size_t pgsz = PAGE_SIZE; in laddr_pg() 556 reclaim(dso, ph->p_vaddr & -PAGE_SIZE, ph->p_vaddr); in reclaim_gaps() 558 ph->p_vaddr+ph->p_memsz+PAGE_SIZE-1 & -PAGE_SIZE); in reclaim_gaps() 668 dso->relro_start = ph->p_vaddr & -PAGE_SIZE; in map_library() 669 dso->relro_end = (ph->p_vaddr + ph->p_memsz) & -PAGE_SIZE; in map_library() 701 map = mmap(0, ph->p_memsz + (ph->p_vaddr & PAGE_SIZE-1), in map_library() 703 fd, ph->p_offset & -PAGE_SIZE); in map_library() 709 (ph->p_vaddr & PAGE_SIZE-1); in map_library() 714 size_t brk = (ph->p_vaddr & PAGE_SIZE in map_library() [all...] |
/third_party/musl/porting/liteos_a/kernel/include/ |
H A D | limits.h | 10 #ifndef PAGE_SIZE 11 #define PAGE_SIZE 4096 macro 14 #define PAGESIZE PAGE_SIZE
|
/third_party/rust/crates/rustix/src/backend/linux_raw/param/ |
H A D | mustang_auxv.rs | 26 unsafe { PAGE_SIZE } 92 static mut PAGE_SIZE: usize = 0; consts 132 AT_PAGESZ => PAGE_SIZE = a_val as usize, in init_from_auxp()
|
/third_party/libunwind/libunwind/src/aarch64/ |
H A D | Ginit.c | 89 #define PAGE_SIZE 4096 macro 90 #define PAGE_START(a) ((a) & ~(PAGE_SIZE-1)) 199 while ((ret = mincore ((void*)addr, PAGE_SIZE, (unsigned char *)mvec)) == -1 && in tdep_init_mem_validate() 295 len = PAGE_SIZE; in validate_mem() 297 len = PAGE_SIZE * 2; in validate_mem()
|
/third_party/libunwind/libunwind/src/arm/ |
H A D | Ginit.c | 79 #define PAGE_SIZE 4096 macro 80 #define PAGE_START(a) ((a) & ~(PAGE_SIZE-1)) 194 while ((ret = mincore ((void*)addr, PAGE_SIZE, (unsigned char *)mvec)) == -1 && in tdep_init_mem_validate() 290 len = PAGE_SIZE; in validate_mem() 292 len = PAGE_SIZE * 2; in validate_mem()
|
/third_party/libunwind/libunwind/src/riscv/ |
H A D | Ginit.c | 100 #define PAGE_SIZE 4096 macro 101 #define PAGE_START(a) ((a) & ~(PAGE_SIZE-1)) 216 while ((ret = mincore ((void*)addr, PAGE_SIZE, (unsigned char *)mvec)) == -1 && in tdep_init_mem_validate() 312 len = PAGE_SIZE; in validate_mem() 314 len = PAGE_SIZE * 2; in validate_mem()
|
/third_party/libunwind/libunwind/src/x86_64/ |
H A D | Ginit.c | 76 #define PAGE_SIZE 4096 macro 77 #define PAGE_START(a) ((a) & ~(PAGE_SIZE-1)) 197 while ((ret = mincore ((void*)addr, PAGE_SIZE, (unsigned char *)mvec)) == -1 && in tdep_init_mem_validate() 293 len = PAGE_SIZE; in validate_mem() 295 len = PAGE_SIZE * 2; in validate_mem()
|
/third_party/musl/porting/linux/user/src/internal/ |
H A D | libc.h | 53 #ifndef PAGE_SIZE 54 #define PAGE_SIZE libc.page_size macro
|