Hello<br><br><div class="gmail_quote">On Mon, Jan 23, 2012 at 2:34 PM, Zheng Da <span dir="ltr"><<a href="mailto:zhengda1936@gmail.com">zhengda1936@gmail.com</a>></span> wrote:<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="gmail_quote"><div class="im"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>
> I build XFS on the top of ramdisk. So yes, there is a lot of small<br>
> concurrent writes in a second.<br>
> I create a file of 4GB in XFS (the ramdisk has 5GB of space). My test<br>
> program overwrites 4G of data to the file and each time writes a page of<br>
> data randomly to the file. It's always overwriting, and no appending. The<br>
> offset of each write is always aligned to the page size. There is no<br>
> overlapping between writes.<br>
<br>
</div>Why are you using XFS for this? tmpfs was designed to do this sort<br>
of stuff as efficiently as possible....<br></blockquote></div><div>OK, I can try that. </div></div></blockquote><div>tmpfs doesn't support direct IO. </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="gmail_quote"><div class="im"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div><br>
> So the test case is pretty simple and I think it's easy to reproduce it.<br>
> It'll be great if you can try the test case.<br>
<br>
</div>Can you post your test code so I know what I test is exactly what<br>
you are running?<br></blockquote></div><div>I can do that. My test code gets very complicated now. I need to simplify it.</div></div></blockquote><div>Here is the code. It's still a bit long. I hope it's OK.</div>
<div>You can run the code like "rand-read file option=direct pages=1048576 threads=8 access=write/read".</div><div><br></div></div>Thanks,<div>Da</div>