|
From: <sv...@va...> - 2009-04-24 07:12:42
|
Author: njn
Date: 2009-04-24 08:12:39 +0100 (Fri, 24 Apr 2009)
New Revision: 9604
Log:
Merged r9602 and r9603 (make cpuid pass on Darwin, rename .s files to .S)
from the DARWIN branch.
Added:
trunk/memcheck/tests/x86/pushfpopf_s.S
trunk/none/tests/x86/cpuid_s.S
Removed:
trunk/memcheck/tests/x86/pushfpopf_s.s
trunk/none/tests/x86/cpuid_s.s
Modified:
trunk/cachegrind/tests/x86/Makefile.am
trunk/memcheck/tests/x86/Makefile.am
trunk/none/tests/x86/Makefile.am
Modified: trunk/cachegrind/tests/x86/Makefile.am
===================================================================
--- trunk/cachegrind/tests/x86/Makefile.am 2009-04-24 07:00:11 UTC (rev 9603)
+++ trunk/cachegrind/tests/x86/Makefile.am 2009-04-24 07:12:39 UTC (rev 9604)
@@ -12,6 +12,6 @@
AM_CFLAGS += @FLAG_M32@ $(FLAG_MMMX) $(FLAG_MSSE)
AM_CXXFLAGS += @FLAG_M32@ $(FLAG_MMMX) $(FLAG_MSSE)
-AM_CCASFLAGS = @FLAG_M32@
+AM_CCASFLAGS = $(AM_CPPFLAGS) @FLAG_M32@
fpu_28_108_SOURCES = fpu-28-108.S
Modified: trunk/memcheck/tests/x86/Makefile.am
===================================================================
--- trunk/memcheck/tests/x86/Makefile.am 2009-04-24 07:00:11 UTC (rev 9603)
+++ trunk/memcheck/tests/x86/Makefile.am 2009-04-24 07:12:39 UTC (rev 9604)
@@ -46,7 +46,7 @@
# must be built with these flags -- bug only occurred with them
fpeflags_CFLAGS = $(AM_CFLAGS) -march=i686
-pushfpopf_SOURCES = pushfpopf_c.c pushfpopf_s.s
+pushfpopf_SOURCES = pushfpopf_c.c pushfpopf_s.S
tronical_SOURCES = tronical.S
more_x86_fp_LDADD = -lm
Copied: trunk/memcheck/tests/x86/pushfpopf_s.S (from rev 9603, branches/DARWIN/memcheck/tests/x86/pushfpopf_s.S)
===================================================================
--- trunk/memcheck/tests/x86/pushfpopf_s.S (rev 0)
+++ trunk/memcheck/tests/x86/pushfpopf_s.S 2009-04-24 07:12:39 UTC (rev 9604)
@@ -0,0 +1,41 @@
+ .file "twoparams.c"
+ .version "01.01"
+gcc2_compiled.:
+.text
+ .align 4
+.globl fooble
+ .type fooble,@function
+fooble:
+ pushl %ebp
+ movl %esp, %ebp
+ movl 8(%ebp), %eax
+
+ subl 12(%ebp), %eax
+ # flags are now undef if either operand is
+ # save possibly undef flags on stack
+ pushfl
+
+ movl $0, %eax
+ addl $0, %eax
+ # flags are now definitely defined
+
+ popfl
+ # resulting flag definedness depends on outcome of sub above
+ # should override that created by 0 + 0 above
+ # because Vex does an emulation-warning check on the popfl,
+ # an error should be reported for the popfl
+
+ # now use the condition codes to generate a value
+ # in a way which will cause undefinedness to get reported
+ # (a second time)
+ jz labelz
+ movl $22, %eax
+ jmp theend
+labelz:
+ movl $33, %eax
+theend:
+ popl %ebp
+ ret
+.Lfe1:
+ .size fooble,.Lfe1-fooble
+ .ident "GCC: (GNU) 2.96 20000731 (Red Hat Linux 7.1 2.96-98)"
Deleted: trunk/memcheck/tests/x86/pushfpopf_s.s
===================================================================
--- trunk/memcheck/tests/x86/pushfpopf_s.s 2009-04-24 07:00:11 UTC (rev 9603)
+++ trunk/memcheck/tests/x86/pushfpopf_s.s 2009-04-24 07:12:39 UTC (rev 9604)
@@ -1,41 +0,0 @@
- .file "twoparams.c"
- .version "01.01"
-gcc2_compiled.:
-.text
- .align 4
-.globl fooble
- .type fooble,@function
-fooble:
- pushl %ebp
- movl %esp, %ebp
- movl 8(%ebp), %eax
-
- subl 12(%ebp), %eax
- # flags are now undef if either operand is
- # save possibly undef flags on stack
- pushfl
-
- movl $0, %eax
- addl $0, %eax
- # flags are now definitely defined
-
- popfl
- # resulting flag definedness depends on outcome of sub above
- # should override that created by 0 + 0 above
- # because Vex does an emulation-warning check on the popfl,
- # an error should be reported for the popfl
-
- # now use the condition codes to generate a value
- # in a way which will cause undefinedness to get reported
- # (a second time)
- jz labelz
- movl $22, %eax
- jmp theend
-labelz:
- movl $33, %eax
-theend:
- popl %ebp
- ret
-.Lfe1:
- .size fooble,.Lfe1-fooble
- .ident "GCC: (GNU) 2.96 20000731 (Red Hat Linux 7.1 2.96-98)"
Modified: trunk/none/tests/x86/Makefile.am
===================================================================
--- trunk/none/tests/x86/Makefile.am 2009-04-24 07:00:11 UTC (rev 9603)
+++ trunk/none/tests/x86/Makefile.am 2009-04-24 07:12:39 UTC (rev 9604)
@@ -67,8 +67,8 @@
bug137714-x86 \
bug152818-x86 \
cmpxchg8b \
- cpuid \
- cse_fail \
+ cpuid \
+ cse_fail \
faultstatus \
fcmovnu \
fpu_lazy_eflags \
@@ -89,13 +89,14 @@
check_PROGRAMS += ssse3_misaligned
endif
+
AM_CFLAGS += @FLAG_M32@ $(FLAG_MMMX) $(FLAG_MSSE)
AM_CXXFLAGS += @FLAG_M32@ $(FLAG_MMMX) $(FLAG_MSSE)
-AM_CCASFLAGS = @FLAG_M32@
+AM_CCASFLAGS = $(AM_CPPFLAGS) @FLAG_M32@
# generic C ones
-cpuid_SOURCES = cpuid_c.c cpuid_s.s
+cpuid_SOURCES = cpuid_c.c cpuid_s.S
# fpu_lazy_eflags must use these flags -- the bug only occurred with them
fpu_lazy_eflags_CFLAGS = $(AM_CFLAGS) -O2 -march=pentiumpro
fxtract_LDADD = -lm
Copied: trunk/none/tests/x86/cpuid_s.S (from rev 9595, trunk/none/tests/x86/cpuid_s.s)
===================================================================
--- trunk/none/tests/x86/cpuid_s.S (rev 0)
+++ trunk/none/tests/x86/cpuid_s.S 2009-04-24 07:12:39 UTC (rev 9604)
@@ -0,0 +1,71 @@
+#include "tests/asm.h"
+
+ .file "oneparam.c"
+ .version "01.01"
+gcc2_compiled.:
+.text
+ .align 4
+
+.globl VG_SYM_ASM(get_cpuid0)
+VG_SYM_ASM(get_cpuid0):
+ pushl %ebp
+ movl %esp, %ebp
+ movl 8(%ebp), %eax
+
+ pushl %edi
+ pushl %eax
+ pushl %ebx
+ pushl %ecx
+ pushl %edx
+
+ movl %eax, %edi
+ movl $0, %eax
+ cpuid
+ movl %eax, (%edi)
+ movl %ebx, 4(%edi)
+ movl %ecx, 8(%edi)
+ movl %edx, 12(%edi)
+
+ popl %edx
+ popl %ecx
+ popl %ebx
+ popl %eax
+ popl %edi
+
+ popl %ebp
+ ret
+
+
+.globl VG_SYM_ASM(get_cpuid1)
+VG_SYM_ASM(get_cpuid1):
+ pushl %ebp
+ movl %esp, %ebp
+ movl 8(%ebp), %eax
+
+ pushl %edi
+ pushl %eax
+ pushl %ebx
+ pushl %ecx
+ pushl %edx
+
+ movl %eax, %edi
+ movl $1, %eax
+ cpuid
+ movl %eax, (%edi)
+ movl %ebx, 4(%edi)
+ movl %ecx, 8(%edi)
+ movl %edx, 12(%edi)
+
+ popl %edx
+ popl %ecx
+ popl %ebx
+ popl %eax
+ popl %edi
+
+ popl %ebp
+ ret
+
+
+
+
+ .ident "GCC: (GNU) 2.96 20000731 (Red Hat Linux 7.1 2.96-98)"
Property changes on: trunk/none/tests/x86/cpuid_s.S
___________________________________________________________________
Name: svn:keywords
+ author date id revision
Name: svn:mergeinfo
+
Name: svn:eol-style
+ native
Deleted: trunk/none/tests/x86/cpuid_s.s
===================================================================
--- trunk/none/tests/x86/cpuid_s.s 2009-04-24 07:00:11 UTC (rev 9603)
+++ trunk/none/tests/x86/cpuid_s.s 2009-04-24 07:12:39 UTC (rev 9604)
@@ -1,77 +0,0 @@
-
-
- .file "oneparam.c"
- .version "01.01"
-gcc2_compiled.:
-.text
- .align 4
-
-.globl get_cpuid0
- .type get_cpuid0,@function
-get_cpuid0:
- pushl %ebp
- movl %esp, %ebp
- movl 8(%ebp), %eax
-
- pushl %edi
- pushl %eax
- pushl %ebx
- pushl %ecx
- pushl %edx
-
- movl %eax, %edi
- movl $0, %eax
- cpuid
- movl %eax, (%edi)
- movl %ebx, 4(%edi)
- movl %ecx, 8(%edi)
- movl %edx, 12(%edi)
-
- popl %edx
- popl %ecx
- popl %ebx
- popl %eax
- popl %edi
-
- popl %ebp
- ret
-.Lfe1:
- .size get_cpuid0,.Lfe1-get_cpuid0
-
-
-.globl get_cpuid1
- .type get_cpuid1,@function
-get_cpuid1:
- pushl %ebp
- movl %esp, %ebp
- movl 8(%ebp), %eax
-
- pushl %edi
- pushl %eax
- pushl %ebx
- pushl %ecx
- pushl %edx
-
- movl %eax, %edi
- movl $1, %eax
- cpuid
- movl %eax, (%edi)
- movl %ebx, 4(%edi)
- movl %ecx, 8(%edi)
- movl %edx, 12(%edi)
-
- popl %edx
- popl %ecx
- popl %ebx
- popl %eax
- popl %edi
-
- popl %ebp
- ret
-.Lfe2:
- .size get_cpuid1,.Lfe2-get_cpuid1
-
-
-
-
- .ident "GCC: (GNU) 2.96 20000731 (Red Hat Linux 7.1 2.96-98)"
|