* [PATCH] kvm: Add emulation for movups/movupd
@ 2018-04-01 15:54 Stefan Fritsch
2018-04-03 19:44 ` Radim Krčmář
2018-04-04 15:53 ` Paolo Bonzini
0 siblings, 2 replies; 9+ messages in thread
From: Stefan Fritsch @ 2018-04-01 15:54 UTC (permalink / raw)
To: Paolo Bonzini, Radim Krčmář,
Thomas Gleixner, Ingo Molnar, H. Peter Anvin, x86, kvm,
linux-kernel
Cc: Stefan Fritsch
This is very similar to the aligned versions movaps/movapd.
We have seen the corresponding emulation failures with openbsd as guest
and with Windows 10 with intel HD graphics pass through.
Signed-off-by: Christian Ehrhardt <christian_ehrhardt@genua.de>
Signed-off-by: Stefan Fritsch <sf@sfritsch.de>
---
arch/x86/kvm/emulate.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c
index d91eaeb01034..7dda8e38c19a 100644
--- a/arch/x86/kvm/emulate.c
+++ b/arch/x86/kvm/emulate.c
@@ -4498,6 +4498,10 @@ static const struct gprefix pfx_0f_2b = {
ID(0, &instr_dual_0f_2b), ID(0, &instr_dual_0f_2b), N, N,
};
+static const struct gprefix pfx_0f_10_0f_11 = {
+ I(Unaligned, em_mov), I(Unaligned, em_mov), N, N,
+};
+
static const struct gprefix pfx_0f_28_0f_29 = {
I(Aligned, em_mov), I(Aligned, em_mov), N, N,
};
@@ -4709,7 +4713,9 @@ static const struct opcode twobyte_table[256] = {
DI(ImplicitOps | Priv, invd), DI(ImplicitOps | Priv, wbinvd), N, N,
N, D(ImplicitOps | ModRM | SrcMem | NoAccess), N, N,
/* 0x10 - 0x1F */
- N, N, N, N, N, N, N, N,
+ GP(ModRM | DstReg | SrcMem | Mov | Sse, &pfx_0f_10_0f_11),
+ GP(ModRM | DstMem | SrcReg | Mov | Sse, &pfx_0f_10_0f_11),
+ N, N, N, N, N, N,
D(ImplicitOps | ModRM | SrcMem | NoAccess),
N, N, N, N, N, N, D(ImplicitOps | ModRM | SrcMem | NoAccess),
/* 0x20 - 0x2F */
--
2.11.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH] kvm: Add emulation for movups/movupd
2018-04-01 15:54 [PATCH] kvm: Add emulation for movups/movupd Stefan Fritsch
@ 2018-04-03 19:44 ` Radim Krčmář
2018-04-04 15:53 ` Paolo Bonzini
1 sibling, 0 replies; 9+ messages in thread
From: Radim Krčmář @ 2018-04-03 19:44 UTC (permalink / raw)
To: Stefan Fritsch
Cc: Paolo Bonzini, Thomas Gleixner, Ingo Molnar, H. Peter Anvin, x86,
kvm, linux-kernel
[The subject could mention "x86:" as well]
2018-04-01 17:54+0200, Stefan Fritsch:
> This is very similar to the aligned versions movaps/movapd.
>
> We have seen the corresponding emulation failures with openbsd as guest
> and with Windows 10 with intel HD graphics pass through.
>
> Signed-off-by: Christian Ehrhardt <christian_ehrhardt@genua.de>
> Signed-off-by: Stefan Fritsch <sf@sfritsch.de>
> ---
Nicely follows the implementation of aligned variants,
Reviewed-by: Radim Krčmář <rkrcmar@redhat.com>
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] kvm: Add emulation for movups/movupd
2018-04-01 15:54 [PATCH] kvm: Add emulation for movups/movupd Stefan Fritsch
2018-04-03 19:44 ` Radim Krčmář
@ 2018-04-04 15:53 ` Paolo Bonzini
2018-04-04 17:10 ` Konrad Rzeszutek Wilk
1 sibling, 1 reply; 9+ messages in thread
From: Paolo Bonzini @ 2018-04-04 15:53 UTC (permalink / raw)
To: Stefan Fritsch, Radim Krčmář,
Thomas Gleixner, Ingo Molnar, H. Peter Anvin, x86, kvm,
linux-kernel
On 01/04/2018 17:54, Stefan Fritsch wrote:
> This is very similar to the aligned versions movaps/movapd.
>
> We have seen the corresponding emulation failures with openbsd as guest
> and with Windows 10 with intel HD graphics pass through.
>
> Signed-off-by: Christian Ehrhardt <christian_ehrhardt@genua.de>
> Signed-off-by: Stefan Fritsch <sf@sfritsch.de>
> ---
> arch/x86/kvm/emulate.c | 8 +++++++-
> 1 file changed, 7 insertions(+), 1 deletion(-)
>
> diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c
> index d91eaeb01034..7dda8e38c19a 100644
> --- a/arch/x86/kvm/emulate.c
> +++ b/arch/x86/kvm/emulate.c
> @@ -4498,6 +4498,10 @@ static const struct gprefix pfx_0f_2b = {
> ID(0, &instr_dual_0f_2b), ID(0, &instr_dual_0f_2b), N, N,
> };
>
> +static const struct gprefix pfx_0f_10_0f_11 = {
> + I(Unaligned, em_mov), I(Unaligned, em_mov), N, N,
> +};
> +
> static const struct gprefix pfx_0f_28_0f_29 = {
> I(Aligned, em_mov), I(Aligned, em_mov), N, N,
> };
> @@ -4709,7 +4713,9 @@ static const struct opcode twobyte_table[256] = {
> DI(ImplicitOps | Priv, invd), DI(ImplicitOps | Priv, wbinvd), N, N,
> N, D(ImplicitOps | ModRM | SrcMem | NoAccess), N, N,
> /* 0x10 - 0x1F */
> - N, N, N, N, N, N, N, N,
> + GP(ModRM | DstReg | SrcMem | Mov | Sse, &pfx_0f_10_0f_11),
> + GP(ModRM | DstMem | SrcReg | Mov | Sse, &pfx_0f_10_0f_11),
> + N, N, N, N, N, N,
> D(ImplicitOps | ModRM | SrcMem | NoAccess),
> N, N, N, N, N, N, D(ImplicitOps | ModRM | SrcMem | NoAccess),
> /* 0x20 - 0x2F */
>
Applied, thanks.
Paolo
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] kvm: Add emulation for movups/movupd
2018-04-04 15:53 ` Paolo Bonzini
@ 2018-04-04 17:10 ` Konrad Rzeszutek Wilk
2018-04-04 17:24 ` Paolo Bonzini
0 siblings, 1 reply; 9+ messages in thread
From: Konrad Rzeszutek Wilk @ 2018-04-04 17:10 UTC (permalink / raw)
To: Paolo Bonzini
Cc: Stefan Fritsch, Radim Krčmář,
Thomas Gleixner, Ingo Molnar, H. Peter Anvin, x86, kvm,
linux-kernel
On Wed, Apr 04, 2018 at 05:53:04PM +0200, Paolo Bonzini wrote:
> On 01/04/2018 17:54, Stefan Fritsch wrote:
> > This is very similar to the aligned versions movaps/movapd.
..snip..
> Applied, thanks.
Should there be a corresponding test-case?
>
> Paolo
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] kvm: Add emulation for movups/movupd
2018-04-04 17:10 ` Konrad Rzeszutek Wilk
@ 2018-04-04 17:24 ` Paolo Bonzini
2018-04-04 17:35 ` Stefan Fritsch
0 siblings, 1 reply; 9+ messages in thread
From: Paolo Bonzini @ 2018-04-04 17:24 UTC (permalink / raw)
To: Konrad Rzeszutek Wilk
Cc: Stefan Fritsch, Radim Krčmář,
Thomas Gleixner, Ingo Molnar, H. Peter Anvin, x86, kvm,
linux-kernel
On 04/04/2018 19:10, Konrad Rzeszutek Wilk wrote:
> On Wed, Apr 04, 2018 at 05:53:04PM +0200, Paolo Bonzini wrote:
>> On 01/04/2018 17:54, Stefan Fritsch wrote:
>>> This is very similar to the aligned versions movaps/movapd.
> ..snip..
>> Applied, thanks.
> Should there be a corresponding test-case?
Good point! Stefan, could you write one?
Thanks,
Paolo
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] kvm: Add emulation for movups/movupd
2018-04-04 17:24 ` Paolo Bonzini
@ 2018-04-04 17:35 ` Stefan Fritsch
2018-04-05 5:44 ` Paolo Bonzini
0 siblings, 1 reply; 9+ messages in thread
From: Stefan Fritsch @ 2018-04-04 17:35 UTC (permalink / raw)
To: Paolo Bonzini
Cc: Konrad Rzeszutek Wilk, Radim Krčmář,
Thomas Gleixner, Ingo Molnar, H. Peter Anvin, x86, kvm,
linux-kernel
On Wednesday, 4 April 2018 19:24:20 CEST Paolo Bonzini wrote:
> On 04/04/2018 19:10, Konrad Rzeszutek Wilk wrote:
> > Should there be a corresponding test-case?
>
> Good point! Stefan, could you write one?
Is there infrastructure for such tests? If yes, can you give me a pointer to
it?
Cheers,
Stefan
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] kvm: Add emulation for movups/movupd
2018-04-04 17:35 ` Stefan Fritsch
@ 2018-04-05 5:44 ` Paolo Bonzini
2021-01-12 23:47 ` Jim Mattson
0 siblings, 1 reply; 9+ messages in thread
From: Paolo Bonzini @ 2018-04-05 5:44 UTC (permalink / raw)
To: Stefan Fritsch
Cc: Konrad Rzeszutek Wilk, Radim Krčmář,
Thomas Gleixner, Ingo Molnar, H. Peter Anvin, x86, kvm,
linux-kernel
On 04/04/2018 19:35, Stefan Fritsch wrote:
> On Wednesday, 4 April 2018 19:24:20 CEST Paolo Bonzini wrote:
>> On 04/04/2018 19:10, Konrad Rzeszutek Wilk wrote:
>>> Should there be a corresponding test-case?
>>
>> Good point! Stefan, could you write one?
>
> Is there infrastructure for such tests? If yes, can you give me a pointer to
> it?
Yes, check out x86/emulator.c in
https://git.kernel.org/pub/scm/virt/kvm/kvm-unit-tests.git. There is
already a movaps test.
Paolo
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] kvm: Add emulation for movups/movupd
2018-04-05 5:44 ` Paolo Bonzini
@ 2021-01-12 23:47 ` Jim Mattson
2021-01-15 8:56 ` Stefan Fritsch
0 siblings, 1 reply; 9+ messages in thread
From: Jim Mattson @ 2021-01-12 23:47 UTC (permalink / raw)
To: Paolo Bonzini
Cc: Stefan Fritsch, Konrad Rzeszutek Wilk,
Radim Krčmář,
Thomas Gleixner, Ingo Molnar, H. Peter Anvin,
the arch/x86 maintainers, kvm list, LKML
On Wed, Apr 4, 2018 at 10:44 PM Paolo Bonzini <pbonzini@redhat.com> wrote:
>
> On 04/04/2018 19:35, Stefan Fritsch wrote:
> > On Wednesday, 4 April 2018 19:24:20 CEST Paolo Bonzini wrote:
> >> On 04/04/2018 19:10, Konrad Rzeszutek Wilk wrote:
> >>> Should there be a corresponding test-case?
> >>
> >> Good point! Stefan, could you write one?
> >
> > Is there infrastructure for such tests? If yes, can you give me a pointer to
> > it?
>
> Yes, check out x86/emulator.c in
> https://git.kernel.org/pub/scm/virt/kvm/kvm-unit-tests.git. There is
> already a movaps test.
Whatever became of this unit test? I don't see it in the
kvm-unit-tests repository.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] kvm: Add emulation for movups/movupd
2021-01-12 23:47 ` Jim Mattson
@ 2021-01-15 8:56 ` Stefan Fritsch
0 siblings, 0 replies; 9+ messages in thread
From: Stefan Fritsch @ 2021-01-15 8:56 UTC (permalink / raw)
To: Jim Mattson, Paolo Bonzini
Cc: Konrad Rzeszutek Wilk, Radim Krčmář,
Thomas Gleixner, Ingo Molnar, H. Peter Anvin,
the arch/x86 maintainers, kvm list, LKML
Am 13.01.21 um 00:47 schrieb Jim Mattson:
> On Wed, Apr 4, 2018 at 10:44 PM Paolo Bonzini <pbonzini@redhat.com> wrote:
>>
>> On 04/04/2018 19:35, Stefan Fritsch wrote:
>>> On Wednesday, 4 April 2018 19:24:20 CEST Paolo Bonzini wrote:
>>>> On 04/04/2018 19:10, Konrad Rzeszutek Wilk wrote:
>>>>> Should there be a corresponding test-case?
>>>>
>>>> Good point! Stefan, could you write one?
>>>
>>> Is there infrastructure for such tests? If yes, can you give me a pointer to
>>> it?
>>
>> Yes, check out x86/emulator.c in
>> https://git.kernel.org/pub/scm/virt/kvm/kvm-unit-tests.git. There is
>> already a movaps test.
>
> Whatever became of this unit test? I don't see it in the
> kvm-unit-tests repository.
>
Sorry, I did not get around to doing this. And it is unlikely that I
will have time to do it in the near future.
Cheers,
Stefan
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2021-01-15 9:22 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-01 15:54 [PATCH] kvm: Add emulation for movups/movupd Stefan Fritsch
2018-04-03 19:44 ` Radim Krčmář
2018-04-04 15:53 ` Paolo Bonzini
2018-04-04 17:10 ` Konrad Rzeszutek Wilk
2018-04-04 17:24 ` Paolo Bonzini
2018-04-04 17:35 ` Stefan Fritsch
2018-04-05 5:44 ` Paolo Bonzini
2021-01-12 23:47 ` Jim Mattson
2021-01-15 8:56 ` Stefan Fritsch
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).