summaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authorhariharans <hariharans@138bc75d-0d04-0410-961f-82ee72b054a4>2008-12-29 10:31:14 +0000
committerhariharans <hariharans@138bc75d-0d04-0410-961f-82ee72b054a4>2008-12-29 10:31:14 +0000
commit0c20e33d2297735c398e42b39e9fbe45a3af7a1d (patch)
treeca75f7c0eb56afa8cddea89b63b6968085a6f574 /gcc/testsuite
parent4331537398d5b595ca10fd1e31a4dd526593aff0 (diff)
downloadgcc-0c20e33d2297735c398e42b39e9fbe45a3af7a1d.tar.gz
* gcc.c-torture/execute/builtins/fprintf.x: Disable test for
freestanding targets. * gcc.c-torture/execute/pr37573.x: Disable test for 16-bit targets. * gcc.c-torture/execute/20081117-1.x: Disable test for 16-bit targets. * gcc.c-torture/compile/limits-stringlit.c: Disable test for picochip. * gcc.dg/array-quals-1.c: Disable test for picochip. * lib/target-supports.exp: Add support for freestanding ports and disable picochip for profiling tests. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@142948 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/ChangeLog11
-rw-r--r--gcc/testsuite/gcc.c-torture/compile/limits-fndefn.c2
-rw-r--r--gcc/testsuite/gcc.c-torture/compile/limits-stringlit.c2
-rw-r--r--gcc/testsuite/gcc.c-torture/execute/20081117-1.x7
-rw-r--r--gcc/testsuite/gcc.c-torture/execute/builtins/fprintf.x7
-rw-r--r--gcc/testsuite/gcc.c-torture/execute/pr37573.x7
-rw-r--r--gcc/testsuite/gcc.dg/array-quals-1.c2
-rw-r--r--gcc/testsuite/lib/target-supports.exp18
8 files changed, 48 insertions, 8 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 33f1b47d317..e89e5b68e94 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,14 @@
+2008-12-15 Hariharan Sandanagobalane <hariharan@picochip.com>
+
+ * gcc.c-torture/execute/builtins/fprintf.x: Disable test for
+ freestanding targets.
+ * gcc.c-torture/execute/pr37573.x: Disable test for 16-bit targets.
+ * gcc.c-torture/execute/20081117-1.x: Disable test for 16-bit targets.
+ * gcc.c-torture/compile/limits-stringlit.c: Disable test for picochip.
+ * gcc.dg/array-quals-1.c: Disable test for picochip.
+ * lib/target-supports.exp: Add support for freestanding ports and
+ disable picochip for profiling tests.
+
2008-12-29 Jakub Jelinek <jakub@redhat.com>
PR c++/38637
diff --git a/gcc/testsuite/gcc.c-torture/compile/limits-fndefn.c b/gcc/testsuite/gcc.c-torture/compile/limits-fndefn.c
index 0c5a2f5e774..10f8714414f 100644
--- a/gcc/testsuite/gcc.c-torture/compile/limits-fndefn.c
+++ b/gcc/testsuite/gcc.c-torture/compile/limits-fndefn.c
@@ -1,4 +1,4 @@
-/* { dg-skip-if "too complex for avr" { "avr-*-*" } { "*" } { "" } } */
+/* { dg-skip-if "too complex for avr and picochip" { picochip-*-* avr-*-* } { "*" } { "" } } */
#define LIM1(x) x##0, x##1, x##2, x##3, x##4, x##5, x##6, x##7, x##8, x##9,
#define LIM2(x) LIM1(x##0) LIM1(x##1) LIM1(x##2) LIM1(x##3) LIM1(x##4) \
LIM1(x##5) LIM1(x##6) LIM1(x##7) LIM1(x##8) LIM1(x##9)
diff --git a/gcc/testsuite/gcc.c-torture/compile/limits-stringlit.c b/gcc/testsuite/gcc.c-torture/compile/limits-stringlit.c
index 5b52c83b061..c24ad4b5793 100644
--- a/gcc/testsuite/gcc.c-torture/compile/limits-stringlit.c
+++ b/gcc/testsuite/gcc.c-torture/compile/limits-stringlit.c
@@ -1,4 +1,4 @@
-/* { dg-skip-if "Array too big" { "avr-*-*" } { "*" } { "" } } */
+/* { dg-skip-if "Array too big" { avr-*-* picochip-*-* } { "*" } { "" } } */
#define STR2 "012345678901234567890123456789012345678901234567890123456789\
0123456789012345678901234567890123456789"
diff --git a/gcc/testsuite/gcc.c-torture/execute/20081117-1.x b/gcc/testsuite/gcc.c-torture/execute/20081117-1.x
new file mode 100644
index 00000000000..7378270cdb0
--- /dev/null
+++ b/gcc/testsuite/gcc.c-torture/execute/20081117-1.x
@@ -0,0 +1,7 @@
+load_lib target-supports.exp
+
+if { [check_effective_target_int16] } {
+ return 1
+}
+
+return 0
diff --git a/gcc/testsuite/gcc.c-torture/execute/builtins/fprintf.x b/gcc/testsuite/gcc.c-torture/execute/builtins/fprintf.x
new file mode 100644
index 00000000000..c8fdaf5b254
--- /dev/null
+++ b/gcc/testsuite/gcc.c-torture/execute/builtins/fprintf.x
@@ -0,0 +1,7 @@
+load_lib target-supports.exp
+
+if { [check_effective_target_freestanding] } {
+ return 1;
+}
+
+return 0;
diff --git a/gcc/testsuite/gcc.c-torture/execute/pr37573.x b/gcc/testsuite/gcc.c-torture/execute/pr37573.x
new file mode 100644
index 00000000000..7378270cdb0
--- /dev/null
+++ b/gcc/testsuite/gcc.c-torture/execute/pr37573.x
@@ -0,0 +1,7 @@
+load_lib target-supports.exp
+
+if { [check_effective_target_int16] } {
+ return 1
+}
+
+return 0
diff --git a/gcc/testsuite/gcc.dg/array-quals-1.c b/gcc/testsuite/gcc.dg/array-quals-1.c
index fc5398ba338..f01db686b45 100644
--- a/gcc/testsuite/gcc.dg/array-quals-1.c
+++ b/gcc/testsuite/gcc.dg/array-quals-1.c
@@ -4,7 +4,7 @@
/* Origin: Joseph Myers <jsm@polyomino.org.uk> */
/* { dg-do compile } */
/* The MMIX port always switches to the .data section at the end of a file. */
-/* { dg-final { scan-assembler-not "\\.data(?!\\.rel\\.ro)" { xfail powerpc*-*-aix* mmix-*-* x86_64-*-mingw* avr-*-*} } } */
+/* { dg-final { scan-assembler-not "\\.data(?!\\.rel\\.ro)" { xfail powerpc*-*-aix* mmix-*-* x86_64-*-mingw* picochip--*-* avr-*-*} } } */
static const int a[2] = { 1, 2 };
const int a1[2] = { 1, 2 };
typedef const int ci;
diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp
index 549ceaac0b7..79e77f237d8 100644
--- a/gcc/testsuite/lib/target-supports.exp
+++ b/gcc/testsuite/lib/target-supports.exp
@@ -452,11 +452,6 @@ proc check_profiling_available { test_what } {
return 0
}
- # At present, there is no profiling support on NetWare.
- if { [istarget *-*-netware*] } {
- return 0
- }
-
# uClibc does not have gcrt1.o.
if { [check_effective_target_uclibc]
&& ([lindex $test_what 1] == "-p"
@@ -470,6 +465,8 @@ proc check_profiling_available { test_what } {
# missing other needed machinery.
if { [istarget mmix-*-*]
|| [istarget arm*-*-eabi*]
+ || [istarget picochip-*-*]
+ || [istarget *-*-netware*]
|| [istarget arm*-*-elf]
|| [istarget arm*-*-symbianelf*]
|| [istarget avr-*-*]
@@ -496,6 +493,17 @@ proc check_profiling_available { test_what } {
return $profiling_available_saved
}
+# Check to see if a target is "freestanding". This is as per the definition
+# in Section 4 of C99 standard. Effectively, it is a target which supports no
+# extra headers or libraries other than what is considered essential.
+proc check_effective_target_freestanding { } {
+ if { [istarget picochip-*-*] } then {
+ return 1
+ } else {
+ return 0
+ }
+}
+
# Return 1 if target has packed layout of structure members by
# default, 0 otherwise. Note that this is slightly different than
# whether the target has "natural alignment": both attributes may be