I'm not aware of any perlapi XS functions that deal with UTF-16. Doing something in perlspace using the Encode module or a UTF-16-aware filehandle is probably your best bet. Shy of that, I think you'd have to write your own UTF-16 to UTF-8 converter in C. That's not insane, but it's hard work testing it properly and preparing to deal with all the possible permutations of malformed data.