
#11204: Recompilation checking stochastically broken on Darwin -----------------------------+---------------------------------------- Reporter: bgamari | Owner: Type: bug | Status: new Priority: normal | Milestone: 8.2.1 Component: Compiler | Version: 7.11 Resolution: | Keywords: Operating System: MacOS X | Architecture: Unknown/Multiple Type of failure: Other | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -----------------------------+---------------------------------------- Description changed by bgamari: Old description:
The `retc001` test usually fails on Darwin. Unfortunately, it also sometimes passes.
Failures look like this, {{{ =====> retc001(normal) 1 of 1 [0, 0, 0] cd . && $MAKE -s --no-print-directory retc001 retc001.run.stdout 2> retc001.run.stderr Actual stderr output differs from expected: --- ./retc001.stderr.normalised 2015-12-11 23:02:23.000000000 +0200 +++ ./retc001.run.stderr.normalised 2015-12-11 23:02:23.000000000 +0200 @@ -1,2 +0,0 @@ - -C.hs:3:11: Module ‘B’ does not export ‘foo’ \ No newline at end of file Actual stdout output differs from expected: --- ./retc001.stdout.normalised 2015-12-11 23:02:23.000000000 +0200 +++ ./retc001.run.stdout.normalised 2015-12-11 23:02:23.000000000 +0200 @@ -3,5 +3,3 @@ [3 of 3] Compiling Main ( C.hs, nothing ) Middle End -[2 of 3] Compiling B ( B.hs, nothing ) -[3 of 3] Compiling Main ( C.hs, nothing ) [B changed] \ No newline at end of file *** unexpected failure for retc001(normal) }}}
I suspect the problem is mtime resolution as if I apply the following patch it almost always passes, {{{ diff --git a/testsuite/tests/driver/retc001/Makefile b/testsuite/tests/driver/retc001/Makefile index a3cf6eb..bb1eca8 100644 --- a/testsuite/tests/driver/retc001/Makefile +++ b/testsuite/tests/driver/retc001/Makefile @@ -20,5 +20,6 @@ retc001: clean echo 'Middle' '$(TEST_HC)' $(TEST_HC_OPTS_NO_RECOMP) -fno-code -fwrite- interface --make C.hs echo 'End' + sleep 1 cp B2.hs B.hs -'$(TEST_HC)' $(TEST_HC_OPTS_NO_RECOMP) -fno-code -fwrite- interface --make C.hs }}}
New description: The `retc001` test usually fails on Darwin. Unfortunately, it also sometimes passes. Failures look like this, {{{ =====> retc001(normal) 1 of 1 [0, 0, 0] cd . && $MAKE -s --no-print-directory retc001 retc001.run.stdout 2> retc001.run.stderr Actual stderr output differs from expected: --- ./retc001.stderr.normalised 2015-12-11 23:02:23.000000000 +0200 +++ ./retc001.run.stderr.normalised 2015-12-11 23:02:23.000000000 +0200 @@ -1,2 +0,0 @@ - -C.hs:3:11: Module ‘B’ does not export ‘foo’ \ No newline at end of file Actual stdout output differs from expected: --- ./retc001.stdout.normalised 2015-12-11 23:02:23.000000000 +0200 +++ ./retc001.run.stdout.normalised 2015-12-11 23:02:23.000000000 +0200 @@ -3,5 +3,3 @@ [3 of 3] Compiling Main ( C.hs, nothing ) Middle End -[2 of 3] Compiling B ( B.hs, nothing ) -[3 of 3] Compiling Main ( C.hs, nothing ) [B changed] \ No newline at end of file *** unexpected failure for retc001(normal) }}} I suspect the problem is mtime resolution as the test nearly always passes with the following patch, {{{ diff --git a/testsuite/tests/driver/retc001/Makefile b/testsuite/tests/driver/retc001/Makefile index a3cf6eb..bb1eca8 100644 --- a/testsuite/tests/driver/retc001/Makefile +++ b/testsuite/tests/driver/retc001/Makefile @@ -20,5 +20,6 @@ retc001: clean echo 'Middle' '$(TEST_HC)' $(TEST_HC_OPTS_NO_RECOMP) -fno-code -fwrite-interface --make C.hs echo 'End' + sleep 1 cp B2.hs B.hs -'$(TEST_HC)' $(TEST_HC_OPTS_NO_RECOMP) -fno-code -fwrite- interface --make C.hs }}} -- -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11204#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler