Implementing /bin/ionice, ioprio_set() support with FILE_IO_PRIORITY_HINT_INFO?

Martin Wege martin.l.wege@gmail.com
Wed Apr 3 01:51:37 GMT 2024


Hello,

could Cygwin implement support for /usr/bin/ionice and ioprio_set()
via FILE_IO_PRIORITY_HINT_INFO?

So basically implement ioprio_set() to store the value per process,
and for each file open() call this:

FILE_IO_PRIORITY_HINT_INFO priorityHint={0};
priorityHint.PriorityHint = ioniceprio2WinIoPriorityHint(ioniceprio);
result = SetFileInformationByHandle( hFile,
                                     FileIoPriorityHintInfo,
                                     &priorityHint,
                                     sizeof(PriorityHint));

NTFS and ReFS support FILE_IO_PRIORITY_HINT_INFO

Thanks,
Martin


More information about the Cygwin mailing list