Skip to content
  • Joachim Breitner's avatar
    Call Arity: Trade precision for performance in large mutually recursive groups · 9654a7cf
    Joachim Breitner authored
    Sometimes (especial with derived Data instances, it seems), one can have
    very large mutually recursive bindings. Calculating the Call Arity
    analysis result with full precision is an expensive operation in these
    case. So above a certain threshold (25, for no good reason besides
    intuition), skip this calculation and assume the recursion is not
    linear, which is a conservative result.
    
    With this, the Call Arity analysis accounts for 3.7% of the compile time
    of haskell-src-exts. Fixes #10293
    
    Differential Revision: https://phabricator.haskell.org/D843
    9654a7cf