[GHC] #15143: Passing an IO value through several functions results in program hanging.
GHC
ghc-devs at haskell.org
Sat May 12 17:53:04 UTC 2018
#15143: Passing an IO value through several functions results in program hanging.
-------------------------------------+-------------------------------------
Reporter: Burtannia | Owner: (none)
Type: bug | Status: new
Priority: normal | Milestone: 8.6.1
Component: Compiler | Version: 8.4.2
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
Type of failure: Runtime | Unknown/Multiple
performance bug | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by osa1):
I made the slow program parametric on number of iterations. Seems like an
exponential behavior in the generated code:
{{{
$ for n ({20..30}); do time ./Slow $n; done
ObsTemp 1
./Slow $n 0,05s user 0,00s system 85% cpu 0,064 total
ObsTemp 1
./Slow $n 0,08s user 0,00s system 91% cpu 0,092 total
ObsTemp 1
./Slow $n 0,16s user 0,00s system 98% cpu 0,162 total
ObsTemp 1
./Slow $n 0,31s user 0,00s system 99% cpu 0,312 total
ObsTemp 1
./Slow $n 0,62s user 0,00s system 99% cpu 0,622 total
ObsTemp 1
./Slow $n 1,23s user 0,00s system 99% cpu 1,242 total
ObsTemp 1
./Slow $n 2,47s user 0,00s system 99% cpu 2,472 total
ObsTemp 1
./Slow $n 5,11s user 0,00s system 99% cpu 5,112 total
ObsTemp 1
./Slow $n 9,85s user 0,00s system 99% cpu 9,862 total
ObsTemp 1
./Slow $n 19,92s user 0,01s system 100% cpu 19,922 total
^C^C
}}}
Increasing the iteration count by one causes time it takes to double.5
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15143#comment:4>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list