perf data: Add perf_data__update_dir() function