cvs commit: fptools/ghc/compiler/basicTypes MkId.lhs

Simon Peyton Jones simonpj@glass.cse.ogi.edu
Fri, 4 May 2001 01:09:43 -0700


simonpj     2001/05/04 01:09:43 PDT

  Modified files:
    ghc/compiler/basicTypes MkId.lhs 
  Log:
  	****	MERGE WITH 5.00 BRANCH     ********
  
  	--------------------------------
  	Make CPR work only for small products
  	--------------------------------
  
  GHC was barfing when doing CPR for programs involving very large
  products.  A one-line fix in MkId.mkDataCon makes it only do CPR for
  smaller products (I chose 10).  Comments
  
  -- We do not treat very big tuples as CPR-ish:
  --	a) for a start we get into trouble because there aren't
  --	   "enough" unboxed tuple types (a tiresome restriction,
  --	   but hard to fix),
  --	b) more importantly, big unboxed tuples get returned mainly
  --	   on the stack, and are often then allocated in the heap
  --	   by the caller.  So doing CPR for them may in fact make
  --	   things worse.
  
  This should fix the error
  	Failed to find interface decl for
  		PrelGHC.(#,,,,,,,,,,,,,,,,,,,,,,,,
  			  ,,,,,,,,,,,,,,,,,,,,,,,,,,,
  			  ,,,,,,,,,,,,,,,,,,,,,,,#)
  
  I hope.
  
  Revision  Changes    Path
  1.59      +14 -1     fptools/ghc/compiler/basicTypes/MkId.lhs