[GHC] #12077: T8761 (Make pattern synonyms work with Template Haskell) is failing on Travis

#12077: T8761 (Make pattern synonyms work with Template Haskell) is failing on Travis -------------------------------------+------------------------------------- Reporter: thomie | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Template | Version: 8.0.1 Haskell | Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: None/Unknown Unknown/Multiple | Test Case: | Blocked By: Blocking: | Related Tickets: #8761 Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- Note that Travis uses `DYNAMIC_GHC_PROGRAMS=NO`. First failure: https://travis-ci.org/ghc/ghc/builds/129738012 {{{ Actual stderr output differs from expected: --- ./th/T8761.stderr.normalised 2016-05-12 15:08:16.512921981 +0000 +++ ./th/T8761.comp.stderr.normalised 2016-05-12 15:08:16.512921981 +0000 @@ -1,7 +1,3 @@ -pattern Q1 x1_0 x2_1 x3_2 <- ((x1_0, x2_1), [x3_2], _, _) -pattern x1_0 Q2 x2_1 = ((x1_0, x2_1)) -pattern Q3 {qx3, qy3, qz3} <- ((qx3, qy3), [qz3]) where - Q3 qx3 qy3 qz3 = ((qx3, qy3), [qz3]) T8761.hs:(15,1)-(38,13): Splicing declarations do { [qx1, qy1, qz1] <- mapM (/ i -> newName $ "x" ++ show i) [1, 2, 3]; @@ -123,30 +119,6 @@ pattern Pup x <- MkUnivProv x pattern Puep :: forall a. forall b. Show b => a -> b -> (ExProv, a) pattern Puep x y <- (MkExProv y, x) -pattern T8761.P :: GHC.Types.Bool -pattern T8761.Pe :: () => forall (a0_0 :: *) . a0_0 -> T8761.Ex -pattern T8761.Pu :: forall (a0_0 :: *) . a0_0 -> a0_0 -pattern T8761.Pue :: forall (a0_0 :: *) . () => forall (b0_1 :: *) . - a0_0 -> b0_1 -> (a0_0, T8761.Ex) -pattern T8761.Pur :: forall (a0_0 :: *) . (GHC.Num.Num a0_0, - GHC.Classes.Eq a0_0) => - a0_0 -> [a0_0] -pattern T8761.Purp :: forall (a0_0 :: *) (b0_1 :: *) . (GHC.Num.Num a0_0, - GHC.Classes.Eq a0_0) => - GHC.Show.Show b0_1 => a0_0 -> b0_1 -> ([a0_0], T8761.UnivProv b0_1) -pattern T8761.Pure :: forall (a0_0 :: *) . (GHC.Num.Num a0_0, - GHC.Classes.Eq a0_0) => - forall (b0_1 :: *) . a0_0 -> b0_1 -> ([a0_0], T8761.Ex) -pattern T8761.Purep :: forall (a0_0 :: *) . (GHC.Num.Num a0_0, - GHC.Classes.Eq a0_0) => - forall (b0_1 :: *) . GHC.Show.Show b0_1 => - a0_0 -> b0_1 -> ([a0_0], T8761.ExProv) -pattern T8761.Pep :: () => forall (a0_0 :: *) . GHC.Show.Show a0_0 => - a0_0 -> T8761.ExProv -pattern T8761.Pup :: forall (a0_0 :: *) . () => GHC.Show.Show a0_0 => - a0_0 -> T8761.UnivProv a0_0 -pattern T8761.Puep :: forall (a0_0 :: *) . () => forall (b0_1 :: *) . GHC.Show.Show b0_1 => - a0_0 -> b0_1 -> (T8761.ExProv, a0_0) T8761.hs:(107,1)-(111,25): Splicing declarations do { infos <- mapM reify *** unexpected failure for T8761(normal) }}} @bollmann added the test in c079de3c43704ea88f592e441389e520313e30ad. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12077 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12077: T8761 (Make pattern synonyms work with Template Haskell) is failing on
Travis
-------------------------------------+-------------------------------------
Reporter: thomie | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: Template Haskell | Version: 8.0.1
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: #8761 | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by Thomas Miedema

