.\" -*- coding: UTF-8 -*- .\" Copyright (C) 2001 Andries Brouwer .\" .\" %%%LICENSE_START(VERBATIM) .\" Permission is granted to make and distribute verbatim copies of this .\" manual provided the copyright notice and this permission notice are .\" preserved on all copies. .\" .\" Permission is granted to copy and distribute modified versions of this .\" manual under the conditions for verbatim copying, provided that the .\" entire resulting derived work is distributed under the terms of a .\" permission notice identical to this one. .\" .\" Since the Linux kernel and libraries are constantly changing, this .\" manual page may be incorrect or out-of-date. The author(s) assume no .\" responsibility for errors or omissions, or for damages resulting from .\" the use of the information contained herein. The author(s) may not .\" have taken the same level of care in the production of this manual, .\" which is licensed free of charge, as they might when working .\" professionally. .\" .\" Formatted or processed versions of this manual, if unaccompanied by .\" the source, must acknowledge the copyright and authors of this work. .\" %%%LICENSE_END .\" .\"******************************************************************* .\" .\" This file was generated with po4a. Translate the source file. .\" .\"******************************************************************* .TH GETPAGESIZE 2 "15 Septiembre 2017" Linux "Manual del Programador de Linux" .SH NOMBRE getpagesize \- obtiene el tamaño de página de memoria .SH SINOPSIS \fB#include \fP .PP \fBint getpagesize(void);\fP .PP .RS -4 Requisitos de Macros de Prueba de Características para glibc (véase \fBfeature_test_macros\fP(7)): .RE .PP \fBgetpagesize\fP(): .ad l .RS 4 .PD 0 .TP 4 Desde glibc 2.19: .nf _DEFAULT_SOURCE || ! (_POSIX_C_SOURCE\ >=\ 200112L) .fi .TP 4 From glibc 2.12 to 2.19: .nf _BSD_SOURCE || ! (_POSIX_C_SOURCE\ >=\ 200112L) .fi .TP 4 Antes de glibc 2.12: .\" || _XOPEN_SOURCE\ &&\ _XOPEN_SOURCE_EXTENDED _BSD_SOURCE || _XOPEN_SOURCE\ >=\ 500 .PD .RE .ad b .SH DESCRIPCIÓN .\" .SH HISTORY .\" This call first appeared in 4.2BSD. The function \fBgetpagesize\fP() returns the number of bytes in a memory page, where "page" is a fixed\-length block, the unit for memory allocation and file mapping performed by \fBmmap\fP(2). .SH "CONFORME A" SVr4, 4.4BSD, SUSv2. En SUSv2 la llamada \fBgetpagesize\fP() está etiquetada como "LEGACY", y en POSIX.1\-2001 ha sido eliminada. HP\-UX no posee esta llamada. .SH NOTAS Portable applications should employ \fIsysconf(_SC_PAGESIZE)\fP instead of \fBgetpagesize\fP(): .PP .in +4n .EX #include long sz = sysconf(_SC_PAGESIZE); .EE .in .PP (Most systems allow the synonym \fB_SC_PAGE_SIZE\fP for \fB_SC_PAGESIZE\fP.) .PP Whether \fBgetpagesize\fP() is present as a Linux system call depends on the architecture. If it is, it returns the kernel symbol \fBPAGE_SIZE\fP, whose value depends on the architecture and machine model. Generally, one uses binaries that are dependent on the architecture but not on the machine model, in order to have a single binary distribution per architecture. This means that a user program should not find \fBPAGE_SIZE\fP at compile time from a header file, but use an actual system call, at least for those architectures (like sun4) where this dependency exists. Here glibc 2.0 fails because its \fBgetpagesize\fP() returns a statically derived value, and does not use a system call. Things are OK in glibc 2.1. .SH "VÉASE TAMBIÉN" \fBmmap\fP(2), \fBsysconf\fP(3) .SH COLOFÓN Esta página es parte de la versión 5.10 del proyecto Linux \fIman\-pages\fP. Puede encontrar una descripción del proyecto, información sobre cómo informar errores y la última versión de esta página en \%https://www.kernel.org/doc/man\-pages/. .SH TRADUCCIÓN La traducción al español de esta página del manual fue creada por Miguel Pérez Ibars . Esta traducción es documentación libre; lea la .UR https://www.gnu.org/licenses/gpl-3.0.html GNU General Public License Version 3 .UE o posterior con respecto a las condiciones de copyright. No existe NINGUNA RESPONSABILIDAD. Si encuentra algún error en la traducción de esta página del manual, envíe un correo electrónico a .MT debian-l10n-spanish@lists.debian.org>. .ME .