
#13014: Seemingly unnecessary marking of a SpecConstr specialization as a loopbreaker -------------------------------------+------------------------------------- Reporter: nfrisby | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.0.1 Resolution: | Keywords: SpecConstr 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 nfrisby): I'm seeing the same behavior if I disable `-fspec-constr` and instead declare. {{{#!hs {-# SPECIALIZE INLINE lengthVL :: SPEC -> VL (a ': as) -> Int# #-} }}} I get the expected rule. {{{#!hs ==================== Tidy Core rules ==================== "SPEC lengthVL" [ALWAYS] forall (@ k) (@ (a :: k)) (@ (as :: [k])). lengthVL @ k @ (a : as) = lengthVL_$slengthVL @ k @ a @ as }}} but the specialization `lengthVL_$slengthVL` is again marked as a loopbreaker, and so it only fires once in the definition of `test`, as with the `-fspec-constr` route. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13014#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler