VirtualBox

Changeset 429 in kBuild


Ignore:
Timestamp:
Mar 26, 2006 6:07:04 AM (19 years ago)
Author:
bird
Message:

optimizing for the libc project.

Location:
trunk/src/gmake
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/gmake/Makefile.kmk

    r376 r429  
    2222        CONFIG_NO_DEFAULT_VARIABLES \
    2323        KMK
     24       
    2425       
    2526kmk_SOURCES         = \
     
    9091# Standalone kmkbuiltin commands.
    9192#
    92 PROGRAMS += kmk_append kmk_cp kmk_echo kmk_mkdir kmk_install kmk_ln kmk_rm 
     93PROGRAMS += kmk_append kmk_cp kmk_echo kmk_mkdir kmk_install kmk_ln kmk_rm
    9394
    9495kmk_append_TEMPLATE = BIN
  • trunk/src/gmake/file.c

    r287 r429  
    968968init_hash_files (void)
    969969{
     970#ifdef KMK
     971  hash_init (&files, 8192, file_hash_1, file_hash_2, file_hash_cmp);
     972#else
    970973  hash_init (&files, 1000, file_hash_1, file_hash_2, file_hash_cmp);
     974#endif
    971975}
    972976
  • trunk/src/gmake/make.h

    r281 r429  
    424424extern void collapse_continuations PARAMS ((char *));
    425425extern void remove_comments PARAMS((char *));
     426#ifdef KMK
     427#define lindex(s, limit, c) ((char *)memchr((s), (c), (limit) - (s)))
     428#else
    426429extern char *lindex PARAMS ((const char *, const char *, int));
     430#endif
    427431extern int alpha_compare PARAMS ((const void *, const void *));
    428432extern void print_spaces PARAMS ((unsigned int));
  • trunk/src/gmake/misc.c

    r281 r429  
    2222#include "dep.h"
    2323#include "debug.h"
     24
     25#ifdef __EMX__  /* saves 5-10ms on libc */
     26# define bcopy(src, dst, size)   __builtin_memcpy((dst), (src), (size))
     27#endif
    2428
    2529/* Variadic functions.  We go through contortions to allow proper function
     
    420424
    421425
     426#ifndef KMK /* This is really a reimplemntation of memchr. */
    422427/* Limited INDEX:
    423428   Search through the string STRING, which ends at LIMIT, for the character C.
     
    435440  return 0;
    436441}
     442#endif
    437443
    438444
  • trunk/src/gmake/variable.c

    r370 r429  
    149149init_hash_global_variable_set (void)
    150150{
    151   hash_init (&global_variable_set.table, VARIABLE_BUCKETS,
     151  hash_init (&global_variable_set.table,
     152#ifdef KMK
     153             8192,
     154#else
     155             VARIABLE_BUCKETS,
     156#endif
    152157             variable_hash_1, variable_hash_2, variable_hash_cmp);
    153158}
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