Placeholder for useful code snippet:
open my $fh, '<:raw:perlio:encoding(UTF-16LE):crlf', $filename |
which will convert CR/LF combinations to LF only. Alternatively, to keep them intact:
open my $fh, '<:raw:perlio:encoding(UTF-16LE)', $filename |
Useful for reading Windows registry export files, SQL server log export files etc.