On 12/13/2011 11:32 AM, Bruno Haible wrote:

I'm attaching the benchmark program I'm experimenting with. So far, it seems
that locale_charset() is really slow, whereas the is_cjk stuff is not a big
speed problem.

I would love to have locale_charset be either faster or use some thread-safe
cache. Do you have an idea how to realize this?

You can add a uc_width_internal that takes the encoding plus an int *. The pointed value can be "-1" for no cache, "0" for cached not CJK, "1" for cached CJK.

Paolo

Reply via email to