uschindler commented on PR #13196: URL: https://github.com/apache/lucene/pull/13196#issuecomment-2014791894
I refactored the code a bit: - The POSIX constants are now part of PosixNativeAcess class - The abstract method madvise() now only takes a `MemorySegment` and the `IOContext`. So it is now the hook for native implementations to implement the "advise" given by the `IOContext` for the platform (POSIX, Windows, Maybe special case for Linux which has more constants if you use plain low-level non-posix MADVISE - I removed `OptionalInt`: The values are all small and are in the `valueOf` cache, so we just return null when no madvice is needed One thing: Should we remove the NoopNativeAccess class and just add a null check? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org