>>20
Jcode.pmでもできるぞ。それも入ってないのけ?

$length = $jcode->jlength();
returns character length properly, rather than byte length.