VirtualBox

Changeset 1930 in kBuild


Ignore:
Timestamp:
Oct 24, 2008 6:20:23 AM (17 years ago)
Author:
bird
Message:

kmk/read.c: more free() avoidance, this time some very small buffers for conditionals. Use static buffers for the first chunk, this avoids all alloc/free for a typical kBuild run. the cost is 16 bytes of stack per recursion.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kmk/read.c

    r1929 r1930  
    19651965    {
    19661966#ifdef KMK
    1967 #if 0
    1968       if (conditionals->allocated == 0)
    1969         {
    1970           conditionals->allocated = sizeof (conditionals->ignoring_first);
    1971           conditionals->ignoring  = conditionals->ignoring_first;
    1972           conditionals->seen_else = conditionals->seen_else_first;
    1973         }
    1974       else
    1975 #endif
    19761967      if (conditionals->allocated <= sizeof (conditionals->ignoring_first))
    19771968        {
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette