<div dir="ltr"><div class="gmail_quote"><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">I do not<span class="gmail_default" style="font-size:small"> </span>think that it's a good idea to pass ~100MB buffer to a single write()<br>
and expect it to succeed anyways.<br></blockquote><div><br></div><div><div class="gmail_default" style="font-size:small">I suddenly realized that it is 1MB buffer but not 100MB, so that block number</div><div class="gmail_default" style="font-size:small">is not the key point for OOM.</div></div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">1 Block == 4k on x86_64, </div><div class="gmail_default" style="font-size:small">256 * 4k == 1024kB == 1MB</div></div><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div>Regards,<br></div><div>Li Wang<br></div></div></div></div>