Proposal for adding O_DIRECT support into JDK 9
Lu, Yingqi
yingqi.lu at intel.com
Mon Sep 11 16:10:27 UTC 2017
Hi Alan,
I will move the alignment checks to Util class.
One thing that has changed is that buffer utility methods have been added to IOUtil. I assume this is a mistake and you meant to add them to Util to go with the other buffer utility methods (IOUtil is for I/O methods of course).
Do you mean remove the validation from FileChannel, only do it in IOUtil? Or, you have another suggested location?
Related is that validation of the alignment is now done twice - once in the FileChannel read/write methods and again in IOUtil. As buffers are mutable then the alignment can only be done after taking a copy of the position + limit.
Thanks,
Lucy
From: Alan Bateman [mailto:Alan.Bateman at oracle.com]
Sent: Monday, September 11, 2017 4:21 AM
To: Lu, Yingqi <yingqi.lu at intel.com>
Cc: nio-dev at openjdk.java.net
Subject: Re: Proposal for adding O_DIRECT support into JDK 9
On 08/09/2017 21:41, Lu, Yingqi wrote:
Hi Brian,
Please find the most recent version of the patch at http://cr.openjdk.java.net/~kkharbas/8164900/webrev.09/<http://cr.openjdk.java.net/%7Ekkharbas/8164900/webrev.09/>
I've looked through the latest version.
One thing that has changed is that buffer utility methods have been added to IOUtil. I assume this is a mistake and you meant to add them to Util to go with the other buffer utility methods (IOUtil is for I/O methods of course).
Related is that validation of the alignment is now done twice - once in the FileChannel read/write methods and again in IOUtil. As buffers are mutable then the alignment can only be done after taking a copy of the position + limit.
Good to see that the native test has been integrated into the build.
-Alan.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/nio-dev/attachments/20170911/b4cc0372/attachment.html>
More information about the nio-dev
mailing list