/third_party/ltp/testcases/kernel/syscalls/pkeys/ |
D | pkey01.c | 72 {PROT_READ, MAP_ANONYMOUS | MAP_PRIVATE, -1}, 74 {PROT_READ, MAP_ANONYMOUS | MAP_PRIVATE | MAP_HUGETLB, -1}, 76 {PROT_READ, MAP_PRIVATE, 0}, 79 {PROT_WRITE, MAP_ANONYMOUS | MAP_PRIVATE, -1}, 81 {PROT_WRITE, MAP_PRIVATE, 0}, 83 {PROT_WRITE, MAP_ANONYMOUS | MAP_PRIVATE | MAP_HUGETLB, -1}, 86 {PROT_EXEC, MAP_ANONYMOUS | MAP_PRIVATE, -1}, 88 {PROT_EXEC, MAP_ANONYMOUS | MAP_PRIVATE | MAP_HUGETLB, -1}, 90 {PROT_EXEC, MAP_PRIVATE, 0}, 93 {PROT_READ | PROT_WRITE, MAP_ANONYMOUS | MAP_PRIVATE, -1}, [all …]
|
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/mmap/ |
D | 5-1.c | 52 {.flags = MAP_PRIVATE,.prot = PROT_NONE}, 53 {.flags = MAP_PRIVATE,.prot = PROT_READ}, 54 {.flags = MAP_PRIVATE,.prot = PROT_WRITE}, 55 {.flags = MAP_PRIVATE,.prot = PROT_EXEC}, 56 {.flags = MAP_PRIVATE,.prot = PROT_READ | PROT_WRITE}, 57 {.flags = MAP_PRIVATE,.prot = PROT_READ | PROT_EXEC}, 58 {.flags = MAP_PRIVATE,.prot = PROT_EXEC | PROT_WRITE}, 59 {.flags = MAP_PRIVATE,.prot = PROT_READ | PROT_WRITE | PROT_EXEC}, 82 case MAP_PRIVATE: in print_error()
|
D | 7-2.c | 65 pa = mmap(NULL, size, PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0); in main() 82 pa = mmap(NULL, size, PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0); in main()
|
/third_party/ltp/testcases/kernel/mem/hugetlb/hugemmap/ |
D | hugemmap18.c | 46 p = mmap(NULL, hpage_size, PROT_READ|PROT_WRITE, MAP_PRIVATE, fd, 0); in run_test() 62 MAP_PRIVATE, fd, 0); in run_test() 76 MAP_PRIVATE|MAP_FIXED, fd, 0); in run_test() 83 q = mmap(NULL, page_size, PROT_READ|PROT_WRITE, MAP_PRIVATE, fd, 0); in run_test() 93 MAP_PRIVATE|MAP_FIXED, fd, 0); in run_test() 103 MAP_PRIVATE, fd, page_size); in run_test() 112 MAP_PRIVATE|MAP_FIXED, fd, page_size); in run_test()
|
D | hugemmap10.c | 63 p = SAFE_MMAP(NULL, hpage_size, PROT_READ|PROT_WRITE, MAP_PRIVATE, fd, 0); in kernel_has_private_reservations() 326 if (MAP(SL_TEST, 1, MAP_PRIVATE, "doing mmap private with no touch") || in test_counters() 327 UNMAP(SL_TEST, 1, MAP_PRIVATE, "doing munmap private with on touch")) in test_counters() 337 if (MAP(SL_TEST, 1, MAP_PRIVATE, "doing mmap private followed by touch") || in test_counters() 338 TOUCH(SL_TEST, 1, MAP_PRIVATE, "touching the addr after mmap private") || in test_counters() 339 UNMAP(SL_TEST, 1, MAP_PRIVATE, "doing munmap private after touch")) in test_counters() 401 if (MAP(SL_SETUP, 1, MAP_PRIVATE, "mmap for test having prior untouched private mmap") || in test_per_base_nr() 403 UNMAP(SL_SETUP, 1, MAP_PRIVATE, "unmap after test having prior untouched private mmap")) in test_per_base_nr() 414 if (MAP(SL_SETUP, 1, MAP_PRIVATE, "mmap for test with having touched private mmap") || in test_per_base_nr() 415 TOUCH(SL_SETUP, 1, MAP_PRIVATE, "touching for test with having touched private mmap") || in test_per_base_nr() [all …]
|
D | hugemmap17.c | 53 MAP_PRIVATE | MAP_NORESERVE, fd, 0); in run_test() 58 MAP_PRIVATE, fd, 0); in run_test()
|
/third_party/musl/Benchmark/musl/ |
D | libc_mman.cpp | 32 MAP_PRIVATE | MAP_ANONYMOUS, 34 MAP_PRIVATE | MAP_ANONYMOUS | MAP_HUGETLB, 35 MAP_PRIVATE | MAP_ANONYMOUS | MAP_HUGE_2MB, 36 MAP_PRIVATE | MAP_ANONYMOUS | MAP_HUGE_1GB, 37 MAP_PRIVATE | MAP_ANONYMOUS | MAP_POPULATE, 38 MAP_PRIVATE | MAP_ANONYMOUS | MAP_HUGETLB | MAP_POPULATE, 39 MAP_PRIVATE | MAP_ANONYMOUS | MAP_HUGE_2MB | MAP_POPULATE, 40 MAP_PRIVATE | MAP_ANONYMOUS | MAP_HUGE_1GB | MAP_POPULATE, 219 …void *oldAddr = mmap(nullptr, oldLength, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS, -1, … in Bm_function_Mremap() 245 …char* mem = (char *)mmap(nullptr, length, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS, -1,… in Bm_function_Msync() [all …]
|
/third_party/ltp/testcases/kernel/syscalls/memfd_create/ |
D | memfd_create03.c | 39 mem = SAFE_MMAP(NULL, size, PROT_WRITE, MAP_PRIVATE, fd, 0); in check_huge_mmapable() 45 NULL, size, PROT_WRITE, MAP_PRIVATE, fd, 0); in check_huge_mmapable() 133 new_mem = mmap(NULL, hps, 0, MAP_PRIVATE, new_fd, 0); in test_max_hugepages() 138 NULL, hps, 0, MAP_PRIVATE, new_fd, 0); in test_max_hugepages() 142 NULL, hps, 0, MAP_PRIVATE, new_fd, 0); in test_max_hugepages() 146 NULL, hps, 0, MAP_PRIVATE, new_fd, 0); in test_max_hugepages()
|
/third_party/ltp/testcases/kernel/syscalls/mmap/ |
D | mmap19.c | 40 mm1 = SAFE_MMAP(0, LEN, PROT_READ, MAP_PRIVATE, f1, 0); in run() 41 mm2 = SAFE_MMAP(0, LEN, PROT_READ, MAP_PRIVATE, f2, 0); in run() 55 mm1 = SAFE_MMAP(save_mm2, LEN, PROT_READ, MAP_PRIVATE, f1, 0); in run() 56 mm2 = SAFE_MMAP(save_mm1, LEN, PROT_READ, MAP_PRIVATE, f2, 0); in run()
|
D | mmap06.c | 32 {MMAPSIZE, PROT_WRITE, MAP_FILE | MAP_PRIVATE, EACCES}, 34 {MMAPSIZE, PROT_READ, MAP_FILE | MAP_PRIVATE, EACCES}, 36 {MMAPSIZE, PROT_READ | PROT_WRITE, MAP_FILE | MAP_PRIVATE, EACCES},
|
D | mmap18.c | 93 MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in allocate_stack() 97 MAP_FIXED | MAP_PRIVATE | MAP_ANONYMOUS | MAP_GROWSDOWN, in allocate_stack() 187 MAP_FIXED | MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in grow_stack_fail()
|
D | mmap17.c | 65 MAP_PRIVATE, fd_file1, 0); in test_mmap() 70 MAP_PRIVATE | MAP_FIXED_NOREPLACE, fd_file2, 0); in test_mmap()
|
/third_party/musl/libc-test/src/functionalext/supplement/ldso/ldso_gtest/ |
D | ldso_dlopen_ext_test.cpp | 64 …void* addr = mmap(nullptr, SIZE_1024_SQUARE, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, INVALID_VALUE… 92 void* addr = mmap(nullptr, SIZE_128, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, INVALID_VALUE, 0); 111 …void* addr = mmap(nullptr, SIZE_1024_SQUARE, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, INVALID_VALUE… 142 …void* addr = mmap(nullptr, SIZE_1024_SQUARE, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, INVALID_VALUE… 182 void* addr = mmap(nullptr, SIZE_128, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, INVALID_VALUE, 0); 287 …void* addr = mmap(nullptr, SIZE_1024_SQUARE, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, INVALID_VALUE… 323 …void* addr = mmap(nullptr, SIZE_1024_SQUARE, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, INVALID_VALUE… 358 …void* addr = mmap(nullptr, SIZE_1024_SQUARE, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, INVALID_VALUE… 394 void* addr = mmap(nullptr, SIZE_128, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, INVALID_VALUE, 0);
|
/third_party/musl/libc-test/src/functionalext/supplement/mman/mman_gtest/ |
D | mman_mmap_test.cpp | 48 void* mapping = mmap(nullptr, SIZE, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0); 97 void* mmapping = mmap(nullptr, sb.st_size, PROT_NONE, MAP_PRIVATE | MAP_FIXED, -1, 0); 137 void* mmapping = mmap(nullptr, sb.st_size, PROT_EXEC, MAP_PRIVATE | MAP_LOCKED, fd, 0); 153 …EXPECT_EQ(MAP_FAILED, mmap(nullptr, (PTRDIFF_MAX) + 1, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1,…
|
/third_party/elfutils/lib/ |
D | crc32_file.c | 53 void *mapped = mmap (NULL, mapsize, PROT_READ, MAP_PRIVATE, fd, 0); in crc32_file() 59 && (mapped = mmap (NULL, mapsize, PROT_READ, MAP_PRIVATE, in crc32_file() 76 } while (mmap (mapped, mapsize, PROT_READ, MAP_FIXED|MAP_PRIVATE, in crc32_file()
|
/third_party/ltp/testcases/kernel/syscalls/mlock/ |
D | mlock02.c | 41 MAP_PRIVATE | MAP_ANONYMOUS, 0, 0); in test_enomem1() 55 MAP_PRIVATE | MAP_ANONYMOUS, 0, 0); in test_enomem2() 72 MAP_PRIVATE | MAP_ANONYMOUS, 0, 0); in test_eperm()
|
/third_party/musl/libc-test/src/functionalext/relro/ |
D | dlopen_ext_relro_test.c | 418 void *map = mmap(NULL, map_size, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in dlopen_ext_relro_1600() 455 void *map = mmap(NULL, map_size, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in dlopen_ext_relro_1700() 492 void *map = mmap(NULL, map_size, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in dlopen_ext_relro_1800() 529 void *map = mmap(NULL, map_size, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in dlopen_ext_relro_1900() 564 void *map = mmap(NULL, map_size, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in dlopen_ext_relro_2000() 601 void *map = mmap(NULL, map_size, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in dlopen_ext_relro_2100() 639 void *map = mmap(NULL, map_size, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in dlopen_ext_relro_2200() 678 void *map = mmap(NULL, map_size, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in dlopen_ext_relro_2300() 716 void *map = mmap(NULL, map_size, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); in dlopen_ext_relro_2400()
|
/third_party/ltp/testcases/open_posix_testsuite/conformance/definitions/sys/mman_h/ |
D | 3-2-buildonly.c | 18 #ifndef MAP_PRIVATE 19 #error MAP_PRIVATE not defined
|
/third_party/ltp/testcases/kernel/mem/vma/ |
D | vma01.c | 96 t = mmap(p, 3 * ps, PROT_WRITE, MAP_ANONYMOUS | MAP_PRIVATE, -1, 0); in check_vma() 107 MAP_ANONYMOUS | MAP_PRIVATE, -1, 0); in check_vma() 153 t = mmap(NULL, 9 * ps, PROT_WRITE, MAP_ANONYMOUS | MAP_PRIVATE, -1, 0); in create_bighole()
|
/third_party/rust/crates/nix/test/sys/ |
D | test_mman.rs | 11 MapFlags::MAP_PRIVATE | MapFlags::MAP_ANONYMOUS, in test_mmap_anonymous() 36 MapFlags::MAP_ANONYMOUS | MapFlags::MAP_PRIVATE, in test_mremap_grow() 94 MapFlags::MAP_ANONYMOUS | MapFlags::MAP_PRIVATE, in test_mremap_shrink()
|
/third_party/ltp/testcases/kernel/mem/mmapstress/ |
D | mmapstress05.c | 180 MAP_FILE | MAP_PRIVATE | MAP_FIXED, fd, in main() 187 MAP_FILE | MAP_PRIVATE | MAP_FIXED, fd, in main() 194 MAP_FILE | MAP_PRIVATE | MAP_FIXED, fd, 0) == (caddr_t) - 1) { in main()
|
/third_party/musl/libc-test/src/functionalext/supplement/hook/hook_gtest/ |
D | hook_munmap_test.cpp | 21 void* ptr = mmap(nullptr, MMAP_SIZE, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0); 34 void* ptr = mmap64(nullptr, MMAP_SIZE, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0);
|
/third_party/FreeBSD/lib/libc/gen/ |
D | arc4random.h | 77 MAP_ANON|MAP_PRIVATE, -1, 0)) == MAP_FAILED) in _rs_allocate() 81 MAP_ANON|MAP_PRIVATE, -1, 0)) == MAP_FAILED) { in _rs_allocate()
|
/third_party/musl/libc-test/src/functionalext/supplement/mman/ |
D | mmap.c | 52 start = mmap(NULL, statbuff.st_size, PROT_READ, MAP_PRIVATE, fd, 0); in mmap_0100() 144 start = mmap(NULL, statbuff.st_size, PROT_EXEC, MAP_PRIVATE | MAP_LOCKED, fd, 0); in mmap_0400() 182 … start = mmap(NULL, statbuff.st_size, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_DENYWRITE, fd, 0); in mmap_0500() 219 start = mmap(NULL, statbuff.st_size, PROT_NONE, MAP_PRIVATE | MAP_FIXED, -1, 0); in mmap_0600() 391 …start = mmap((void *)(&get), statbuff.st_size, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_DENYWRITE… in mmap_1100()
|
/third_party/musl/libc-test/src/common/ |
D | vmfill.c | 21 if ((p=mmap(0, n, PROT_NONE, MAP_PRIVATE|MAP_ANONYMOUS, fd, 0)) == MAP_FAILED) { in mmax() 50 q = mmap(0, m, PROT_NONE, MAP_PRIVATE|MAP_ANONYMOUS, fd, 0); in t_vmfill()
|