The branch is merged anyway, just in case any of the extra code used in it can be extracted later.
Fortune for collect's current commit: Future small blessing − 末小吉
# (This will very likely not happen unless you're specifically trying to make it happen, however.)
# (This will very likely not happen unless you're specifically trying to make it happen, however.)
memfile=["bitflags","lazy_static","stackalloc"]
memfile=["bitflags","lazy_static","stackalloc"]
# Use `MAP_HUGE` masks when needed or asked for.
# XXX: This cannot work for our use case as we do not map the fd, we splice() to it... It's entirely useless...
hugetlb=["memfile"]
# Check the conversion of kernel information into `MAP_HUGE` flags
#
# Usually only useful for debugging.
# XXX: See above
hugepage-checked-masks=["hugetlb"]
# `memfile`: When unable to determine the size of the input, preallocate the buffer to a multiple of the system page-size before writing to it. This can save extra `ftruncate()` calls, but will also result in the buffer needing to be truncated to the correct size at the end if the sizes as not matched.
# `memfile`: When unable to determine the size of the input, preallocate the buffer to a multiple of the system page-size before writing to it. This can save extra `ftruncate()` calls, but will also result in the buffer needing to be truncated to the correct size at the end if the sizes as not matched.
#
#
# *NOTE*: Requires `getpagesz()` to be available in libc.
# *NOTE*: Requires `getpagesz()` to be available in libc.
memfile-preallocate=["memfile"]
memfile-preallocate=["memfile"]
# Use jemalloc instead of system malloc.
# Use jemalloc instead of system malloc.
#
#
# Decreases memory-handling function calls, resulting in less "used" memory and faster allocation speeds at the "cost" of mapping a huge amount of virtual memory.
# Decreases memory-handling function calls, resulting in less "used" memory and faster allocation speeds at the "cost" of mapping a huge amount of virtual memory.
TODO: Is there a way we can set the size of `stdout` before exiting?
TODO: I dunno what `sealing` is, but maybe that can be used? Or, if not, a specific `fcntl()` call? Finding this out will allow consumers of `collect`'s output to use a single `splice()` instead of many, greatly improving its performance in pipelines as its output can be used like an actual file's...