[commit: ghc] ghc-8.2: testsuite: Allow join007 to pass on 32-bit machines (df21c54)

git at git.haskell.org git at git.haskell.org
Mon Mar 27 03:00:49 UTC 2017


Repository : ssh://git@git.haskell.org/ghc

On branch  : ghc-8.2
Link       : http://ghc.haskell.org/trac/ghc/changeset/df21c5448618b07e0fb130be967124ecd5306494/ghc

>---------------------------------------------------------------

commit df21c5448618b07e0fb130be967124ecd5306494
Author: Ben Gamari <ben at smart-cactus.org>
Date:   Fri Mar 24 12:27:35 2017 -0400

    testsuite: Allow join007 to pass on 32-bit machines
    
    The output of the test overflows. Given that the result is stable
    regardless of whether it overflows, I just made the expected output
    word-size dependent.
    
    (cherry picked from commit aecbfb908a11991eb23b790a440efe4697ffb86a)


>---------------------------------------------------------------

df21c5448618b07e0fb130be967124ecd5306494
 testsuite/tests/perf/join_points/join007.hs                             | 2 ++
 testsuite/tests/perf/join_points/join007.stdout-ws-32                   | 1 +
 .../tests/perf/join_points/{join007.stdout => join007.stdout-ws-64}     | 0
 3 files changed, 3 insertions(+)

diff --git a/testsuite/tests/perf/join_points/join007.hs b/testsuite/tests/perf/join_points/join007.hs
index aa2f68c..59cc99b 100644
--- a/testsuite/tests/perf/join_points/join007.hs
+++ b/testsuite/tests/perf/join_points/join007.hs
@@ -39,4 +39,6 @@ enumFromToS lo hi = Stream next lo
 test :: Int -> Int -> Int
 test lo hi = sumS (filterS even (enumFromToS lo hi))
 
+-- Note that this overflows on 32-bit machines and therefore we have two stdout
+-- files
 main = print $ test 1 10000000
diff --git a/testsuite/tests/perf/join_points/join007.stdout-ws-32 b/testsuite/tests/perf/join_points/join007.stdout-ws-32
new file mode 100644
index 0000000..d4692e3
--- /dev/null
+++ b/testsuite/tests/perf/join_points/join007.stdout-ws-32
@@ -0,0 +1 @@
+-999630016
diff --git a/testsuite/tests/perf/join_points/join007.stdout b/testsuite/tests/perf/join_points/join007.stdout-ws-64
similarity index 100%
rename from testsuite/tests/perf/join_points/join007.stdout
rename to testsuite/tests/perf/join_points/join007.stdout-ws-64



More information about the ghc-commits mailing list