RFR: 6980847: (fs) Files.copy needs to be tuned [v2]

Brian Burkhalter bpb at openjdk.java.net
Wed Jun 15 16:00:16 UTC 2022


> Modify `UnixCopyFile.copyFile()` to set the transfer size to the least common multiple of the source and destination file block sizes if the block sizes are not equal. Modify `WindowsFileCopy.copy()` to set `COPY_FILE_NO_BUFFERING` in the flags passed to `CopyFileEx()` if the size of the transfer is greater than a threshold.

Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision:

  6980847: 1) use UnixFileStoreAttributes.get(file).blockSize(); 2) use @Native instead of transferSize0()

-------------

Changes:
  - all: https://git.openjdk.org/jdk/pull/9161/files
  - new: https://git.openjdk.org/jdk/pull/9161/files/ce276522..f151dc4c

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=9161&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=9161&range=00-01

  Stats: 24 lines in 2 files changed: 4 ins; 13 del; 7 mod
  Patch: https://git.openjdk.org/jdk/pull/9161.diff
  Fetch: git fetch https://git.openjdk.org/jdk pull/9161/head:pull/9161

PR: https://git.openjdk.org/jdk/pull/9161


More information about the nio-dev mailing list