Home | History | Annotate | Download | only in unit
      1 #include "test/jemalloc_test.h"
      2 
      3 TEST_BEGIN(test_pages_huge)
      4 {
      5 	bool commit;
      6 	void *pages;
      7 
      8 	commit = true;
      9 	pages = pages_map(NULL, PAGE, &commit);
     10 	assert_ptr_not_null(pages, "Unexpected pages_map() error");
     11 
     12 	assert_false(pages_huge(pages, PAGE),
     13 	    "Unexpected pages_huge() result");
     14 	assert_false(pages_nohuge(pages, PAGE),
     15 	    "Unexpected pages_nohuge() result");
     16 
     17 	pages_unmap(pages, PAGE);
     18 }
     19 TEST_END
     20 
     21 int
     22 main(void)
     23 {
     24 
     25 	return (test(
     26 	    test_pages_huge));
     27 }
     28