summaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authortoon <toon@138bc75d-0d04-0410-961f-82ee72b054a4>2001-08-01 20:35:59 +0000
committertoon <toon@138bc75d-0d04-0410-961f-82ee72b054a4>2001-08-01 20:35:59 +0000
commitad2b2377eb1cf8008d6e527ec7913f83e0dce071 (patch)
treebbe6b7f15b54c0db3bb1fa887ed7a0710d644e36 /gcc/testsuite
parent93006578d2031216f781196b79b51e3a91b48717 (diff)
downloadgcc-ad2b2377eb1cf8008d6e527ec7913f83e0dce071.tar.gz
2001-08-01 David Billinghurst <David.Billinghurst@riotinto.com>
* lib/g77.exp: Load gcc-defs.exp for common procedures (g77_pass, g77_fail, g77_finish, g77_exit, ${tool}_check_unsupported_p} Now redundant. Deleted. 2001-08-01 David Billinghurst <David.Billinghurst@riotinto.com> * g77.dg/fbackslash.f * g77.dg/fcase-preserve.f * g77.dg/ff90-1.f * g77.dg/ffixed-line-length-0.f * g77.dg/ffixed-line-length-132.f * g77.dg/ffixed-line-length-7.f * g77.dg/ffixed-line-length-72.f * g77.dg/ffixed-line-length-none.f * g77.dg/ffree-form-1.f * g77.dg/fno-backslash.f * g77.dg/fno-f90-1.f * g77.dg/fno-fixed-form-1.f * g77.dg/fno-onetrip.f * g77.dg/fno-typeless-boz.f * g77.dg/fno-underscoring.f * g77.dg/fno-vxt-1.f * g77.dg/fonetrip.f * g77.dg/ftypeless-boz.f * g77.dg/fugly-assumed.f * g77.dg/funderscoring.f * g77.dg/fvxt-1.f git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@44555 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/ChangeLog30
-rw-r--r--gcc/testsuite/g77.dg/fbackslash.f7
-rw-r--r--gcc/testsuite/g77.dg/fcase-preserve.f9
-rw-r--r--gcc/testsuite/g77.dg/ff90-1.f15
-rw-r--r--gcc/testsuite/g77.dg/ffixed-line-length-0.f7
-rw-r--r--gcc/testsuite/g77.dg/ffixed-line-length-132.f7
-rw-r--r--gcc/testsuite/g77.dg/ffixed-line-length-7.f8
-rw-r--r--gcc/testsuite/g77.dg/ffixed-line-length-72.f7
-rw-r--r--gcc/testsuite/g77.dg/ffixed-line-length-none.f7
-rw-r--r--gcc/testsuite/g77.dg/ffree-form-1.f6
-rw-r--r--gcc/testsuite/g77.dg/fno-backslash.f7
-rw-r--r--gcc/testsuite/g77.dg/fno-f90-1.f15
-rw-r--r--gcc/testsuite/g77.dg/fno-fixed-form-1.f6
-rw-r--r--gcc/testsuite/g77.dg/fno-onetrip.f9
-rw-r--r--gcc/testsuite/g77.dg/fno-typeless-boz.f10
-rw-r--r--gcc/testsuite/g77.dg/fno-underscoring.f8
-rw-r--r--gcc/testsuite/g77.dg/fno-vxt-1.f10
-rw-r--r--gcc/testsuite/g77.dg/fonetrip.f10
-rw-r--r--gcc/testsuite/g77.dg/ftypeless-boz.f10
-rw-r--r--gcc/testsuite/g77.dg/fugly-assumed.f9
-rw-r--r--gcc/testsuite/g77.dg/funderscoring.f8
-rw-r--r--gcc/testsuite/g77.dg/fvxt-1.f10
-rw-r--r--gcc/testsuite/lib/g77.exp92
23 files changed, 217 insertions, 90 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 3123415c8fe..0fd0ee30fc7 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,33 @@
+2001-08-01 David Billinghurst <David.Billinghurst@riotinto.com>
+
+ * lib/g77.exp: Load gcc-defs.exp for common procedures
+ (g77_pass, g77_fail, g77_finish, g77_exit,
+ ${tool}_check_unsupported_p} Now redundant. Deleted.
+
+2001-08-01 David Billinghurst <David.Billinghurst@riotinto.com>
+
+ * g77.dg/fbackslash.f
+ * g77.dg/fcase-preserve.f
+ * g77.dg/ff90-1.f
+ * g77.dg/ffixed-line-length-0.f
+ * g77.dg/ffixed-line-length-132.f
+ * g77.dg/ffixed-line-length-7.f
+ * g77.dg/ffixed-line-length-72.f
+ * g77.dg/ffixed-line-length-none.f
+ * g77.dg/ffree-form-1.f
+ * g77.dg/fno-backslash.f
+ * g77.dg/fno-f90-1.f
+ * g77.dg/fno-fixed-form-1.f
+ * g77.dg/fno-onetrip.f
+ * g77.dg/fno-typeless-boz.f
+ * g77.dg/fno-underscoring.f
+ * g77.dg/fno-vxt-1.f
+ * g77.dg/fonetrip.f
+ * g77.dg/ftypeless-boz.f
+ * g77.dg/fugly-assumed.f
+ * g77.dg/funderscoring.f
+ * g77.dg/fvxt-1.f
+
2001-08-01 Ziemowit Laski <zlaski@apple.com>
* objc.dg/fwd-proto-1.m: New.
diff --git a/gcc/testsuite/g77.dg/fbackslash.f b/gcc/testsuite/g77.dg/fbackslash.f
new file mode 100644
index 00000000000..d2227adb67b
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fbackslash.f
@@ -0,0 +1,7 @@
+C Test compiler flags: -fbackslash
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do run }
+C { dg-options "-fbackslash" }
+ if ( len('A\nB') .ne. 3 ) call abort
+ end
diff --git a/gcc/testsuite/g77.dg/fcase-preserve.f b/gcc/testsuite/g77.dg/fcase-preserve.f
new file mode 100644
index 00000000000..f1d1eab6fd4
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fcase-preserve.f
@@ -0,0 +1,9 @@
+C Test compiler flags: -fcase-preserve
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do run }
+C { dg-options "-fcase-preserve" }
+ i = 3
+ I = 4
+ if ( i .ne. 3 ) call abort
+ end
diff --git a/gcc/testsuite/g77.dg/ff90-1.f b/gcc/testsuite/g77.dg/ff90-1.f
new file mode 100644
index 00000000000..2120f530ef1
--- /dev/null
+++ b/gcc/testsuite/g77.dg/ff90-1.f
@@ -0,0 +1,15 @@
+C Test compiler flags: -ff90
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C Read the g77 manual entry on CMPAMBIG
+C
+C { dg-do run }
+C { dg-options "-ff90" }
+ double complex z
+ z = (2.0d0,1.0d0)
+ call s(real(z))
+ end
+ subroutine s(x)
+ double precision x
+ if ( abs(z-2.0d0) .gt. 1.0e-5 ) call abort
+ end
diff --git a/gcc/testsuite/g77.dg/ffixed-line-length-0.f b/gcc/testsuite/g77.dg/ffixed-line-length-0.f
new file mode 100644
index 00000000000..80c4f3f56ca
--- /dev/null
+++ b/gcc/testsuite/g77.dg/ffixed-line-length-0.f
@@ -0,0 +1,7 @@
+C Test compiler flags: -ffixed-line-length-0
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do compile }
+C { dg-options "-ffixed-line-length-0" }
+C The next line has length 257
+ en d
diff --git a/gcc/testsuite/g77.dg/ffixed-line-length-132.f b/gcc/testsuite/g77.dg/ffixed-line-length-132.f
new file mode 100644
index 00000000000..6101696758c
--- /dev/null
+++ b/gcc/testsuite/g77.dg/ffixed-line-length-132.f
@@ -0,0 +1,7 @@
+C Test compiler flags: -ffixed-line-length-132
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do compile }
+C { dg-options "-ffixed-line-length-132" }
+c23456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012
+ en d*
diff --git a/gcc/testsuite/g77.dg/ffixed-line-length-7.f b/gcc/testsuite/g77.dg/ffixed-line-length-7.f
new file mode 100644
index 00000000000..8a9abf48050
--- /dev/null
+++ b/gcc/testsuite/g77.dg/ffixed-line-length-7.f
@@ -0,0 +1,8 @@
+C Test compiler flags: -ffixed-line-length-7
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do compile }
+C { dg-options "-ffixed-line-length-7" }
+ e*
+ $n*
+ $d*
diff --git a/gcc/testsuite/g77.dg/ffixed-line-length-72.f b/gcc/testsuite/g77.dg/ffixed-line-length-72.f
new file mode 100644
index 00000000000..8a2fad1fad2
--- /dev/null
+++ b/gcc/testsuite/g77.dg/ffixed-line-length-72.f
@@ -0,0 +1,7 @@
+C Test compiler flags: -ffixed-line-length-72
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do compile }
+C { dg-options "-ffixed-line-length-72" }
+c2345678901234567890123456789012345678901234567890123456789012345678901234567890
+ en d*
diff --git a/gcc/testsuite/g77.dg/ffixed-line-length-none.f b/gcc/testsuite/g77.dg/ffixed-line-length-none.f
new file mode 100644
index 00000000000..b4a50147f12
--- /dev/null
+++ b/gcc/testsuite/g77.dg/ffixed-line-length-none.f
@@ -0,0 +1,7 @@
+C Test compiler flags: -ffixed-line-length-none
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do compile }
+C { dg-options "-ffixed-line-length-none" }
+C The next line has length 257
+ en d
diff --git a/gcc/testsuite/g77.dg/ffree-form-1.f b/gcc/testsuite/g77.dg/ffree-form-1.f
new file mode 100644
index 00000000000..88ddeefb32c
--- /dev/null
+++ b/gcc/testsuite/g77.dg/ffree-form-1.f
@@ -0,0 +1,6 @@
+! Test compiler flags: -ffree-form
+! Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+!
+! { dg-do compile }
+! { dg-options "-ffree-form" }
+end
diff --git a/gcc/testsuite/g77.dg/fno-backslash.f b/gcc/testsuite/g77.dg/fno-backslash.f
new file mode 100644
index 00000000000..7488cb6e98e
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fno-backslash.f
@@ -0,0 +1,7 @@
+C Test compiler flags: -fno-backslash
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do run }
+C { dg-options "-fno-backslash" }
+ if ( len('A\nB') .ne. 4 ) call abort
+ end
diff --git a/gcc/testsuite/g77.dg/fno-f90-1.f b/gcc/testsuite/g77.dg/fno-f90-1.f
new file mode 100644
index 00000000000..ac0f967505b
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fno-f90-1.f
@@ -0,0 +1,15 @@
+C Test compiler flags: -fno-f90
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C Read the g77 manual entry on CMPAMBIG
+C
+C { dg-do run }
+C { dg-options "-fno-f90 -fugly-complex" }
+ double complex z
+ z = (2.0d0,1.0d0)
+ call s(real(z))
+ end
+ subroutine s(x)
+ real x
+ if ( abs(x-2.0) .gt. 1.0e-5 ) call abort
+ end
diff --git a/gcc/testsuite/g77.dg/fno-fixed-form-1.f b/gcc/testsuite/g77.dg/fno-fixed-form-1.f
new file mode 100644
index 00000000000..df2dd1d70e5
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fno-fixed-form-1.f
@@ -0,0 +1,6 @@
+! Test compiler flags: -fno-fixed-form
+! Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+!
+! { dg-do compile }
+! { dg-options "-fno-fixed-form" }
+end
diff --git a/gcc/testsuite/g77.dg/fno-onetrip.f b/gcc/testsuite/g77.dg/fno-onetrip.f
new file mode 100644
index 00000000000..781e272f972
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fno-onetrip.f
@@ -0,0 +1,9 @@
+C Test compiler flags: -fno-onetrip
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do run }
+C { dg-options "-fno-onetrip -w" }
+ do i = 1, 0
+ call abort
+ end do
+ end
diff --git a/gcc/testsuite/g77.dg/fno-typeless-boz.f b/gcc/testsuite/g77.dg/fno-typeless-boz.f
new file mode 100644
index 00000000000..3faa550cce8
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fno-typeless-boz.f
@@ -0,0 +1,10 @@
+C Test compiler flags: -fno-typeless-boz
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do run }
+C { dg-options "-fno-typeless-boz" }
+ equivalence (i,r)
+ r = Z'ABCD1234'
+ j = Z'ABCD1234'
+ if ( j .eq. i ) call abort
+ end
diff --git a/gcc/testsuite/g77.dg/fno-underscoring.f b/gcc/testsuite/g77.dg/fno-underscoring.f
new file mode 100644
index 00000000000..b91320b4c0b
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fno-underscoring.f
@@ -0,0 +1,8 @@
+C Test compiler flags: -fno-underscoring
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do compile }
+C { dg-options "-fno-underscoring" }
+ call aaabbbccc
+ end
+C { dg-final { scan-assembler-not "aaabbbccc_" } }
diff --git a/gcc/testsuite/g77.dg/fno-vxt-1.f b/gcc/testsuite/g77.dg/fno-vxt-1.f
new file mode 100644
index 00000000000..1277fb50c6b
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fno-vxt-1.f
@@ -0,0 +1,10 @@
+C Test compiler flags: -fno-vxt
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do run }
+C { dg-options "-fno-vxt" }
+ i = 0
+ !1
+ if ( i .ne. 0 ) call exit
+ call abort
+ END
diff --git a/gcc/testsuite/g77.dg/fonetrip.f b/gcc/testsuite/g77.dg/fonetrip.f
new file mode 100644
index 00000000000..dec61bcb364
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fonetrip.f
@@ -0,0 +1,10 @@
+C Test compiler flags: -fonetrip
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do run }
+C { dg-options "-fonetrip -w" }
+ do i = 1, 0
+ call exit
+ end do
+ call abort
+ end
diff --git a/gcc/testsuite/g77.dg/ftypeless-boz.f b/gcc/testsuite/g77.dg/ftypeless-boz.f
new file mode 100644
index 00000000000..b72cb177546
--- /dev/null
+++ b/gcc/testsuite/g77.dg/ftypeless-boz.f
@@ -0,0 +1,10 @@
+C Test compiler flags: -ftypeless-boz
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do run }
+C { dg-options "-ftypeless-boz" }
+ equivalence (i,r)
+ r = Z'ABCD1234'
+ j = Z'ABCD1234'
+ if ( j .ne. i ) call abort
+ end
diff --git a/gcc/testsuite/g77.dg/fugly-assumed.f b/gcc/testsuite/g77.dg/fugly-assumed.f
new file mode 100644
index 00000000000..a45e9c8e2b7
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fugly-assumed.f
@@ -0,0 +1,9 @@
+C Test compiler flags: -fugly-assumed
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do compile }
+C { dg-options "-fugly-assumed" }
+ function f(i)
+ integer i(1)
+ f = i(1)+i(2)
+ end
diff --git a/gcc/testsuite/g77.dg/funderscoring.f b/gcc/testsuite/g77.dg/funderscoring.f
new file mode 100644
index 00000000000..720b3a7e3e1
--- /dev/null
+++ b/gcc/testsuite/g77.dg/funderscoring.f
@@ -0,0 +1,8 @@
+C Test compiler flags: -funderscoring
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do compile }
+C { dg-options "-funderscoring" }
+ call aaabbbccc
+ end
+C { dg-final { scan-assembler "aaabbbccc_" } }
diff --git a/gcc/testsuite/g77.dg/fvxt-1.f b/gcc/testsuite/g77.dg/fvxt-1.f
new file mode 100644
index 00000000000..0cde4f8a36f
--- /dev/null
+++ b/gcc/testsuite/g77.dg/fvxt-1.f
@@ -0,0 +1,10 @@
+C Test compiler flags: -fvxt
+C Origin: David Billinghurst <David.Billinghurst@riotinto.com>
+C
+C { dg-do run }
+C { dg-options "-fvxt" }
+ i = 0
+ !1
+ if ( i .eq. 0 ) call exit
+ call abort
+ END
diff --git a/gcc/testsuite/lib/g77.exp b/gcc/testsuite/lib/g77.exp
index d508b953e26..dad392ff884 100644
--- a/gcc/testsuite/lib/g77.exp
+++ b/gcc/testsuite/lib/g77.exp
@@ -24,6 +24,8 @@
# They are also used by the various testsuites to define the environment:
# where to find stdio.h, libc.a, etc.
+load_lib gcc-defs.exp
+
#
# G77_UNDER_TEST is the compiler under test.
#
@@ -151,79 +153,6 @@ proc g77_target_compile { source dest type options } {
return [target_compile $source $dest $type $options]
}
-#
-# g77_pass -- utility to record a testcase passed
-#
-
-proc g77_pass { testcase cflags } {
- if { "$cflags" == "" } {
- pass "$testcase"
- } else {
- pass "$testcase, $cflags"
- }
-}
-
-#
-# g77_fail -- utility to record a testcase failed
-#
-
-proc g77_fail { testcase cflags } {
- if { "$cflags" == "" } {
- fail "$testcase"
- } else {
- fail "$testcase, $cflags"
- }
-}
-
-#
-# g77_finish -- called at the end of every .exp script that calls g77_init
-#
-# The purpose of this proc is to hide all quirks of the testing environment
-# from the testsuites. It also exists to undo anything that g77_init did
-# (that needs undoing).
-#
-
-proc g77_finish { } {
- # The testing harness apparently requires this.
- global errorInfo;
-
- if [info exists errorInfo] then {
- unset errorInfo
- }
-
- # Might as well reset these (keeps our caller from wondering whether
- # s/he has to or not).
- global prms_id bug_id
- set prms_id 0
- set bug_id 0
-}
-
-proc g77_exit { } {
- global gluefile;
-
- if [info exists gluefile] {
- file_on_build delete $gluefile;
- unset gluefile;
- }
-}
-
-# If this is an older version of dejagnu (without runtest_file_p),
-# provide one and assume the old syntax: foo1.exp bar1.c foo2.exp bar2.c.
-# This can be deleted after next dejagnu release.
-
-if { [info procs runtest_file_p] == "" } then {
- proc runtest_file_p { runtests testcase } {
- if { $runtests != "" && [regexp "\[.\]\[cC\]" $runtests] } then {
- if { [lsearch $runtests [file tail $testcase]] >= 0 } then {
- return 1
- } else {
- return 0
- }
- }
- return 1
- }
-}
-
# Provide a definition of this if missing (delete after next dejagnu release).
if { [info procs prune_warnings] == "" } then {
@@ -232,23 +161,6 @@ if { [info procs prune_warnings] == "" } then {
}
}
-# Utility used by mike-gcc.exp and c-torture.exp.
-# Check the compiler(/assembler/linker) output for text indicating that
-# the testcase should be marked as "unsupported".
-#
-# When dealing with a large number of tests, it's difficult to weed out the
-# ones that are too big for a particular cpu (eg: 16 bit with a small amount
-# of memory). There are various ways to deal with this. Here's one.
-# Fortunately, all of the cases where this is likely to happen will be using
-# gld so we can tell what the error text will look like.
-
-proc ${tool}_check_unsupported_p { output } {
- if [regexp "(^|\n)\[^\n\]*: region \[^\n\]* is full" $output] {
- return "memory full"
- }
- return ""
-}
-
# Prune messages from g77 that aren't useful.
proc prune_g77_output { text } {