> I think this is more in the range of megabytes since the kernel is full
 > of duplicate strings.

The waste is certainly noticeable on DEBUG kernels.  In fact, there's
currently a P1 bug (6522961) open that DEBUG kernels are overflowing the
4M nucleus text page because of all the duplicate text strings in ASSERT()
messages (especially __FILE__).  Roland, you will be happy to hear that
one of the proposals on the table is to enable -xstrconst for the kernel.

>From that bug report (unfortunately, in the Comments):

  Nulling out the ASSERT macro reduces the amount of text used for the
  DEBUG unix/genunix by a whopping 800k.

   diff debug   non-debug
   757042       2331073 1574031         genunix
   305878       862043  556165          unix
   
   138507       1712538 1574031         genunix 
   53280        644768  591488          unix 

  There are over 32000 ASSERTs according to cscope and I believe that much
  of the 800k is used for strings for the __FILE__ expansion.

--
meem
_______________________________________________
opensolaris-code mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/opensolaris-code

Reply via email to