From 4c2732a1dad1de295c9219ee3afac007b2d7ba05 Mon Sep 17 00:00:00 2001 From: Josh Stone Date: Wed, 28 Jan 2009 14:36:08 -0800 Subject: Use 'static' as much as possible This change just inserts 'static' on runtime, tapset, and generated C functions and globals, so the compiler can do a better job of optimizing. My tests with small scripts show ~10% reduction in compile time and ~20% reduction in module size. Larger scripts may show less benefit, but I expect purely positive results. --- runtime/transport/symbols.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'runtime/transport/symbols.c') diff --git a/runtime/transport/symbols.c b/runtime/transport/symbols.c index 72f9ad80..b9458ada 100644 --- a/runtime/transport/symbols.c +++ b/runtime/transport/symbols.c @@ -103,7 +103,7 @@ static void generic_swap(void *a, void *b, int size) * O(n*n) worst-case behavior and extra memory requirements that make * it less suitable for kernel use. */ -void _stp_sort(void *_base, size_t num, size_t size, +static void _stp_sort(void *_base, size_t num, size_t size, int (*cmp_func) (const void *, const void *), void (*swap_func) (void *, void *, int size)) { char *base = (char*) _base; -- cgit