logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

memkind_fixed - memkind operations on user-defined memory.

Description

       The fixed memory memkind operations enable memory kinds built on user-defined memory.   Such  memory  may
       have different attributes, depending on how the memory mapping was created.

       The fixed kinds are most useful when a specific memory characteristics, e.g.  numa binding, which are not
       fully supported by other memkind API, need to be manipulated.

       The most convenient way to create fixed kinds is to use memkind_create_fixed() (see memkind(3)).

       memkind_fixed_create()  is an implementation of the memkind "create" operation for kinds that are created
       on the memory area supplied by the user.  It allocates space for some fixed-kind-specific metadata,  then
       calls memkind_arena_create() (see memkind_arena(3))

       memkind_fixed_destroy()  is  an  implementation  of  the  memkind  "destroy" operation for kinds that are
       created on the memory area supplied by the user.   This  releases  all  of  the  resources  allocated  by
       memkind_fixed_create() , but please note that it does not de-allocate the underlying memory.

       memkind_fixed_mmap()  allocates the file system space for a block of size bytes in the memory-mapped file
       associated with given kind.  The addr hint is ignored.  The return value is the address of mapped  memory
       region or MAP_FAILED in the case of an error.

       COPYRIGHT
              Copyright (C) 2021 Intel Corporation. All rights reserved.

Name

       memkind_fixed - memkind operations on user-defined memory.
       Note:  This  is  EXPERIMENTAL API. The functionality and the header file itself can be changed (including
       non-backward compatible changes) or removed.

See Also

memkind(3),   memkind_arena(3),   memkind_default(3),   memkind_hbw(3),  memkind_hugetlb(3),  libvmem(3),
       jemalloc(3), mbind(2), mmap(2)

Intel Corporation                                  2021-12-08                                   MEMKIND_FIXED(3)

Synopsis

intmemkind_fixed_create(structmemkind*kind,structmemkind_ops*ops,constchar*name);intmemkind_fixed_destroy(structmemkind*kind);void*memkind_fixed_mmap(structmemkind*kind,void*addr,size_tsize);

See Also