[GHC] #11973: Simplifier ticks exhausted with complex list literal.

#11973: Simplifier ticks exhausted with complex list literal. -------------------------------------+------------------------------------- Reporter: Lokathor | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.10.3 Keywords: | Operating System: Windows Architecture: | Type of failure: Compile-time Unknown/Multiple | crash Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- So I had a working version of a module that was too slow: https://github.com/Lokathor/ludolib/blob/6e69f87762c88d7909ca259ffe69141ea4b... and then I tried to rearrange things so that the checking could short- circuit a bit and run faster. I came up with this: https://gist.github.com/Lokathor/d1e4a8cd6268835a2403423fb180a71d#file- automatagencrashesghc-hs-L172 Which loads and runs just fine in GHCi, but then when I go to compile it into a binary for benchmarking I got the following: {{{ ghc.exe: panic! (the 'impossible' happened) (GHC version 7.10.3 for x86_64-unknown-mingw32): Simplifier ticks exhausted When trying UnfoldingDone a_siVC To increase the limit, use -fsimpl-tick-factor=N (default 100) If you need to do this, let GHC HQ know, and what factor you needed To see detailed counts use -ddump-simpl-stats Total ticks: 294802 Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug }}} Setting the factor up to 1k caused it to crash out with the same problem. Setting the factor up to 10k caused GHC to just eat up nearly all of my RAM (11GB) and then stall out until I killed it a few minutes later. I tried not using -O2 during compilation, but it had the same problem anyway. With some IRC help, it was suggested to add the `-fsimple-list- literals` flag, which makes things compile and run just fine (and with the speed gain that I'd hoped for). So things work now, for some definition of "work", though I was advised to report this bad behavior anyway. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11973 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11973: Simplifier ticks exhausted with complex list literal. -------------------------------------+------------------------------------- Reporter: Lokathor | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.10.3 Resolution: | Keywords: Operating System: Windows | Architecture: Type of failure: Compile-time | Unknown/Multiple crash | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by simonpj): There's a fix in #11710 that may help. You don't give instructions to reproduce, so it's hard to tell. The fix is in the GHC 8.0 release candidate so you could give it a try. Thanks Simon -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11973#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11973: Simplifier ticks exhausted with complex list literal. -------------------------------------+------------------------------------- Reporter: Lokathor | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.10.3 Resolution: | Keywords: Operating System: Windows | Architecture: Type of failure: Compile-time | Unknown/Multiple crash | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by erikd): Just tested this on Linux. This project (at git commit f1f770241cb548) fails as reported with ghc-7.10.3 and builds successfully with ghc-8.0.0rc4. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11973#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11973: Simplifier ticks exhausted with complex list literal. -------------------------------------+------------------------------------- Reporter: Lokathor | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.10.3 Resolution: | Keywords: Operating System: Windows | Architecture: Type of failure: Compile-time | Unknown/Multiple crash | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by Lokathor): Wonderful. For historical purposes, here are the specific steps to get in position to reproduce the bug: {{{ git clone https://github.com/Lokathor/ludolib.git cd ludolib git checkout f1f7702 }}} And then build with "stack build" or make a cabal sandbox and use cabal or however you like. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11973#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11973: Simplifier ticks exhausted with complex list literal. -------------------------------------+------------------------------------- Reporter: Lokathor | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler | Version: 7.10.3 Resolution: fixed | Keywords: Operating System: Windows | Architecture: Type of failure: Compile-time | Unknown/Multiple crash | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by Lokathor): * status: new => closed * resolution: => fixed -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11973#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC