All of lore.kernel.org
 help / color / mirror / Atom feed
* Is it safe to hvm_emulate_one() an MMX instruction?
@ 2013-04-17  9:30 Razvan Cojocaru
  2013-04-17 10:26 ` Jan Beulich
  0 siblings, 1 reply; 4+ messages in thread
From: Razvan Cojocaru @ 2013-04-17  9:30 UTC (permalink / raw)
  To: xen-devel

Hello,

assuming that RIP points to just before a MMX instruction (such as
'movdqu [some_address],xmm0'), is it safe to call hvm_emulate_one() in
the hypervisor? Are MMX instructions handled in a special manner?


Thanks,
Razvan Cojocaru

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Is it safe to hvm_emulate_one() an MMX instruction?
  2013-04-17  9:30 Is it safe to hvm_emulate_one() an MMX instruction? Razvan Cojocaru
@ 2013-04-17 10:26 ` Jan Beulich
  2013-04-17 10:40   ` Razvan Cojocaru
  0 siblings, 1 reply; 4+ messages in thread
From: Jan Beulich @ 2013-04-17 10:26 UTC (permalink / raw)
  To: Razvan Cojocaru; +Cc: xen-devel

>>> On 17.04.13 at 11:30, Razvan Cojocaru <rzvncj@gmail.com> wrote:
> assuming that RIP points to just before a MMX instruction (such as
> 'movdqu [some_address],xmm0'), is it safe to call hvm_emulate_one() in
> the hypervisor? Are MMX instructions handled in a special manner?

So do you mean an MMX instruction, or MOVDQU (which is an XMM
one)? In any event, 4.2 and later should be fine with this particular
instruction (and a few more move variants), but 4.1.x and earlier
won't be, nor does the emulator support the whole spectrum of
MMX, XMM, and AVX instructions.

Jan

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Is it safe to hvm_emulate_one() an MMX instruction?
  2013-04-17 10:26 ` Jan Beulich
@ 2013-04-17 10:40   ` Razvan Cojocaru
  2013-04-17 10:44     ` Jan Beulich
  0 siblings, 1 reply; 4+ messages in thread
From: Razvan Cojocaru @ 2013-04-17 10:40 UTC (permalink / raw)
  To: Jan Beulich; +Cc: xen-devel

> So do you mean an MMX instruction, or MOVDQU (which is an XMM
> one)? In any event, 4.2 and later should be fine with this particular
> instruction (and a few more move variants), but 4.1.x and earlier
> won't be, nor does the emulator support the whole spectrum of
> MMX, XMM, and AVX instructions.

In this particular case, MOVDQ, but I'm interested in all the mentioned
types of instructions.

What happens when a HVM guest tries to execute such an unsupported
instruction, via the hypervisor calling hvm_emulate_one()? Does
hvm_emulate_one() not return X86EMUL_OKAY - is testing for that enough?


Thanks,
Razvan Cojocaru

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Is it safe to hvm_emulate_one() an MMX instruction?
  2013-04-17 10:40   ` Razvan Cojocaru
@ 2013-04-17 10:44     ` Jan Beulich
  0 siblings, 0 replies; 4+ messages in thread
From: Jan Beulich @ 2013-04-17 10:44 UTC (permalink / raw)
  To: Razvan Cojocaru; +Cc: xen-devel

>>> On 17.04.13 at 12:40, Razvan Cojocaru <rzvncj@gmail.com> wrote:
>>  So do you mean an MMX instruction, or MOVDQU (which is an XMM
>> one)? In any event, 4.2 and later should be fine with this particular
>> instruction (and a few more move variants), but 4.1.x and earlier
>> won't be, nor does the emulator support the whole spectrum of
>> MMX, XMM, and AVX instructions.
> 
> In this particular case, MOVDQ, but I'm interested in all the mentioned
> types of instructions.
> 
> What happens when a HVM guest tries to execute such an unsupported
> instruction, via the hypervisor calling hvm_emulate_one()? Does
> hvm_emulate_one() not return X86EMUL_OKAY - is testing for that enough?

Supposedly yes.

Jan

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-04-17 10:44 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-17  9:30 Is it safe to hvm_emulate_one() an MMX instruction? Razvan Cojocaru
2013-04-17 10:26 ` Jan Beulich
2013-04-17 10:40   ` Razvan Cojocaru
2013-04-17 10:44     ` Jan Beulich

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.