aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorUros Bizjak <ubizjak@gmail.com>2015-01-30 11:53:53 +0100
committerUros Bizjak <uros@gcc.gnu.org>2015-01-30 11:53:53 +0100
commit089ad47399b946baeb5c6b62a97d6f1e5339e2bf (patch)
tree88743c2bd0acb8ae2784d371ce84c9f5e97c74c7 /gcc
parentb6dd03dd9c48470246b4b47e7471b2cf99c65737 (diff)
downloadgcc-089ad47399b946baeb5c6b62a97d6f1e5339e2bf.zip
gcc-089ad47399b946baeb5c6b62a97d6f1e5339e2bf.tar.gz
gcc-089ad47399b946baeb5c6b62a97d6f1e5339e2bf.tar.bz2
re PR target/15184 (Direct access to byte inside word not working with -march=pentiumpro)
PR target/15184 * gcc.target/i386/pr15184-1.c: Compile for ia32 target only. (dg-options): Remove -m32. (dg-final): Scan for "movb %al" only. * gcc.target/i386/pr15184-2.c: Ditto. From-SVN: r220277
Diffstat (limited to 'gcc')
-rw-r--r--gcc/testsuite/ChangeLog8
-rw-r--r--gcc/testsuite/gcc.target/i386/pr15184-1.c9
-rw-r--r--gcc/testsuite/gcc.target/i386/pr15184-2.c11
3 files changed, 17 insertions, 11 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 5ce99e6..e90c8b0 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,11 @@
+2015-01-30 Uros Bizjak <ubizjak@gmail.com>
+
+ PR target/15184
+ * gcc.target/i386/pr15184-1.c: Compile for ia32 target only.
+ (dg-options): Remove -m32.
+ (dg-final): Scan for "movb %al" only.
+ * gcc.target/i386/pr15184-2.c: Ditto.
+
2015-01-30 Richard Biener <rguenther@suse.de>
PR tree-optimization/64829
diff --git a/gcc/testsuite/gcc.target/i386/pr15184-1.c b/gcc/testsuite/gcc.target/i386/pr15184-1.c
index 9eb544c..8c19e47 100644
--- a/gcc/testsuite/gcc.target/i386/pr15184-1.c
+++ b/gcc/testsuite/gcc.target/i386/pr15184-1.c
@@ -1,11 +1,10 @@
/* PR 15184 first two tests, plus two addition ones. */
-/* { dg-do compile } */
-/* { dg-options "-O2 -m32 -march=pentiumpro" } */
+/* { dg-do compile { target ia32 } } */
+/* { dg-options "-O2 -march=pentiumpro" } */
-#define regparm __attribute__((__regparm__(3)))
+#define regparm __attribute__((__regparm__(1)))
extern unsigned int x;
-extern unsigned short y;
void regparm f0(unsigned char c)
{
@@ -29,5 +28,5 @@ void regparm f3(unsigned char c)
/* Each function should compile down to a byte move from
the input register into x, possibly at an offset within x. */
-/* { dg-final { scan-assembler-times "\tmovb\t%al, x" 4 } } */
+/* { dg-final { scan-assembler-times "movb\[ \\t\]+%al" 4 } } */
diff --git a/gcc/testsuite/gcc.target/i386/pr15184-2.c b/gcc/testsuite/gcc.target/i386/pr15184-2.c
index 99fdbc8..a6cb9eb 100644
--- a/gcc/testsuite/gcc.target/i386/pr15184-2.c
+++ b/gcc/testsuite/gcc.target/i386/pr15184-2.c
@@ -1,10 +1,9 @@
/* PR 15184 second two tests
-/* { dg-do compile } */
-/* { dg-options "-O2 -m32 -march=pentiumpro" } */
+/* { dg-do compile { target ia32 } } */
+/* { dg-options "-O2 -march=pentiumpro" } */
-#define regparm __attribute__((__regparm__(3)))
+#define regparm __attribute__((__regparm__(1)))
-extern unsigned int x;
extern unsigned short y;
void regparm g0(unsigned char c)
@@ -18,6 +17,6 @@ void regparm g1(unsigned char c)
}
/* Each function should compile down to a byte move from
- the input register into x, possibly at an offset within x. */
-/* { dg-final { scan-assembler-times "\tmovb\t%al, y" 2 } } */
+ the input register into y, possibly at an offset within y. */
+/* { dg-final { scan-assembler-times "movb\[ \\t\]+%al" 2 } } */