in reply to How to read the unicode file

You have been advised in the chatterbox already to show the Perl code that relates to this problem. From your snippet you showed in the CB, I see you're not checking the error while opening the file. Maybe that is a problem. Or maybe your machine does not have enough RAM to read the file as a whole into memory. Or maybe your algorithm is just bad and takes a very long time for more lines. You don't show any code, so we can't help you further.