<div dir="ltr">Hi,<br><br>ZipFile.Source.readFullyAt caps its calls to RandomAccessFile.readFully to a maximum of 8192 bytes per call, like this:<br><br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">int N = len;<br>while (N > 0) {<br>    int n = Math.min(BUF_SIZE, N);<br>    zfile.readFully(buf, off, n);<br>    off += n;<br>    N -= n;<br>}</blockquote><div><br></div><div>I'm observing a ~10% speedup of the ZipFileOpen micro when I replace the above with simply:</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">zfile.seek(pos);<br>zfile.readFully(buf, off, len);</blockquote><div><br></div><div>Does anyone know why readFullyAt is implemented this way? Is it trying to limit blocking time somehow? Is there some hidden buffering deeper down I'm not seeing?</div><div><br></div><div>If this is safe to remove, I'm happy to submit a PR. But code like this is usually there for a reason..?</div><div><br></div><div>Cheers,</div><div>Eiirk.</div></div>