Andi Kleen <andi@xxxxxxxxxxxxxx> wrote: > > Only I can guess for that reason is the reduction of some function calls > > by inlining some functions. > > Yes once at a time cfu was inline too and just checked for the right > sizes and the used g*u, but it got lost in the "icache over everything else" mania which is unfortunately en vogue for quite some time in kernel land (aka > measuring patches only based on their impact on the .text > size, not the actual performance) > > But you might getter better gains by fixing this general > c*u() regression. > What I mentioned was about not only cfu but 3 functions. Originally, we were doing the following function calls: walk_addr_generic() ---1 kvm_read_guest_page_mmu() ---2 kvm_read_guest_page() ---3 copy_from_user() ---4 And now, with my patch already applied, we are not using generic kvm_read_guest_page_mmu() and some address calculations are done in walk_addr_generic(): walk_addr_generic() ---1' get_user() ---2' The length is passed in from walk_addr_generic(). Do you think the following case would not differ so much from (1' 2') ? walk_addr_generic() ---1'' copy_from_user() ---2'' This can satisfy your "assuming you pass in a constant length" and almost same as get_user() ? Takuya -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html