**random**
Advise using **FADV_RANDOM**.
+ **noreuse**
+ Advise using **FADV_NOREUSE**. This may be a no-op on older Linux
+ kernels. Since Linux 6.3, it provides a hint to the LRU algorithm.
+ See the :manpage:`posix_fadvise(2)` man page.
+
.. option:: write_hint=str
Use :manpage:`fcntl(2)` to advise the kernel what life time to expect
.TP
.B random
Advise using FADV_RANDOM.
+.TP
+.B noreuse
+Advise using FADV_NOREUSE. This may be a no-op on older Linux
+kernels. Since Linux 6.3, it provides a hint to the LRU algorithm.
+See the \fBposix_fadvise\fR\|(2) man page.
.RE
.RE
.TP
F_ADV_TYPE,
F_ADV_RANDOM,
F_ADV_SEQUENTIAL,
+ F_ADV_NOREUSE,
};
/*
flags = POSIX_FADV_RANDOM;
else if (td->o.fadvise_hint == F_ADV_SEQUENTIAL)
flags = POSIX_FADV_SEQUENTIAL;
+#ifdef POSIX_FADV_NOREUSE
+ else if (td->o.fadvise_hint == F_ADV_NOREUSE)
+ flags = POSIX_FADV_NOREUSE;
+#endif
else {
log_err("fio: unknown fadvise type %d\n",
td->o.fadvise_hint);
#include <ctype.h>
#include <string.h>
#include <assert.h>
+#include <fcntl.h>
#include <sys/stat.h>
#include <netinet/in.h>
.oval = F_ADV_SEQUENTIAL,
.help = "Advise using FADV_SEQUENTIAL",
},
+#ifdef POSIX_FADV_NOREUSE
+ { .ival = "noreuse",
+ .oval = F_ADV_NOREUSE,
+ .help = "Advise using FADV_NOREUSE",
+ },
+#endif
},
.help = "Use fadvise() to advise the kernel on IO pattern",
.def = "1",