Lines Matching full:pagesize
33 static size_t pagesize; variable
68 for (; size; addr += pagesize, size -= pagesize) in range_is_swapped()
684 mem = mmap(NULL, pagesize, PROT_READ | PROT_WRITE, in do_run_with_base_page()
691 ret = madvise(mem, pagesize, MADV_NOHUGEPAGE); in do_run_with_base_page()
699 memset(mem, 0, pagesize); in do_run_with_base_page()
702 madvise(mem, pagesize, MADV_PAGEOUT); in do_run_with_base_page()
709 fn(mem, pagesize); in do_run_with_base_page()
711 munmap(mem, pagesize); in do_run_with_base_page()
766 if (!pagemap_is_populated(pagemap_fd, mem + pagesize)) { in do_run_with_thp()
783 ret = mprotect(mem + pagesize, pagesize, PROT_READ); in do_run_with_thp()
788 ret = mprotect(mem + pagesize, pagesize, PROT_READ | PROT_WRITE); in do_run_with_thp()
800 ret = madvise(mem + pagesize, thpsize - pagesize, MADV_DONTNEED); in do_run_with_thp()
805 size = pagesize; in do_run_with_thp()
833 ret = madvise(mem + pagesize, thpsize - pagesize, MADV_DONTFORK); in do_run_with_thp()
847 ret = madvise(mem + pagesize, thpsize - pagesize, MADV_DOFORK); in do_run_with_thp()
1152 ret = mprotect(mem + pagesize, pagesize, PROT_READ); in do_test_anon_thp_collapse()
1157 ret = mprotect(mem + pagesize, pagesize, PROT_READ | PROT_WRITE); in do_test_anon_thp_collapse()
1384 mem = mmap(NULL, pagesize, PROT_READ | PROT_WRITE, in run_with_zeropage()
1391 smem = mmap(NULL, pagesize, PROT_READ, MAP_PRIVATE | MAP_ANON, -1, 0); in run_with_zeropage()
1401 fn(mem, smem, pagesize); in run_with_zeropage()
1403 munmap(mem, pagesize); in run_with_zeropage()
1405 munmap(smem, pagesize); in run_with_zeropage()
1454 if (!pagemap_is_populated(pagemap_fd, mem + pagesize) || in run_with_huge_zeropage()
1455 !pagemap_is_populated(pagemap_fd, smem + pagesize)) { in run_with_huge_zeropage()
1481 if (fallocate(fd, 0, 0, pagesize)) { in run_with_memfd()
1487 mem = mmap(NULL, pagesize, PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0); in run_with_memfd()
1492 smem = mmap(NULL, pagesize, PROT_READ, MAP_SHARED, fd, 0); in run_with_memfd()
1502 fn(mem, smem, pagesize); in run_with_memfd()
1504 munmap(mem, pagesize); in run_with_memfd()
1506 munmap(smem, pagesize); in run_with_memfd()
1532 if (fallocate(fd, 0, 0, pagesize)) { in run_with_tmpfile()
1538 mem = mmap(NULL, pagesize, PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0); in run_with_tmpfile()
1543 smem = mmap(NULL, pagesize, PROT_READ, MAP_SHARED, fd, 0); in run_with_tmpfile()
1553 fn(mem, smem, pagesize); in run_with_tmpfile()
1555 munmap(mem, pagesize); in run_with_tmpfile()
1557 munmap(smem, pagesize); in run_with_tmpfile()
1685 pagesize = getpagesize(); in main()