Re: [GIT PULL 0/7] perf/core improvements and fixes
From: Ingo Molnar
Date: Thu Nov 26 2015 - 06:00:32 EST
* Jiri Olsa <jolsa@xxxxxxxxxx> wrote:
> I think I found one race..
> - having install-traceevent-plugins depend on $(LIBTRACEEVENT),
> plugins will not be built as its prereq. and the target
> install-traceevent-plugins itself will trigger plugins build
> - but plugins build is also triggered by perf build itself
> via libtraceevent_plugins target
>
> so those 2 might race.. but as I said, I've never reproduced ;-)
>
> Could you please give it a try?
>
> thanks,
> jirka
>
>
> ---
> diff --git a/tools/perf/Makefile.perf b/tools/perf/Makefile.perf
> index 0d19d5447d6c..929a32ba15f5 100644
> --- a/tools/perf/Makefile.perf
> +++ b/tools/perf/Makefile.perf
> @@ -420,7 +420,7 @@ $(LIBTRACEEVENT)-clean:
> $(call QUIET_CLEAN, libtraceevent)
> $(Q)$(MAKE) -C $(TRACE_EVENT_DIR) O=$(OUTPUT) clean >/dev/null
>
> -install-traceevent-plugins: $(LIBTRACEEVENT)
> +install-traceevent-plugins: libtraceevent_plugins
> $(Q)$(MAKE) -C $(TRACE_EVENT_DIR) $(LIBTRACEEVENT_FLAGS) O=$(OUTPUT) install_plugins
>
Ok, so I tried this fix with my 'sleep 1' hack to make the race easier to trigger,
and without your fix it still fails fairly quickly:
triton:~/tip/tools/perf> while : ; do echo -n "$(date) "; make clean install V=1 >/tmp/FAIL.log 2>&1 && echo pass || { echo 'FAIL!'; break; } done
Thu Nov 26 11:54:36 CET 2015 pass
Thu Nov 26 11:54:47 CET 2015 FAIL!
but with your fix applied it passes a reasonable number of builds:
triton:~/tip/tools/perf> while : ; do echo -n "$(date) "; make clean install V=1 >/tmp/FAIL.log 2>&1 && echo pass || { echo 'FAIL!'; break; } done
Thu Nov 26 11:55:12 CET 2015 pass
Thu Nov 26 11:55:25 CET 2015 pass
Thu Nov 26 11:55:36 CET 2015 pass
Thu Nov 26 11:55:47 CET 2015 pass
Thu Nov 26 11:55:58 CET 2015 pass
Thu Nov 26 11:56:09 CET 2015 pass
Thu Nov 26 11:56:21 CET 2015 pass
Thu Nov 26 11:56:32 CET 2015 pass
Thu Nov 26 11:56:44 CET 2015 pass
Thu Nov 26 11:56:55 CET 2015 pass
Thu Nov 26 11:57:06 CET 2015 pass
Thu Nov 26 11:57:18 CET 2015 pass
Thu Nov 26 11:57:29 CET 2015 pass
Thu Nov 26 11:57:40 CET 2015 pass
Thu Nov 26 11:57:51 CET 2015 pass
Thu Nov 26 11:58:03 CET 2015 pass
So I think the bug is fixed for good:
Tested-by: Ingo Molnar <mingo@xxxxxxxxxx>
( I'll keep it running some longer and will let you know if there's any failure.
Consider it fixed if I don't send any update. )
Thanks,
Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/