#12077: DYNAMIC_GHC_PROGRAMS=NO: T8761 is failing (Make pattern synonyms work with Template Haskell) -------------------------------------+------------------------------------- Reporter: thomie | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Template Haskell | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: th/T8761 Blocked By: | Blocking: Related Tickets: #8761 | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by thomie): * testcase: => th/T8761 @@ -1,2 +1,0 @@ - Note that Travis uses `DYNAMIC_GHC_PROGRAMS=NO`. - New description: First failure: https://travis-ci.org/ghc/ghc/builds/129738012 {{{ Actual stderr output differs from expected: --- ./th/T8761.stderr.normalised 2016-05-12 15:08:16.512921981 +0000 +++ ./th/T8761.comp.stderr.normalised 2016-05-12 15:08:16.512921981 +0000 @@ -1,7 +1,3 @@ -pattern Q1 x1_0 x2_1 x3_2 <- ((x1_0, x2_1), [x3_2], _, _) -pattern x1_0 Q2 x2_1 = ((x1_0, x2_1)) -pattern Q3 {qx3, qy3, qz3} <- ((qx3, qy3), [qz3]) where - Q3 qx3 qy3 qz3 = ((qx3, qy3), [qz3]) T8761.hs:(15,1)-(38,13): Splicing declarations do { [qx1, qy1, qz1] <- mapM (/ i -> newName $ "x" ++ show i) [1, 2, 3]; @@ -123,30 +119,6 @@ pattern Pup x <- MkUnivProv x pattern Puep :: forall a. forall b. Show b => a -> b -> (ExProv, a) pattern Puep x y <- (MkExProv y, x) -pattern T8761.P :: GHC.Types.Bool -pattern T8761.Pe :: () => forall (a0_0 :: *) . a0_0 -> T8761.Ex -pattern T8761.Pu :: forall (a0_0 :: *) . a0_0 -> a0_0 -pattern T8761.Pue :: forall (a0_0 :: *) . () => forall (b0_1 :: *) . - a0_0 -> b0_1 -> (a0_0, T8761.Ex) -pattern T8761.Pur :: forall (a0_0 :: *) . (GHC.Num.Num a0_0, - GHC.Classes.Eq a0_0) => - a0_0 -> [a0_0] -pattern T8761.Purp :: forall (a0_0 :: *) (b0_1 :: *) . (GHC.Num.Num a0_0, - GHC.Classes.Eq a0_0) => - GHC.Show.Show b0_1 => a0_0 -> b0_1 -> ([a0_0], T8761.UnivProv b0_1) -pattern T8761.Pure :: forall (a0_0 :: *) . (GHC.Num.Num a0_0, - GHC.Classes.Eq a0_0) => - forall (b0_1 :: *) . a0_0 -> b0_1 -> ([a0_0], T8761.Ex) -pattern T8761.Purep :: forall (a0_0 :: *) . (GHC.Num.Num a0_0, - GHC.Classes.Eq a0_0) => - forall (b0_1 :: *) . GHC.Show.Show b0_1 => - a0_0 -> b0_1 -> ([a0_0], T8761.ExProv) -pattern T8761.Pep :: () => forall (a0_0 :: *) . GHC.Show.Show a0_0 => - a0_0 -> T8761.ExProv -pattern T8761.Pup :: forall (a0_0 :: *) . () => GHC.Show.Show a0_0 => - a0_0 -> T8761.UnivProv a0_0 -pattern T8761.Puep :: forall (a0_0 :: *) . () => forall (b0_1 :: *) . GHC.Show.Show b0_1 => - a0_0 -> b0_1 -> (T8761.ExProv, a0_0) T8761.hs:(107,1)-(111,25): Splicing declarations do { infos <- mapM reify *** unexpected failure for T8761(normal) }}} @bollmann added the test in c079de3c43704ea88f592e441389e520313e30ad. -- -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12077#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12077: DYNAMIC_GHC_PROGRAMS=NO: T8761 is failing (Make pattern synonyms work with Template Haskell) -------------------------------------+------------------------------------- Reporter: thomie | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Template Haskell | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: th/T8761 Blocked By: | Blocking: Related Tickets: #8761 | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by bollmann): hmm, it seems as if doing IO during compilation isn't supported with DYNAMIC_GHC_PROGRAMS=NO enabled? Where do I set this option to be able to verify this behavior on my local machine? Is it in `mk/build.mk` somewhere? It'd be great if anyone could tell me so, that I can take a deeper look at a fix. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12077#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12077: DYNAMIC_GHC_PROGRAMS=NO: T8761 is failing (Make pattern synonyms work with Template Haskell) -------------------------------------+------------------------------------- Reporter: thomie | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Template Haskell | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: th/T8761 Blocked By: | Blocking: Related Tickets: #8761 | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by thomie):
Where do I set this option to be able to verify this behavior on my local machine? Is it in mk/build.mk somewhere?
Yes. When `DYNAMIC_GHC_PROGRAMS=NO`, GHCi uses the Runtime System linker (rts/Linker.c) instead of the system installed dynamic linker. Thanks for looking into it. It might be a [https://ghc.haskell.org/trac/ghc/query?status=!closed&component=Runtime+System+(Linker) known issue with the Runtime System Linker], I'm not sure. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12077#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12077: DYNAMIC_GHC_PROGRAMS=NO: T8761 is failing (Make pattern synonyms work with Template Haskell) -------------------------------------+------------------------------------- Reporter: thomie | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Template Haskell | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: th/T8761 Blocked By: | Blocking: Related Tickets: #8761 | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by bollmann): hmm, putting `DYNAMIC_GHC_PROGRAMS=NO` into `mk/build.mk` and then running `./boot && ./configure && make` results in an error: {{{ Configuring ghc-prim-0.5.0.0... ghc-cabal: Cannot find the program 'ghc'. User-specified path '/home/dominik/ghc/inplace/bin/ghc-stage1' does not refer to an executable and the program is not on the system path. libraries/ghc-prim/ghc.mk:4: recipe for target 'libraries/ghc-prim/dist- install/package-data.mk' failed make[1]: *** [libraries/ghc-prim/dist-install/package-data.mk] Error 1 Makefile:129: recipe for target 'all' failed make: *** [all] Error 2 }}} I don't really understand what's happening here. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12077#comment:5 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12077: DYNAMIC_GHC_PROGRAMS=NO: T8761 is failing (Make pattern synonyms work with Template Haskell) -------------------------------------+------------------------------------- Reporter: thomie | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Template Haskell | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: th/T8761 Blocked By: | Blocking: Related Tickets: #8761 | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by thomie): Remove `stage=2` from `mk/build.mk`. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12077#comment:6 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12077: DYNAMIC_GHC_PROGRAMS=NO: T8761 is failing (Make pattern synonyms work with Template Haskell) -------------------------------------+------------------------------------- Reporter: thomie | Owner: simonmar Type: bug | Status: new Priority: normal | Milestone: 8.0.2 Component: Template Haskell | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: th/T8761 Blocked By: | Blocking: Related Tickets: #8761 | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by simonmar): * owner: => simonmar * milestone: => 8.0.2 Comment: This is just a buffering issue. GHC does `hSetBuffering stdout LineBuffering`, but that only applies to the interpreter's stdout when GHC is dynamic, because there GHC and the interpreter share a `stdout`. In other configurations, GHC and the interpreter have different stdout Handles, and the interpreter's stdout will be block-buffered by default when output goes to a file, as it does in the testsuite. There's no easy fix that makes this just work. I'm going to make the test do `hFlush stdout` explicitly instead. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12077#comment:7 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12077: DYNAMIC_GHC_PROGRAMS=NO: T8761 is failing (Make pattern synonyms work with
Template Haskell)
-------------------------------------+-------------------------------------
Reporter: thomie | Owner: simonmar
Type: bug | Status: new
Priority: normal | Milestone: 8.0.2
Component: Template Haskell | Version: 8.0.1
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case: th/T8761
Blocked By: | Blocking:
Related Tickets: #8761 | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by Simon Marlow

#12077: DYNAMIC_GHC_PROGRAMS=NO: T8761 is failing (Make pattern synonyms work with Template Haskell) -------------------------------------+------------------------------------- Reporter: thomie | Owner: simonmar Type: bug | Status: merge Priority: normal | Milestone: 8.0.2 Component: Template Haskell | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: th/T8761 Blocked By: | Blocking: Related Tickets: #8761 | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by simonmar): * status: new => merge -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12077#comment:9 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12077: DYNAMIC_GHC_PROGRAMS=NO: T8761 is failing (Make pattern synonyms work with Template Haskell) -------------------------------------+------------------------------------- Reporter: thomie | Owner: simonmar Type: bug | Status: closed Priority: normal | Milestone: 8.2.1 Component: Template Haskell | Version: 8.1 Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: th/T8761 Blocked By: | Blocking: Related Tickets: #8761 | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by bgamari): * status: merge => closed * version: 8.0.1 => 8.1 * resolution: => fixed * milestone: 8.0.2 => 8.2.1 Comment: This test doesn't exist on `ghc-8.0` as TH support for pattern synonyms (#8761) wasn't yet merged. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12077#comment:10 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC