Changeset 1848 for trunk/src/kmk


Ignore:
Timestamp:
Oct 12, 2008, 6:41:07 PM (17 years ago)
Author:
bird
Message:

kmk: includedep dependencies does not require unescaping or any other parsing in expand_deps. This saves more than 10% in a typical kBuild testcase.

Location:
trunk/src/kmk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kmk/dep.h

    r1827 r1848  
    4444    unsigned int staticpattern : 1;
    4545    unsigned int need_2nd_expansion : 1;
     46#ifdef CONFIG_WITH_INCLUDEDEP
     47    unsigned int includedep : 1;
     48#endif
    4649  };
    4750
  • trunk/src/kmk/file.c

    r1847 r1848  
    514514        continue;
    515515
     516#ifdef CONFIG_WITH_INCLUDEDEP
     517      /* Dependencies loaded by includedep can be passed right thru. */
     518      if (d->includedep)
     519        {
     520          new = alloc_dep();
     521          new->name = d->name;
     522        }
     523      else
     524        {
     525#endif
     526
    516527      /* Create the dependency list.
    517528         If we're not doing 2nd expansion, then it's just the name.  We will
     
    574585
    575586      /* Parse the prerequisites.  */
    576 #ifndef CONFIG_WITH_VALUE_LENGTH
    577587      new = parse_prereqs (p);
    578 #else
    579       /** @todo make use of len here! */
    580       new = parse_prereqs (p);
    581 #endif
    582588
    583589      /* If this dep list was from a static pattern rule, expand the %s.  We
     
    647653            }
    648654        }
     655
     656#ifdef CONFIG_WITH_INCLUDEDEP
     657        }
     658#endif
    649659
    650660      /* Enter them as files. */
  • trunk/src/kmk/incdep.c

    r1825 r1848  
    12551255                  *nextdep = dep = alloc_dep ();
    12561256                  dep->name = incdep_record_strcache (curdep, cur, endp - cur);
     1257                  dep->includedep = 1;
    12571258                  nextdep = &dep->next;
    12581259
Note: See TracChangeset for help on using the changeset viewer.