[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] x86/pv: Minor improvements to guest_get_eff_{, kern}_l1e()



>>> On 24.08.17 at 13:13, <andrew.cooper3@xxxxxxxxxx> wrote:
> On 24/08/17 09:44, Jan Beulich wrote:
>>  >>> On 23.08.17 at 21:09, <andrew.cooper3@xxxxxxxxxx> wrote:
>>> * These functions work in terms of linear addresses, not virtual addresses.
>>>    Update the comments and parameter names.
>>>  * Drop unnecessary inlines.
>>>  * Drop vcpu parameter from guest_get_eff_kern_l1e().  Its sole caller 
>>> passes
>>>    current, and its callee strictly operates on current.
>> I'm not entirely convinced of this part, as I think the intention was
>> to save the re-latching of "current", but anyway:
> 
> It'll be inlined anyway, given a sole caller.

But the inlining won't help with the re-fetching; the compiler can't
know it can re-use the earlier fetched value.

> We could have struct vcpu *curr as a parameter if you prefer, but having
> just a plain v gives the false impression it can be used with something
> other than current.

That would be an option, yes, but as said, the problem is minor
enough for the patch to be good as is.

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.