DsExpr: Don't build/foldr huge lists
authorBen Gamari <bgamari.foss@gmail.com>
Sun, 20 Mar 2016 16:49:58 +0000 (17:49 +0100)
committerBen Gamari <ben@smart-cactus.org>
Sun, 20 Mar 2016 21:00:37 +0000 (22:00 +0100)
commitb735e99d79448bd7f416b35d8b0473d8eb5271f1
tree98e970b5d44a91349a18a15c42958c4e9a2ede1e
parentba95f22eb98cc2ee2d8d76e56df80769c379413d
DsExpr: Don't build/foldr huge lists

Desugaring long lists with build trades large static data for large
code, which is likely a poor trade-off. See #11707.

Test Plan: Validate, nofib

Reviewers: simonpj, austin

Reviewed By: austin

Subscribers: thomie

Differential Revision: https://phabricator.haskell.org/D2007

GHC Trac Issues: #11707
compiler/deSugar/DsExpr.hs
testsuite/tests/perf/compiler/all.T