intel/perf: move wait_query to perf