Re: [PATCH] KVM: emulator: drop unneeded call to get_segment()

2012-07-26 Thread Avi Kivity
On 07/25/2012 03:49 PM, Gleb Natapov wrote: setup_syscalls_segments() calls get_segment() and than overwrites all but one of the structure fields and this one should also be overwritten anyway, so we can drop call to get_segment() and avoid a couple of vmreads on vmx. Also drop zeroing ss/cs

[PATCH] KVM: emulator: drop unneeded call to get_segment()

2012-07-25 Thread Gleb Natapov
setup_syscalls_segments() calls get_segment() and than overwrites all but one of the structure fields and this one should also be overwritten anyway, so we can drop call to get_segment() and avoid a couple of vmreads on vmx. Also drop zeroing ss/cs structures since most of the fields are set