https://github.com/Singular/Sources
Tip revision: 35c6e2c47bae1f858ec6f4a0cdab911b80a1c383 authored by Hans Schoenemann on 22 January 2021, 14:55:14 UTC
fix: map Z, Zn ->Zp, mpz_z ->Zp
fix: map Z, Zn ->Zp, mpz_z ->Zp
Tip revision: 35c6e2c
omGetPageSize.h
/*******************************************************************
* File: omGetPageSize.h
* Purpose: figure out how to get the pagesize
* This is adapted from dlmalloc's mechanisms which in fact derived it from
* bsd/gnu getpagesize.h
*******************************************************************/
#include <unistd.h>
#ifndef omalloc_getpagesize
# ifdef _SC_PAGESIZE /* some SVR4 systems omit an underscore */
# ifndef _SC_PAGE_SIZE
# define _SC_PAGE_SIZE _SC_PAGESIZE
# endif
# endif
# ifdef _SC_PAGE_SIZE
# define omalloc_getpagesize sysconf(_SC_PAGE_SIZE)
# else
# if defined(BSD) || defined(DGUX) || defined(HAVE_GETPAGESIZE)
extern size_t getpagesize();
# define omalloc_getpagesize getpagesize()
# else
# include <sys/param.h>
# ifdef EXEC_PAGESIZE
# define omalloc_getpagesize EXEC_PAGESIZE
# else
# ifdef NBPG
# ifndef CLSIZE
# define omalloc_getpagesize NBPG
# else
# define omalloc_getpagesize (NBPG * CLSIZE)
# endif
# else
# ifdef NBPC
# define omalloc_getpagesize NBPC
# else
# ifdef PAGESIZE
# define omalloc_getpagesize PAGESIZE
# else
# define omalloc_getpagesize (4096) /* just guess */
# endif
# endif
# endif
# endif
# endif
# endif
#endif