develooper Front page | perl.perl5.porters | Postings from March 2010

Re: Another optimization question: bsearch()

Thread Previous | Thread Next
From:
karl williamson
Date:
March 11, 2010 12:16
Subject:
Re: Another optimization question: bsearch()
Message ID:
4B994F75.2010401@khwilliamson.com
Jan Dubois wrote:
> On Mon, 08 Mar 2010, Nicholas Clark wrote:
>> However, even 7-14Mb doesn't scare me. On any demand paged OS, if it's not
>> used, it's not paged in. I doubt that we have any platform where we're that
>> tight on virtual memory space for executables.
> 
> It is also a little bit of an issue for people who distribute stand-alone
> applications written in Perl and bundled into a single executable with tools
> like PAR, PerlApp or Perl2Exe.
> 
> Right now you can fine tune the size of your bundled Unicode support by
> for example removing the 4 big tables for the major Asian scripts and
> still have Unicode support for all the European languages.  Having just one
> huge table would likely make this impossible.
> 
> Having such a big footprint is also a huge drag on application startup
> time if they have to extract the table to disk every time the application is
> run (yes, you can leave the files behind in a cache area, but some people
> prefer not to leave stuff behind when the application exits).
> 

As a compromise measure, couldn't these tables be dynamically loaded on 
demand?  I would guess that Perl already has a mechanism to do this, but 
if not, a malloc and copy from disk would work.

> I would also be curious how good those 7-14MB could be compressed, as that
> too would make a big difference for the actual filesize of packaged apps.
> 
> Cheers,
> -Jan
> 


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About