Displaying 20 results from an estimated 38 matches for "x86_emul".
2008 Apr 21
1
[PATCH] x86-64: emulation support for cmpxchg16b
...tion pointer (making clear that if
implemented, it is to operate on two longs rather than two 32-bit
values). At the same time it fixes an apparently wrong emulator context
initialization in the shadow code.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Index: 2008-04-15/tools/tests/test_x86_emulator.c
===================================================================
--- 2008-04-15.orig/tools/tests/test_x86_emulator.c 2008-04-01 11:10:21.000000000 +0200
+++ 2008-04-15/tools/tests/test_x86_emulator.c 2008-04-15 08:48:15.000000000 +0200
@@ -74,7 +74,7 @@ static int cmpxchg(
return X86E...
2013 Aug 28
3
[PATCH] x86: AVX instruction emulation fixes
...uctions in order to
be able to actually run all the tests on the hardware I have)
- slightly tweak cpu_has_avx to more consistently express the outputs
we don''t care about (sinking them all into the same variable)
Signed-off-by: Jan Beulich <jbeulich@suse.com>
--- a/tools/tests/x86_emulator/test_x86_emulator.c
+++ b/tools/tests/x86_emulator/test_x86_emulator.c
@@ -94,13 +94,25 @@ static inline uint64_t xgetbv(uint32_t x
}
#define cpu_has_avx ({ \
- unsigned int eax = 1, ecx = 0, edx; \
- cpuid(&eax, &edx, &ecx, &edx, NULL); \
+ unsigned int eax = 1, ec...
2007 Dec 19
3
x86_emulate(): forgot to generate_exception_if() for 0xff?
Hi all,
In arch/x86/x86_emulate.c: x86_emulate():
1716 case 0xfe: /* Grp4 */
1717 generate_exception_if((m odrm_reg & 7) >= 2, EXC_UD);
1718 case 0xff: /* Grp5 */
1719 switch ( modrm_reg & 7 )
1720 {
1721 case 0: /* inc */
1722 emulate_1op(&quo...
2011 Nov 30
0
[PATCH 4/4] x86/emulator: cleanup
Utilize some of the additions in the prior patches to clean up other
code:
- keep track of REP prefixes in only one variable
- use REX_W in a few more places (instead of a literal number)
Signed-off-by: Jan Beulich <jbeulich@suse.com>
--- a/xen/arch/x86/x86_emulate/x86_emulate.c
+++ b/xen/arch/x86/x86_emulate/x86_emulate.c
@@ -304,6 +304,10 @@ union vex {
ptr[1] = rex | REX_PREFIX; \
} while (0)
+#define rep_prefix() (vex.pfx >= vex_f3)
+#define repe_prefix() (vex.pfx == vex_f3)
+#define repne_prefix() (vex.pfx == vex_f2)
+
/* Type, addr...
2008 Mar 17
12
[PATCH]Fix the bug of guest os installation failure and win2k boot failure
...patch is to fix the problem of Linux guest installation failure and Windows 2000 boot failure.
In the early code, we use vmx_vmexit_handler() -> vmx_io_instruction() function to emulate I/O instructions. But now, we use vmx_vmexit_handler() -> handle_mmio -> hvm_emulate_one() -> x86_emulate() to emulate I/O instructions. Also nowadays, the realmode emulation code walks through the path: vmx_realmode() -> realmode_emulate_one() -> hvm_emulate_one() -> x86_emulate().
The I/O handle code in x86_emulate() checks the cpl and iopl value, and if cpl > iopl, it will gene...
2011 Dec 15
10
fsincos emulation on AMD CPUs
All,
in the light of erratum #573 I''m wondering if we need to tweak or
conditionally suppress fsincos emulation. The question is whether there
is any possibility for getting the emulator to hit this instruction on AMD
(as no real mode emulation ought to be taking place there), i.e.
whether there are places where emulation gets continued eagerly
in anticipation of the need for emulation
2013 Nov 19
1
[PATCH] x86: fix emulation of indirect far calls and jumps
Commit 86781624 ("x86_emulate: PUSH <mem> must read source operand
just once") corrected the operands of those of the operations of opcode
extension group 5 that only read memory from SrcMem to DstMem, but
failed to also switch the use of "dst" here to "src".
Reported-by: Anthony Perard <an...
2007 Nov 27
1
build error with current (changeset 16475) xen-unstable tree
...c -fno-builtin -fno-common -iwithprefix include -Werror -Wno-pointer-arith -pipe -I/home/xen-unstable.hg/xen/include -I/home/xen-unstable.hg/xen/include/asm-x86/mach-generic -I/home/xen-unstable.hg/xen/include/asm-x86/mach-default -msoft-float -fno-stack-protector -DCONFIG_X86_PAE=1 -g -D__XEN__ -c x86_emulate.c -o x86_emulate.o
cc1: warnings being treated as errors
x86_emulate.c: In function âx86_emulateâ:
x86_emulate.c:2709: warning: âea.bytesâ is used uninitialized in this function
make[5]: *** [x86_emulate.o] Fehler 1
make[5]: Leaving directory `/home/xen-unstable.hg/xen/arch/x86''
make[4]...
2006 May 17
20
X86_emulate to be moved into qemu...
...mio. ;-)
In the process of solving this one, I''ve got to (another) of the
blocking points...
At the moment, we translate the virtual address from the guest in the
page-fault-handler to guest physical address via the gva_to_gpa()
function in svm.c/vmx.c: xxx_do_page_fault().
When using x86_emulate.c inside qemu, we''d need to feed in the virtual
address, but we also need to translate to (guest-)physical address. Any
hints or tricks for this, or do I need to read the page-table and get
the info that way [and CAN I even do that]? [And I''m sorry if this shows
my complete and...
2011 Nov 30
0
[PATCH 2/4] x86/emulator: add emulation of SIMD FP moves
Clone the existing movq emulation to also support the most fundamental
SIMD FP moves.
Extend the testing code to also exercise these instructions.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
--- a/tools/tests/x86_emulator/test_x86_emulator.c
+++ b/tools/tests/x86_emulator/test_x86_emulator.c
@@ -629,6 +629,60 @@ int main(int argc, char **argv)
else
printf("skipped\n");
+ printf("%-40s", "Testing movsd %xmm5,(%ecx)...");
+ memset(res, 0x77, 64);
+ memset(res...
2011 Nov 30
0
[PATCH 3/4] x86/emulator: properly handle lzcnt and tzcnt
These instructions are prefix selected flavors of bsf and bsr
respectively, and hence the presences of the F3 prefix must be handled
in the emulation code in order to avoid running into problems on newer
CPUs.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
--- a/xen/arch/x86/x86_emulate/x86_emulate.c
+++ b/xen/arch/x86/x86_emulate/x86_emulate.c
@@ -1058,6 +1058,9 @@ static bool_t vcpu_has(
return rc == X86EMUL_OKAY;
}
+#define vcpu_has_lzcnt() vcpu_has(0x80000001, ECX, 5, ctxt, ops)
+#define vcpu_has_bmi1() vcpu_has(0x00000007, EBX, 3, ctxt, ops)
+
#define vcpu_must...
2008 Jun 06
4
Query regarding x86_emulate_memop() function
Hi there,
I have a question regarding the functionality of x86_emulate_memop (Xen 3.1) or x86_emulate (Xen 3.2) function. This function gets called from sh_page_fault() function which is invoked when Xen receives a page fault.
Since I am not clear completely about the emulation operation performed by Xen, I have following questions with a below mentioned scenario?...
2008 Mar 13
0
printk: cc1 warnings being treated as errors
Hi,
I was trying to write printk statements in x86_emulate.c and I am getting
following error.
cc1: warnings being treated as errors
x86_emulate.c: In function ''x86_emulate'':
x86_emulate.c:2913: warning: ISO C90 forbids mixed declarations and code
x86_emulate.c:2939: warning: ISO C90 forbids mixed declarations and code
Yes, I know pr...
2008 Mar 13
0
printk: cc1 warnings being treated as errors
Hi,
I was trying to write printk statements in x86_emulate.c and I am getting
following error.
cc1: warnings being treated as errors
x86_emulate.c: In function ''x86_emulate'':
x86_emulate.c:2913: warning: ISO C90 forbids mixed declarations and code
x86_emulate.c:2939: warning: ISO C90 forbids mixed declarations and code
Yes, I know pr...
2012 Oct 02
18
[PATCH 0/3] x86: adjust entry frame generation
This set of patches converts the way frames gets created from
using PUSHes/POPs to using MOVes, thus allowing (in certain
cases) to avoid saving/restoring part of the register set.
While the place where the (small) win from this comes from varies
between CPUs, the net effect is a 1 to 2% reduction on a
combined interruption entry and exit when the full state save
can be avoided.
1: use MOV
2005 Nov 11
3
[PATCH] add MOVSX instr support to VMX MMIO decoder
Add MOVSX instr support to VMX MMIO decoder.
Signed-off-by: Xin Li <xin.b.li@intel.com>
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
2007 Feb 15
0
[PATCH] x86 emulation: suppress rep prefix handling on non-repeatable instructions
Otherwise, pause or the recommended one-byte ret workaround on AMD
processors may have ill side effects.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Index: 2007-02-07/xen/arch/x86/x86_emulate.c
===================================================================
--- 2007-02-07.orig/xen/arch/x86/x86_emulate.c 2007-02-08 08:46:39.000000000 +0100
+++ 2007-02-07/xen/arch/x86/x86_emulate.c 2007-02-08 09:32:00.000000000 +0100
@@ -1579,7 +1579,9 @@ x86_emulate(
if ( twobyte )
g...
2012 May 04
9
[hybrid]: unable to boot hvm due to eflags.ID
Hi guys,
At a loss trying to figure why
if (has_eflag(X86_EFLAGS_ID))
returns false in my HVM domU. Standard function has_eflag() in
cpucheck.c running in real mode. Works fine on PV dom0, but fails when
guest is booting on my hybrid dom0.
LMK if any ideas. I''ll keep digging in the manuals, but nothing so far.
thanks,
Mukesh
2008 Nov 20
10
issues with movnti emulation
We''ve got reports of that change causing HVM data corruption issues. While
I can''t see what''s wrong with the patch, I''d suggest at least reverting it from
the 3.3 tree (which is what our code is based upon) for the time being.
Jan
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
2011 Jan 31
9
[PATCH][SVM] Fix 32bit Windows guest VMs save/restore
The attached patch fixes the save/restore issue seen with 32bit Windows
guest VMs. The root cause is that current Xen doesn''t intercept
SYSENTER-related MSRs for 32bit guest VMs. As a result, the
guest_sysenter_xxx fields contain incorrect values and shouldn''t be used
for save/restore. This patch checks the LMA bit of EFER register in the
save/restore code path.
Please apply it