[GHC] #11568: Regression in nofib/shootout/k-nucleotide

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: None/Unknown Unknown/Multiple | Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- Fixing the `sizeExpr` bug in #11564 caused a regression in `nofib/shootout/k-nucleotide`. We don't know yet exactly which function was affected. See Phab:D1900 for details and some `-ddump-simpl` and `-ticky` dumps. We should investigate this before merging Phab:D1900 into a release. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by thomie): [https://perf.haskell.org/ghc/#revision/51a33924fc118d9b6c1db556c75c0d010ef95... perf.haskell.org] reports the following numbers as well: {{{ Benchmark name previous change now tests/alloc/T3064 297834384 + 3.18% 307311896 bytes tests/alloc/T5631 1164415992 + 108.27% 2425081664 bytes tests/alloc/T7257 1654893352 - 14.50% 1414893352 bytes tests/alloc/T783 489042024 + 3.47% 505987776 bytes tests/alloc/T9020 703211744 + 16.45% 818924416 bytes tests/alloc/T9872d 535824528 + 3.09% 552399688 bytes tests/alloc/T9961 731573736 + 5.10% 768861280 bytes tests/alloc/haddock.Cabal 10472403176 + 4.52% 10945830216 bytes tests/alloc/haddock.compiler 59679619080 + 4.56% 62402376816 bytes }}} Links to: #3064, #5631, #783, #9020, #9872, #9961. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 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: | -------------------------------------+------------------------------------- Changes (by bgamari): * failure: None/Unknown => Runtime performance bug -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: dfeuer Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 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: | -------------------------------------+------------------------------------- Changes (by bgamari): * owner: => dfeuer Comment: David is currently looking into this. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: dfeuer Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 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 dfeuer): According to ticky-ticky profiling, the big things being allocated (`alloc'd`) after the patch that caused the regression are `$j1` and `$j2` in `$s$wfoldMe`. Neither of these showed up in ticky-ticky before. I think `$j2` may be new after the patch, but `$j1` was there before; perhaps it was LNEed before and isn't now? I'll try to dig deeper on Sunday. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: dfeuer Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 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: | -------------------------------------+------------------------------------- Changes (by dfeuer): * Attachment "Main.dump-stg.gz" added. STG dump for HEAD c. Jan 8 2017 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: dfeuer Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 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: | -------------------------------------+------------------------------------- Changes (by dfeuer): * Attachment "headallocd.ticky" added. ticky-ticky profile for HEAD c. Jan 8, 2017 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: dfeuer Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 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 dfeuer): I'm seeing a lot of allocation of `j2_sbYy`. It seems this is not let-no- escape because it's used in non-tail position. But every use site looks identical (modulo distinctions that at least ''shouldn't'' matter). Specifically, an application of `j2_sbYy` is case-matched, and the non-`void#` portion of the result is passed to `$j3_sbZZ`. Something must be preventing GHC from seeing that `j2_sbYy` should itself call `$j3_sbZZ`. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568#comment:5 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: dfeuer Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 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 simonpj): Aha. Yes, `j2_sbYy` was born as a join-point but some subsequent transformation changed it into a non-join point. Happily [wiki:SequentCore Luke's work on join points] should nail this. I suggest you down-tools on this until Luke has his stuff committed. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568#comment:6 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: dfeuer Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 Resolution: | Keywords: JoinPoints 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: | -------------------------------------+------------------------------------- Changes (by simonpj): * keywords: => JoinPoints -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568#comment:7 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: dfeuer Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 Resolution: | Keywords: JoinPoints 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: | -------------------------------------+------------------------------------- Changes (by simonpj): * cc: maurerl@…, pdownen@…, ariola@… (added) -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568#comment:8 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: dfeuer Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 Resolution: | Keywords: JoinPoints Operating System: Unknown/Multiple | Architecture: Type of failure: Runtime | Unknown/Multiple performance bug | Test Case: Blocked By: 12988 | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by lukemaurer): Looks to me like Simon's instinct was correct. Every instance of `$j1` remains a join point now, since those pesky contexts that were getting put around the calls are getting put into `$j1` instead. In fact, `k-nucleotide` is one of the poster children for join points—it gets an 86.0% decrease in allocs. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568#comment:10 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11568: Regression in nofib/shootout/k-nucleotide -------------------------------------+------------------------------------- Reporter: simonmar | Owner: lukemaurer Type: bug | Status: new Priority: high | Milestone: 8.2.1 Component: Compiler | Version: 7.10.3 Resolution: | Keywords: JoinPoints Operating System: Unknown/Multiple | Architecture: Type of failure: Runtime | Unknown/Multiple performance bug | Test Case: Blocked By: 12988 | Blocking: Related Tickets: | Differential Rev(s): Phab:D2853 Wiki Page: | -------------------------------------+------------------------------------- Changes (by dfeuer): * owner: dfeuer => lukemaurer * differential: => Phab:D2853 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11568#comment:11 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC