alloc_hugepages(2) System Calls Manual alloc_hugepages(2) NOMBRE alloc_hugepages, free_hugepages - asigna o libera paginas de gran tamano SINOPSIS void *syscall(SYS_alloc_hugepages, int key, void addr[.len], size_t len, int prot, int flag); int syscall(SYS_free_hugepages, void *addr); Note: glibc provides no wrappers for these system calls, necessitating the use of syscall(2). DESCRIPCION Las llamadas al sistema alloc_hugepages() y free_hugepages() fueron introducidas en Linux 2.5.36 y eliminadas de nuevo en la version 2.5.54. Existian solo para arquitecturas i386 e ia64 (cuando se compilaba con la opcion CONFIG_HUGETLB_PAGE). En Linux 2.4.20 existen los numeros de las llamadas al sistemas, pero las llamadas devuelven ENOSYS. En la arquitectura i386 el hardware de gestion de la memoria maneja paginas ordinarias (4 KiB) y paginas grandes (2 o 4 MiB). De manera similar, la arquitectura ia64 maneja paginas grandes de distintos tamanos. Estas llamadas al sistema sirven para ubicar paginas de gran tamano en la memoria del proceso o para liberarlas. Las paginas grandes estan fijas en memoria, y no son intercambiadas (swapped). El argumento key es un identificador. Cuando es cero las paginas son privadas, y no son heredadas por los hijos. Cuando es positivo las paginas son compartidas con otras aplicaciones usando el mismo identificador key, y heredadas por los procesos hijo. The addr argument of free_hugepages() tells which page is being freed: it was the return value of a call to alloc_hugepages(). (The memory is first actually freed when all users have released it.) The addr argument of alloc_hugepages() is a hint, that the kernel may or may not follow. Addresses must be properly aligned. El parametro len es la longitud del segmento requerido. Debe ser un multiplo del tamano de la pagina gigante. El parametro prot especifica la proteccion de memoria del segmento. Puede ser PROT_READ, PROT_WRITE o bien PROT_EXEC. The flag argument is ignored, unless key is positive. In that case, if flag is IPC_CREAT, then a new huge page segment is created when none with the given key existed. If this flag is not set, then ENOENT is returned when no segment with the given key exists. VALOR DEVUELTO En caso de exito, alloc_hugepages() devuelve la direccion virtual asignada, y free_hugepages() devuelve cero. En caso de error, se devuelve -1, y se define errno para indicar el tipo de error. ERRORES ENOSYS La llamada al sistema no esta soportada por este nucleo. ARCHIVOS /proc/sys/vm/nr_hugepages Numero de paginas hugetlb configuradas. Puede ser leido y escrito. /proc/meminfo Proporciona informacion del numero de paginas hugetlb configuradas y de su tamano en las tres variables HugePages_Total, HugePages_Free, Hugepagesize. ESTANDARES Linux on Intel processors. HISTORIAL These system calls are gone; they existed only in Linux 2.5.36 through to Linux 2.5.54. NOTAS Now the hugetlbfs filesystem can be used instead. Memory backed by huge pages (if the CPU supports them) is obtained by using mmap(2) to map files in this virtual filesystem. El numero maximo de paginas grandes puede especificarse usando el parametro hugepages= en el arranque. TRADUCCION La traduccion al espanol de esta pagina del manual fue creada por Miguel Perez Ibars y Marcos Fouces Esta traduccion es documentacion libre; lea la GNU General Public License Version 3 o posterior con respecto a las condiciones de copyright. No existe NINGUNA RESPONSABILIDAD. Si encuentra algun error en la traduccion de esta pagina del manual, envie un correo electronico a . Paginas de manual de Linux 6.06 31 Octubre 2023 alloc_hugepages(2)