core: refactor file lookup from z_file_entry.erl to z_file_locate.erl.