On Sun, Aug 16, 2015 at 06:51:33AM -0500, Eric W. Biederman wrote: > It occurs to me that there is a fairly simple way we can emperically > test to see how expensive calling is_subdir for every .. on a bind mount > is in practice. > > - Take my last patch > - run a benchmark outside of a bind mount (perhaps a kernel compile). > - run the same benchmark inside of a bind mount. > > See if the performance differs. > > I am going to try to find time to do this, but I am travelling for the > next couple of days. > > If someone who has a bit more time wants to try it and beats me to that > would be great. > > I think having some emperical numbers would be nice in this part of the > conversation. I took a bit of time to do something simpler though less scientific : I just ran a kernel build under strace -c -f to get a rough idea of the number of syscalls. It takes 2m23 without strace and 3m00 under strace. 7.2M syscalls were seen out of which only 3.2M were related to FS access (mostly open(), fstat() and stat()), the rest is minor. That's 22k syscalls per second, or 45 us between two syscalls. From this point I'm having a hard time imagining that any extra tests in the code path would have a significant impact to cause a measurable difference compared to these 45us, especially since I'm counting all FS accesses (worst case) and not just those referencing "..". Just my two cents, Willy -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html