This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH][ARM] Update target testcases for gnu11


this patch update arm testcases for recently gnu11 change.

ok for trunk?
thanks.

gcc/testsuite/
  * gcc.target/arm/20031108-1.c: Add explicit declaration.
  * gcc.target/arm/cold-lc.c: Likewise.
  * gcc.target/arm/neon-modes-2.c: Likewise.
  * gcc.target/arm/pr43920-2.c: Likewise.
  * gcc.target/arm/pr44788.c: Likewise.
  * gcc.target/arm/pr55642.c: Likewise.
  * gcc.target/arm/pr58784.c: Likewise.
  * gcc.target/arm/pr60650.c: Likewise.
  * gcc.target/arm/pr60650-2.c: Likewise.
  * gcc.target/arm/vfp-ldmdbs.c: Likewise.
  * gcc.target/arm/vfp-ldmias.c: Likewise.
  * lib/target-supports.exp: Likewise.
  * gcc.target/arm/pr51968.c: Add -Wno-implicit-function-declaration.

diff --git a/gcc/testsuite/gcc.target/arm/20031108-1.c b/gcc/testsuite/gcc.target/arm/20031108-1.c
index d9b6006..7923e11 100644
--- a/gcc/testsuite/gcc.target/arm/20031108-1.c
+++ b/gcc/testsuite/gcc.target/arm/20031108-1.c
@@ -20,6 +20,9 @@ typedef struct record
 
 Rec_Pointer Ptr_Glob;
 
