perf events: Fix false positive build warning with older GCC's