New results from "dictionary word count" programs...

Levi Pearson levi at
Tue Mar 21 09:25:03 MST 2006

On Mar 21, 2006, at 8:59 AM, Gregory Hill wrote:

> Sorry for the double post, but I just thought of an example of why
> relying on external modules can be bad.  In Perl, the standard POSIX
> module takes up over 1MB of memory.  When I was working at  
> Navitaire, we
> had one module that relied on POSIX, but only for 2 or 3 extremely
> simple functions.  So, in order to cut down the memory footprint of  
> our
> code, we dropped POSIX and implemented those same functions  
> internally.
> So, we added probably 10 lines of code to our program, but dropped  
> over
> 1MB out of a 20MB memory footprint (per apache process).

So, where do you draw the line between 'language' and 'library'?   
Does a language's standard library count?  You couldn't write much of  
a program in C without its standard library.  What about Java?  It  
ships with a huge number of standard libraries.  Which of those would  
you allow?

How do you take into account the runtime system of a language?  C has  
a pretty small runtime support library, C++ has a larger one, and  
Java and other virtual machine-based or interpreted languages are on  
a whole different scale.

All languages are implemented by someone else's code, and their power  
to make programs short relies upon that fact.  Not allowing libraries  
is silly, because it's difficult to define what constitutes a library  
and libraries do not necessarily constitute the largest part of a  
program's memory footprint even when they are used.


More information about the PLUG mailing list