[libc-commits] [libc] [libc][mmap] force offset to long for mmap2 (PR #96522)

via libc-commits libc-commits at lists.llvm.org
Mon Jun 24 15:40:50 PDT 2024


enh-google wrote:

> I don't think we quite need to provide mmap2 or mmap64 as symbols

we only have mmap64() for historical reasons (we had to retrofit `_FILE_OFFSET_BITS=64` pretty late), and i don't think anyone exposes mmap2().

(fwiw, musl _removed_ a their `_LARGEFILE64_SOURCE` junk recently. it didn't cause much trouble that i know of, and means that folks likely to have trouble have already had it :-) )

> and I don't think we should attempt to support kernels that lack mmap2

yeah, the toybox guy has a "seven year rule" -- https://landley.net/toybox/faq.html#support_horizon -- that i think is quite reasonable, but Linux 2.4 is _way_ beyond that :-)

https://github.com/llvm/llvm-project/pull/96522


More information about the libc-commits mailing list