<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Fri, Jun 30, 2017 at 5:39 PM, Rafael Avila de Espindola <span dir="ltr"><<a href="mailto:rafael.espindola@gmail.com" target="_blank">rafael.espindola@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">Rafael Avila de Espindola <<a href="mailto:rafael.espindola@gmail.com">rafael.espindola@gmail.com</a>> writes:<br>
<br>
> LGTM<br>
><br>
> FileOutputBuffer has something similar, so this is all that we have to<br>
> do.<br>
><br>
> It is a pity that we have to unlink at all. I will do a quick benchmark<br>
> to see if rename without unlink is still slow.<br>
<br>
</span>There doesn't seem to be any way of avoiding the cost.<br>
<br>
What I tried was<br>
<br>
* Renaming without unlink: the rename is slow.<br>
* Opening the file. This makes rename/unlink fast, but close is slow.<br>
* Not calling close, the process exit is slow.<br></blockquote><div><br></div><div>That was my observation too. This is an ugly hack, but there seems to be no way to circumvent the performance issue of the kernel filesystem. </div></div></div></div>