[GHC] #15163: non coercion variable in coVarKindsTypesRole
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.5 (Type checker) | Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: None/Unknown Unknown/Multiple | Test Case: T14732 | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- It is triggered by T14732... in the `profasm` way, and only that one. {{{#!sh $ make fulltest TEST="T14732" THREADS=4 =====> T14732(profasm) 1 of 1 [0, 0, 0] cd "./typecheck/should_compile/T14732.run" && "/home/alp/WT/ghc-slow- validate/inplace/test spaces/ghc-stage2" -c T14732.hs -dcore-lint -dcmm- lint -no-user-package-db -rtsopts -fno-warn-missed-specialisations -fshow- warning-groups -fdiagnostics-color=never -fno-diagnostics-show-caret -dno- debug-output -fno-warn-incomplete-patterns -O -prof -static -fprof-auto Compile failed (exit code 1) errors were: ghc-stage2: panic! (the 'impossible' happened) (GHC version 8.5.20180511 for x86_64-unknown-linux): coVarKindsTypesRole, non coercion variable as_atY Vector a_a2sO Call stack: CallStack (from HasCallStack): callStackDoc, called at compiler/utils/Outputable.hs:1162:37 in ghc:Outputable pprPanic, called at compiler/types/Coercion.hs:376:16 in ghc:Coercion Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug *** unexpected failure for T14732(profasm) }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Compiler (Type | Version: 8.5 checker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by Simon Peyton Jones <simonpj@…>): In [changeset:"d191db48c43469ee1818887715bcbc5c0eb1d91f/ghc" d191db48/ghc]: {{{ #!CommitTicketReference repository="ghc" revision="d191db48c43469ee1818887715bcbc5c0eb1d91f" Don't expose strictness when sm_inline is False This is very much a corner case, but Trac #15163 showed that if you have a RULE like forall x. f (g x) = ..x.. and g = undefined, then the simplifier is likely to discard that 'x' argument. It is usually right to do so; but not here because then x is used on the right but not bound on the left. The fix is a narrow one, aimed at this rather pathalogical case. See Note [Do not expose strictness if sm_inline=False] in SimplUtils. }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:2> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Compiler (Type | Version: 8.5 checker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by Simon Peyton Jones <simonpj@…>): In [changeset:"86bba7d519fb6050f78b7e3bac2b3f54273fd70e/ghc" 86bba7d/ghc]: {{{ #!CommitTicketReference repository="ghc" revision="86bba7d519fb6050f78b7e3bac2b3f54273fd70e" Add missing check to isReflCoVar_maybe isReflCoVar_maybe is called, by CoreLint, on all sorts of Vars (tyvars, term vars, coercion vars). But it was silently assuming that it was always called on a CoVar, and as a result could crash fatally. This is the immediate cause of the panic in Trac #15163. It's easy to fix. NB: this does not completely fix Trac #15163; more to come }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:1> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Compiler (Type | Version: 8.5 checker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by simonpj): I believe I've fixed this. Would anyone care to check and close? -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:3> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Compiler (Type | Version: 8.5 checker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by alpmestan): I ran the test with a (quickest flavoured) GHC from commit a32c8f7514c8192fa064537fb93d5a5c224991a0, and I do get: {{{ Unexpected passes: typecheck/should_compile/T14732.run T14732 [unexpected] (profasm) }}} I'll change that expectation in a new diff soon and close this ticket when it's merged. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:4> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler (Type | Version: 8.5 checker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): D4725 Wiki Page: | -------------------------------------+------------------------------------- Changes (by alpmestan): * status: new => patch * differential: => D4725 -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:5> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler (Type | Version: 8.5 checker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab D4725 Wiki Page: | -------------------------------------+------------------------------------- Changes (by alpmestan): * differential: D4725 => Phab D4725 -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:6> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler (Type | Version: 8.5 checker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab: D4725 Wiki Page: | -------------------------------------+------------------------------------- Changes (by alpmestan): * differential: Phab D4725 => Phab: D4725 -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:7> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler (Type | Version: 8.5 checker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D4725 Wiki Page: | -------------------------------------+------------------------------------- Changes (by RyanGlScott): * differential: Phab: D4725 => Phab:D4725 -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:8> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: merge Priority: normal | Milestone: Component: Compiler (Type | Version: 8.5 checker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D4725 Wiki Page: | -------------------------------------+------------------------------------- Changes (by alpmestan): * status: patch => merge -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:9> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: merge Priority: normal | Milestone: 8.4.4 Component: Compiler (Type | Version: 8.5 checker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D4725 Wiki Page: | -------------------------------------+------------------------------------- Changes (by bgamari): * milestone: => 8.4.4 -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:10> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: merge Priority: normal | Milestone: 8.4.4 Component: Compiler (Type | Version: 8.5 checker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D4725 Wiki Page: | -------------------------------------+------------------------------------- Comment (by Ben Gamari <ben@…>): In [changeset:"c65159dcf401d36e8920f43fec300264533642b9/ghc" c65159dc/ghc]: {{{ #!CommitTicketReference repository="ghc" revision="c65159dcf401d36e8920f43fec300264533642b9" T14732 now passes with the profasm way Simon PJ recently fixed the problem behind this failure so we can now expect this test to pass in all ways again. The fixes got introduced in the following commits: 86bba7d519fb6050f78b7e3bac2b3f54273fd70e d191db48c43469ee1818887715bcbc5c0eb1d91f Test Plan: T14732 (profasm way) Reviewers: bgamari, RyanGlScott, simonpj Reviewed By: RyanGlScott, simonpj Subscribers: simonpj, RyanGlScott, rwbarton, thomie, carter GHC Trac Issues: #15163 Differential Revision: https://phabricator.haskell.org/D4725 }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:11> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#15163: non coercion variable in coVarKindsTypesRole -------------------------------------+------------------------------------- Reporter: alpmestan | Owner: (none) Type: bug | Status: closed Priority: normal | Milestone: 8.4.4 Component: Compiler (Type | Version: 8.5 checker) | Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: T14732 Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Phab:D4725 Wiki Page: | -------------------------------------+------------------------------------- Changes (by alpmestan): * status: merge => closed * resolution: => fixed -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15163#comment:12> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
participants (1)
-
GHC