This is the mail archive of the libc-help@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Missing <aio_misc.h> exported header ?



On 22/08/2019 08:53, Xavier Roche wrote:
> Dear glibc users,
> 
> The librt's <aio_misc.h> (which can be found in
> sysdeps/pthread/aio_misc.h) header file seems not to be exported as
> public header file (like <aio.h> is)
> 
> I was wondering if there was a reason behind this ?
> 
> The LIO_DSYNC/LIO_SYNC operations are implemented in glibc's librt and
> seem perfectly working (providing much better performances when
> syncing a lot of small files, specifically):
> 
> /* Extend the operation enum.  */
> enum
> {
>   LIO_DSYNC = LIO_READ + 1,
>   LIO_SYNC,
>   LIO_READ64 = LIO_READ | 128,
>   LIO_WRITE64 = LIO_WRITE | 128
> };
> 
> [ Also note that the sysdeps/generic/aio_misc.h version includes the
> erroneous LIO_DSYNC definition (b8744bea9bf, fix by Roland McGrath a
> long time ago) ]

Because it an internal-only implementation files.  The Linux one, for
instance, calls syscall directly using internal macros (INTERNAL_SYSCALL)
which are not meant to be exported.

The LIO_DSYNC/LIO_SYNC are used to call the internal __aio_enqueue_request,
external usage should use aio_fsync. By "providing much better performances when
> syncing a lot of small files" which exactly usage pattern are you referring? 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]