+extern int Proc_7 (int, int, int *);
+
+void
 Proc_1 (Ptr_Val_Par)
     Rec_Pointer Ptr_Val_Par;
 {
diff --git a/gcc/testsuite/gcc.target/arm/cold-lc.c b/gcc/testsuite/gcc.target/arm/cold-lc.c
index 295c29f..467a696 100644
--- a/gcc/testsuite/gcc.target/arm/cold-lc.c
+++ b/gcc/testsuite/gcc.target/arm/cold-lc.c
@@ -7,6 +7,7 @@ struct thread_info {
     struct task_struct *task;
 };
 extern struct thread_info *current_thread_info (void);
+extern int show_stack (struct task_struct *, unsigned long *);
 
 void dump_stack (void)
 {
diff --git a/gcc/testsuite/gcc.target/arm/neon-modes-2.c b/gcc/testsuite/gcc.target/arm/neon-modes-2.c
index 40f1bba..16319bb 100644
--- a/gcc/testsuite/gcc.target/arm/neon-modes-2.c
+++ b/gcc/testsuite/gcc.target/arm/neon-modes-2.c
@@ -11,6 +11,8 @@
 
 #define MANY(A) A (0), A (1), A (2), A (3), A (4), A (5)
 
+extern void foo (int *, int *);
+
 void
 bar (uint32_t *ptr, int y)
 {
diff --git a/gcc/testsuite/gcc.target/arm/pr43920-2.c b/gcc/testsuite/gcc.target/arm/pr43920-2.c
index f647165..f5e8f48 100644
--- a/gcc/testsuite/gcc.target/arm/pr43920-2.c
+++ b/gcc/testsuite/gcc.target/arm/pr43920-2.c
@@ -4,6 +4,8 @@
 
 #include <stdio.h>
 
+extern int lseek(int, long, int);
+
 int getFileStartAndLength (int fd, int *start_, size_t *length_)
 {
       int start, end;
diff --git a/gcc/testsuite/gcc.target/arm/pr44788.c b/gcc/testsuite/gcc.target/arm/pr44788.c
index eb4bc11..9ce44a8 100644
--- a/gcc/testsuite/gcc.target/arm/pr44788.c
+++ b/gcc/testsuite/gcc.target/arm/pr44788.c
@@ -2,6 +2,8 @@
 /* { dg-require-effective-target arm_thumb2_ok } */
 /* { dg-options "-Os -fno-strict-aliasing -fPIC -mthumb -march=armv7-a -mfpu=vfp3 -mfloat-abi=softfp" } */
 
+extern void foo (float *);
+
 void joint_decode(float* mlt_buffer1, int t) {
     int i;
     float decode_buffer[1060];
diff --git a/gcc/testsuite/gcc.target/arm/pr51968.c b/gcc/testsuite/gcc.target/arm/pr51968.c
index f0506c2..6cf802b 100644
--- a/gcc/testsuite/gcc.target/arm/pr51968.c
+++ b/gcc/testsuite/gcc.target/arm/pr51968.c
@@ -1,6 +1,6 @@
 /* PR target/51968 */
 /* { dg-do compile } */
-/* { dg-options "-O2 -march=armv7-a -mfloat-abi=softfp -mfpu=neon" } */
+/* { dg-options "-O2 -Wno-implicit-function-declaration -march=armv7-a -mfloat-abi=softfp -mfpu=neon" } */
 /* { dg-require-effective-target arm_neon_ok } */
 
 typedef __builtin_neon_qi int8x8_t __attribute__ ((__vector_size__ (8)));
diff --git a/gcc/testsuite/gcc.target/arm/pr55642.c b/gcc/testsuite/gcc.target/arm/pr55642.c
index 10f2daa..a7defa7 100644
--- a/gcc/testsuite/gcc.target/arm/pr55642.c
+++ b/gcc/testsuite/gcc.target/arm/pr55642.c
@@ -2,6 +2,8 @@
 /* { dg-do compile } */
 /* { dg-require-effective-target arm_thumb2_ok } */
 
+extern int abs (int);
+
 int
 foo (int v)
 {
diff --git a/gcc/testsuite/gcc.target/arm/pr58784.c b/gcc/testsuite/gcc.target/arm/pr58784.c
index 9a1fcff..4ee3ef5 100644
--- a/gcc/testsuite/gcc.target/arm/pr58784.c
+++ b/gcc/testsuite/gcc.target/arm/pr58784.c
@@ -11,6 +11,9 @@ typedef struct __attribute__ ((__packed__))
     char stepsRemoved;
     ptp_tlv_t tlv[1];
 } ptp_message_announce_t;
+
+extern void f (ptp_message_announce_t *);
+
 int ptplib_send_announce(int sequenceId, int i)
 {
     ptp_message_announce_t tx_packet;
diff --git a/gcc/testsuite/gcc.target/arm/pr60650-2.c b/gcc/testsuite/gcc.target/arm/pr60650-2.c
index 1946760..c8d4615 100644
--- a/gcc/testsuite/gcc.target/arm/pr60650-2.c
+++ b/gcc/testsuite/gcc.target/arm/pr60650-2.c
@@ -4,17 +4,19 @@
 int a, h, j;
 long long d, e, i;
 int f;
+int
 fn1 (void *p1, int p2)
 {
     switch (p2)
     case 8:
 {
-    register b = *(long long *) p1, c asm ("r2");
+    register int b = *(long long *) p1, c asm ("r2");
     asm ("%0": "=r" (a), "=r" (c):"r" (b), "r" (0));
     *(long long *) p1 = c;
     }
 }
 
+int
 fn2 ()
 {
     int k;
@@ -27,8 +29,8 @@ fn2 ()
         case 0:
         (
         {
-            register l asm ("r4");
-            register m asm ("r0");
+            register int l asm ("r4");
+            register int m asm ("r0");
             asm ("  .err  .endif\n\t": "=r" (h), "=r" (j):"r" (m),
             "r"
             (l));;
diff --git a/gcc/testsuite/gcc.target/arm/pr60650.c b/gcc/testsuite/gcc.target/arm/pr60650.c
index 17a5ed4..734b41f 100644
--- a/gcc/testsuite/gcc.target/arm/pr60650.c
+++ b/gcc/testsuite/gcc.target/arm/pr60650.c
@@ -20,6 +20,10 @@ struct btrfs_root
 int a, c, d;
 long long e;
 
+extern int foo1 (struct btrfs_root *, int, int, int);
+extern int foo2 (struct btrfs_root *, int, int);
+
+int
 truncate_one_csum (struct btrfs_root *p1, long long p2, long long p3)
 {
   int f, g, i = p1->fs_info->sb->s_blocksize_bits;
diff --git a/gcc/testsuite/gcc.target/arm/vfp-ldmdbs.c b/gcc/testsuite/gcc.target/arm/vfp-ldmdbs.c
index 10bccf6..0187c01 100644
--- a/gcc/testsuite/gcc.target/arm/vfp-ldmdbs.c
+++ b/gcc/testsuite/gcc.target/arm/vfp-ldmdbs.c
@@ -3,7 +3,7 @@
 /* { dg-skip-if "need fp instructions" { *-*-* } { "-mfloat-abi=soft" } { "" } } */
 /* { dg-options "-O2 -mfpu=vfp -mfloat-abi=softfp" } */
 
-extern void baz (float);
+extern void bar (float);
 
 void
 foo (float *p, float a, int n)
diff --git a/gcc/testsuite/gcc.target/arm/vfp-ldmias.c b/gcc/testsuite/gcc.target/arm/vfp-ldmias.c
index bc40451..92051fd 100644
--- a/gcc/testsuite/gcc.target/arm/vfp-ldmias.c
+++ b/gcc/testsuite/gcc.target/arm/vfp-ldmias.c
@@ -3,7 +3,7 @@
 /* { dg-skip-if "need fp instructions" { *-*-* } { "-mfloat-abi=soft" } { "" } } */
 /* { dg-options "-O2 -mfpu=vfp -mfloat-abi=softfp" } */
 
-extern void baz (float);
+extern void bar (float);
 
 void
 foo (float *p, float a, int n)
diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp
index 4398345..91460c2 100644
--- a/gcc/testsuite/lib/target-supports.exp
+++ b/gcc/testsuite/lib/target-supports.exp
@@ -2404,6 +2404,7 @@ proc check_effective_target_arm_crypto_ok_nocache { } {
 	foreach flags {"" "-mfloat-abi=softfp" "-mfpu=crypto-neon-fp-armv8" "-mfpu=crypto-neon-fp-armv8 -mfloat-abi=softfp"} {
 	    if { [check_no_compiler_messages_nocache arm_crypto_ok object {
 		#include "arm_neon.h"
+		extern uint8x16_t vaeseq_u8 (uint8x16_t, uint8x16_t);
 		uint8x16_t
 		foo (uint8x16_t a, uint8x16_t b)
 		{
@@ -2548,6 +2549,7 @@ proc check_effective_target_arm_neon_fp16_ok_nocache { } {
 	               "-mfpu=neon-fp16 -mfloat-abi=softfp"} {
 	    if { [check_no_compiler_messages_nocache arm_neon_fp_16_ok object {
 		#include "arm_neon.h"
+		extern float16x4_t vcvt_f16_f32 (float32x4_t);
 		float16x4_t
 		foo (float32x4_t arg)
 		{
@@ -2623,6 +2625,7 @@ proc check_effective_target_arm_neonv2_ok_nocache { } {
 	foreach flags {"" "-mfloat-abi=softfp" "-mfpu=neon-vfpv4" "-mfpu=neon-vfpv4 -mfloat-abi=softfp"} {
 	    if { [check_no_compiler_messages_nocache arm_neonv2_ok object {
 		#include "arm_neon.h"
+		extern float32x2_t vfma_f32 (float32x2_t, float32x2_t, float32x2_t);
 		float32x2_t 
 		foo (float32x2_t a, float32x2_t b, float32x2_t c)
                 {

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]