Cache TypeRep kinds aggressively

Authored by dfeuer on Dec 1 2017, 4:00 PM.


Cache TypeRep kinds aggressively

Cache TypeRep k in each TrApp or TrTyCon constructor of
TypeRep (a :: k). This makes typeRepKind cheap.

With this change, we won't need any special effort to deserialize
typereps efficiently. The downside, of course, is that we make
TypeReps slightly larger.

Reviewers: austin, hvr, bgamari, simonpj

Reviewed By: bgamari, simonpj

Subscribers: carter, simonpj, rwbarton, thomie

GHC Trac Issues: Trac #14254

Differential Revision: