summaryrefslogtreecommitdiff
path: root/testsuite
diff options
context:
space:
mode:
authorPeter Trommler <ptrommler@acm.org>2016-12-26 10:04:54 -0500
committerBen Gamari <ben@smart-cactus.org>2016-12-27 12:44:25 -0500
commit4dec7d191fbc26276cc2c8306d9d03e71e277979 (patch)
treeb7dbe0c3ebd757acdac5f0459e6dfd1fa6704278 /testsuite
parent88f5add0280788d424c9df5f751a73e73a1a4284 (diff)
downloadhaskell-4dec7d191fbc26276cc2c8306d9d03e71e277979.tar.gz
Testsuite: Skip failing tests on PowerPC 64-bit
The Power ISA says the result of a division by zero is undefined. So ignore stdout on PowerPC 64-bit systems. Disable ext-interp tests on 64-bit PowerPC. We don't have support for PowerPC 64-bit ELF in the RTS linker, which is needed for the external interpreter. Test Plan: ./validate Reviewers: austin, simonmar, hvr, erikd, bgamari Reviewed By: bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2782
Diffstat (limited to 'testsuite')
-rw-r--r--testsuite/config/ghc3
-rwxr-xr-xtestsuite/tests/ghci/scripts/all.T3
-rw-r--r--testsuite/tests/rts/all.T4
-rw-r--r--testsuite/tests/th/all.T5
4 files changed, 10 insertions, 5 deletions
diff --git a/testsuite/config/ghc b/testsuite/config/ghc
index b9991d7729..b126580863 100644
--- a/testsuite/config/ghc
+++ b/testsuite/config/ghc
@@ -165,6 +165,9 @@ def get_compiler_info():
s = re.sub('[\r\n]', '', s)
rtsInfoDict = dict(eval(s))
+ # external interpreter needs RTS linker support
+ config.have_ext_interp = compilerInfoDict["target has RTS linker"] == "YES"
+
# See Note [Replacing backward slashes in config.libdir].
config.libdir = compilerInfoDict['LibDir'].replace('\\', '/')
diff --git a/testsuite/tests/ghci/scripts/all.T b/testsuite/tests/ghci/scripts/all.T
index 08ae3a2e87..d448a12d9f 100755
--- a/testsuite/tests/ghci/scripts/all.T
+++ b/testsuite/tests/ghci/scripts/all.T
@@ -97,7 +97,8 @@ test('ghci056',
test('ghci057', normal, ghci_script, ['ghci057.script'])
test('ghci060', normal, ghci_script, ['ghci060.script'])
test('ghci061', normal, ghci_script, ['ghci061.script'])
-test('ghci062', extra_ways(['ghci-ext']), ghci_script, ['ghci062.script'])
+test('ghci062', when(config.have_ext_interp, extra_ways(['ghci-ext'])),
+ ghci_script, ['ghci062.script'])
test('T2452', normal, ghci_script, ['T2452.script'])
test('T2766', normal, ghci_script, ['T2766.script'])
diff --git a/testsuite/tests/rts/all.T b/testsuite/tests/rts/all.T
index a3b16f07b9..cf8e90419e 100644
--- a/testsuite/tests/rts/all.T
+++ b/testsuite/tests/rts/all.T
@@ -46,8 +46,8 @@ test('divbyzero',
# do not generate an exception (interrupt) for integer
# division by zero but the result is undefined.
# C programs compiled with gcc exit normally, so do we.
- when(platform('powerpc64-unknown-linux'), exit_code(0)),
- when(platform('powerpc64le-unknown-linux'), exit_code(0)),
+ when(platform('powerpc64-unknown-linux'), [ignore_stdout, exit_code(0)]),
+ when(platform('powerpc64le-unknown-linux'), [ignore_stdout, exit_code(0)]),
when(opsys('mingw32'), exit_code(1)),
# The output under OS X is too unstable to readily compare
when(platform('i386-apple-darwin'), [ignore_stderr, exit_code(136)]),
diff --git a/testsuite/tests/th/all.T b/testsuite/tests/th/all.T
index 66a7a9fc87..cc9fa4dc96 100644
--- a/testsuite/tests/th/all.T
+++ b/testsuite/tests/th/all.T
@@ -9,8 +9,9 @@ def f(name, opts):
setTestOpts(f)
setTestOpts(req_interp)
# TH should work with -fexternal-interpreter too
-setTestOpts(extra_ways(['ext-interp']))
-setTestOpts(only_ways(['normal','ghci','ext-interp']))
+if config.have_ext_interp :
+ setTestOpts(extra_ways(['ext-interp']))
+ setTestOpts(only_ways(['normal','ghci','ext-interp']))
test('TH_mkName', normal, compile, ['-v0'])
test('TH_1tuple', normal, compile_fail, ['-v0'])