|
From: <sv...@va...> - 2006-08-28 18:09:48
|
Author: sewardj
Date: 2006-08-28 19:09:46 +0100 (Mon, 28 Aug 2006)
New Revision: 6034
Log:
Regtest for #132813 (Assertion at priv/guest-x86/toIR.c:652 fails)
Added:
trunk/none/tests/x86/bug132813-x86.c
trunk/none/tests/x86/bug132813-x86.stderr.exp
trunk/none/tests/x86/bug132813-x86.stdout.exp
trunk/none/tests/x86/bug132813-x86.vgtest
Modified:
trunk/none/tests/x86/Makefile.am
Modified: trunk/none/tests/x86/Makefile.am
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/none/tests/x86/Makefile.am 2006-08-28 13:36:52 UTC (rev 6033)
+++ trunk/none/tests/x86/Makefile.am 2006-08-28 18:09:46 UTC (rev 6034)
@@ -8,6 +8,7 @@
badseg.stderr.exp badseg.stdout.exp badseg.vgtest \
bt_everything.stderr.exp bt_everything.stdout.exp bt_everything.vgtest =
\
bt_literal.stderr.exp bt_literal.stdout.exp bt_literal.vgtest \
+ bug132813-x86.stderr.exp bug132813-x86.stdout.exp bug132813-x86.vgtest =
\
cpuid.stderr.exp cpuid.stdout.exp cpuid.vgtest \
cmpxchg8b.stderr.exp cmpxchg8b.stdout.exp cmpxchg8b.vgtest \
faultstatus.disabled faultstatus.stderr.exp \
@@ -32,7 +33,9 @@
yield.stderr.exp yield.stdout.exp yield.disabled
=20
check_PROGRAMS =3D \
- badseg bt_everything bt_literal cmpxchg8b cpuid \
+ badseg bt_everything bt_literal \
+ bug132813-x86 \
+ cmpxchg8b cpuid \
faultstatus fcmovnu fpu_lazy_eflags fxtract \
getseg incdec_alt $(INSN_TESTS) \
lahf looper movx int pushpopseg sbbmisc \
Added: trunk/none/tests/x86/bug132813-x86.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/none/tests/x86/bug132813-x86.c (rev 0)
+++ trunk/none/tests/x86/bug132813-x86.c 2006-08-28 18:09:46 UTC (rev 603=
4)
@@ -0,0 +1,170 @@
+
+#include <stdio.h>
+
+void do_pushb_pos ( void )
+{
+ unsigned int block[3];
+ __asm__ __volatile__ (
+ "movl %0, %%edx\n\t"
+ "pushl $0x55555555\n\t"
+ "movl %%esp, 0(%%edx)\n\t"
+ ".byte 0x6A,0x22\n\t"
+ "movl %%esp, 4(%%edx)\n\t"
+ "popl %%eax\n\t"
+ "movl %%eax,8(%%edx)\n\t"
+ "movl 0(%%edx),%%esp\n\t"
+ "addl $4, %%esp"
+ : : "r"(&block) : "eax","edx","cc","memory"
+ );
+ printf(" pushb_pos: delta %d, top32 0x%08x\n",
+ block[0] - block[1], block[2]);
+}
+
+void do_pushb_neg ( void )
+{
+ unsigned int block[3];
+ __asm__ __volatile__ (
+ "movl %0, %%edx\n\t"
+ "pushl $0x55555555\n\t"
+ "movl %%esp, 0(%%edx)\n\t"
+ ".byte 0x6A,0xEE\n\t"
+ "movl %%esp, 4(%%edx)\n\t"
+ "popl %%eax\n\t"
+ "movl %%eax,8(%%edx)\n\t"
+ "movl 0(%%edx),%%esp\n\t"
+ "addl $4, %%esp"
+ : : "r"(&block) : "eax","edx","cc","memory"
+ );
+ printf(" pushb_neg: delta %d, top32 0x%08x\n",
+ block[0] - block[1], block[2]);
+}
+
+void do_pushw_pos ( void )
+{
+ unsigned int block[3];
+ __asm__ __volatile__ (
+ "movl %0, %%edx\n\t"
+ "pushl $0x55555555\n\t"
+ "movl %%esp, 0(%%edx)\n\t"
+ "pushw $0x3344\n\t"
+ "movl %%esp, 4(%%edx)\n\t"
+ "popl %%eax\n\t"
+ "movl %%eax,8(%%edx)\n\t"
+ "movl 0(%%edx),%%esp\n\t"
+ "addl $4, %%esp"
+ : : "r"(&block) : "eax","edx","cc","memory"
+ );
+ printf(" pushw_neg: delta %d, top32 0x%08x\n",
+ block[0] - block[1], block[2]);
+}
+
+void do_pushw_neg ( void )
+{
+ unsigned int block[3];
+ __asm__ __volatile__ (
+ "movl %0, %%edx\n\t"
+ "pushl $0x55555555\n\t"
+ "movl %%esp, 0(%%edx)\n\t"
+ "pushw $0xDDCC\n\t"
+ "movl %%esp, 4(%%edx)\n\t"
+ "popl %%eax\n\t"
+ "movl %%eax,8(%%edx)\n\t"
+ "movl 0(%%edx),%%esp\n\t"
+ "addl $4, %%esp"
+ : : "r"(&block) : "eax","edx","cc","memory"
+ );
+ printf(" pushw_pos: delta %d, top32 0x%08x\n",
+ block[0] - block[1], block[2]);
+}
+
+void do_pushl_pos ( void )
+{
+ unsigned int block[3];
+ __asm__ __volatile__ (
+ "movl %0, %%edx\n\t"
+ "pushl $0x55555555\n\t"
+ "movl %%esp, 0(%%edx)\n\t"
+ "pushl $0x67675656\n\t"
+ "movl %%esp, 4(%%edx)\n\t"
+ "popl %%eax\n\t"
+ "movl %%eax,8(%%edx)\n\t"
+ "movl 0(%%edx),%%esp\n\t"
+ "addl $4, %%esp"
+ : : "r"(&block) : "eax","edx","cc","memory"
+ );
+ printf(" pushl_pos: delta %d, top32 0x%08x\n",
+ block[0] - block[1], block[2]);
+}
+
+void do_pushl_neg ( void )
+{
+ unsigned int block[3];
+ __asm__ __volatile__ (
+ "movl %0, %%edx\n\t"
+ "pushl $0x55555555\n\t"
+ "movl %%esp, 0(%%edx)\n\t"
+ "pushl $0x98988787\n\t"
+ "movl %%esp, 4(%%edx)\n\t"
+ "popl %%eax\n\t"
+ "movl %%eax,8(%%edx)\n\t"
+ "movl 0(%%edx),%%esp\n\t"
+ "addl $4, %%esp"
+ : : "r"(&block) : "eax","edx","cc","memory"
+ );
+ printf(" pushl_neg: delta %d, top32 0x%08x\n",
+ block[0] - block[1], block[2]);
+}
+
+
+void do_66pushb_pos ( void )
+{
+ unsigned int block[3];
+ __asm__ __volatile__ (
+ "movl %0, %%edx\n\t"
+ "pushl $0x55555555\n\t"
+ "movl %%esp, 0(%%edx)\n\t"
+ ".byte 0x66,0x6A,0x22\n\t"
+ "movl %%esp, 4(%%edx)\n\t"
+ "popl %%eax\n\t"
+ "movl %%eax,8(%%edx)\n\t"
+ "movl 0(%%edx),%%esp\n\t"
+ "addl $4, %%esp"
+ : : "r"(&block) : "eax","edx","cc","memory"
+ );
+ printf("66pushb_pos: delta %d, top32 0x%08x\n",
+ block[0] - block[1], block[2]);
+}
+
+void do_66pushb_neg ( void )
+{
+ unsigned int block[3];
+ __asm__ __volatile__ (
+ "movl %0, %%edx\n\t"
+ "pushl $0x55555555\n\t"
+ "movl %%esp, 0(%%edx)\n\t"
+ ".byte 0x66,0x6A,0xEE\n\t"
+ "movl %%esp, 4(%%edx)\n\t"
+ "popl %%eax\n\t"
+ "movl %%eax,8(%%edx)\n\t"
+ "movl 0(%%edx),%%esp\n\t"
+ "addl $4, %%esp"
+ : : "r"(&block) : "eax","edx","cc","memory"
+ );
+ printf("66pushb_neg: delta %d, top32 0x%08x\n",
+ block[0] - block[1], block[2]);
+}
+
+
+int main ( void )
+{
+ do_pushb_pos();
+ do_pushb_neg();
+ do_pushw_pos();
+ do_pushw_neg();
+ do_pushl_pos();
+ do_pushl_neg();
+
+ do_66pushb_pos();
+ do_66pushb_neg();
+ return 0;
+}
Added: trunk/none/tests/x86/bug132813-x86.stderr.exp
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/none/tests/x86/bug132813-x86.stderr.exp =
(rev 0)
+++ trunk/none/tests/x86/bug132813-x86.stderr.exp 2006-08-28 18:09:46 UTC=
(rev 6034)
@@ -0,0 +1,2 @@
+
+
Added: trunk/none/tests/x86/bug132813-x86.stdout.exp
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/none/tests/x86/bug132813-x86.stdout.exp =
(rev 0)
+++ trunk/none/tests/x86/bug132813-x86.stdout.exp 2006-08-28 18:09:46 UTC=
(rev 6034)
@@ -0,0 +1,8 @@
+ pushb_pos: delta 4, top32 0x00000022
+ pushb_neg: delta 4, top32 0xffffffee
+ pushw_neg: delta 2, top32 0x55553344
+ pushw_pos: delta 2, top32 0x5555ddcc
+ pushl_pos: delta 4, top32 0x67675656
+ pushl_neg: delta 4, top32 0x98988787
+66pushb_pos: delta 2, top32 0x55550022
+66pushb_neg: delta 2, top32 0x5555ffee
Added: trunk/none/tests/x86/bug132813-x86.vgtest
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/none/tests/x86/bug132813-x86.vgtest (re=
v 0)
+++ trunk/none/tests/x86/bug132813-x86.vgtest 2006-08-28 18:09:46 UTC (re=
v 6034)
@@ -0,0 +1 @@
+prog: bug132813-x86
|