Skip to content
Snippets Groups Projects
  • jshin@chromium.org's avatar
    Trim ICU data to reduce the download size/memory usage · 4e493261
    jshin@chromium.org authored
    Add a shell script to trim the ICU data further : trim_data.sh along with
    locale list files.  The script does the following:
    
    1. Remove the display names of languages NOT listed in Chrome's Accept-Language
       list. (800kB)
    2. Minimize the locale data for locales listed in the A-L list that are
       not a UI locale in Chrome. For those locales, exemplar characters,
       the display name in the native language and layout direction are included.
       (640kB)
    3. Filter the region data to drop numeric region display names other than 419
       (Latin-America). (50kB)
    4. Filter the currency data (display name and plurals) for historic currencies.
       (200kB)
    
    This CL also checks in icudtl.dat (source/data/in) and
    icudt_dat.S (mac and linux). Note that I dropped '52' (the version number)
    in the assembly source file name and icu.gyp was adjusted accordingly.
    
    With all these changes, icudtl.dat is ~ 800kB larger than that in ICU 4.6.
    The 7z compression (as used by the installer) makes the size difference
    go down to ~ 130kB.
    
    BUG=132145
    TEST=The icudtl.dat (uncompressed) is about 10.7MB instead of 12.4MB without this CL.
    R=mark@chromium.org
    
    Review URL: https://codereview.chromium.org/239543018
    
    git-svn-id: http://src.chromium.org/svn/trunk/deps/third_party/icu52@264811 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
    4e493261