DevHeads.net

RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

We have this nice ECM module that gives us the option to compile with ASAN.

I'd like to propose that we enable it by default in jenkins.

This way we get all the autotests run with ASAN and potentially catch more
bugs/regressions.

Comments?

Cheers,
Albert

Comments

Re: RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

By Albert Astals Cid at 09/21/2015 - 14:29

El Dijous, 10 de setembre de 2015, a les 22:36:10, Albert Astals Cid va escriure:
This has now been commited.

<a href="https://quickgit.kde.org/?p=sysadmin%2Fci-builder-tools.git&amp;a=commit&amp;h=5e4f2e673c902e9d3b09aeffe56c20838918c681" title="https://quickgit.kde.org/?p=sysadmin%2Fci-builder-tools.git&amp;a=commit&amp;h=5e4f2e673c902e9d3b09aeffe56c20838918c681">https://quickgit.kde.org/?p=sysadmin%2Fci-builder-tools.git&amp;a=commit&amp;h=5...</a>

Watch out for tests failing, let's hope it doesn't find anything bad :D

Cheers,
Albert

Re: RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

By Milian Wolff at 09/24/2015 - 23:15

On Montag, 21. September 2015 20:29:32 CEST Albert Astals Cid wrote:
\o/

Thanks for taking the initiative here, Albert! Much appreciated!

Also, did you think of additionally enabling UBSan where available? It can be
combined with ASan and should thus find even more issues in our codebase!

Bye

Re: RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

By Albert Astals Cid at 09/25/2015 - 17:35

El Divendres, 25 de setembre de 2015, a les 05:15:35, Milian Wolff va
escriure:
I've never tried the undefined sanitizer so can't comment on how "correct" or
"pedantic" its checks are.

Have you? What's your opinion on it?

Also it seems it doesn't really crash(stop the app like asan does, so it would
not be of much use unless someone spends lots of time parsing the tests logs,
no?

Cheers,
Albert

Re: RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

By Milian Wolff at 09/28/2015 - 10:41

On Friday, September 25, 2015 11:35:35 PM CEST Albert Astals Cid wrote:
Yes, it works nicely for the simple examples I've tried, see also:

<a href="http://developerblog.redhat.com/2014/10/16/gcc-undefined-behavior-sanitizer-ubsan/" title="http://developerblog.redhat.com/2014/10/16/gcc-undefined-behavior-sanitizer-ubsan/">http://developerblog.redhat.com/2014/10/16/gcc-undefined-behavior-saniti...</a>

It could either be scripted, or we can try to pass -fno-sanitize-recover,
which should make it crash instantly on the first error (indeed, it does in my
test).

Bye

Re: RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

By Albert Astals Cid at 09/28/2015 - 17:10

El Dilluns, 28 de setembre de 2015, a les 16:41:58, Milian Wolff va escriure:
Have you compiled some frameworks with those flags on? Are we confident it
won't blow up in a red-festival?

Cheers,
Albert

Re: RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

By Milian Wolff at 09/28/2015 - 17:12

On Montag, 28. September 2015 23:10:33 CEST Albert Astals Cid wrote:
No.

Bye

Re: RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

By =?ISO-8859-1?Q?... at 09/15/2015 - 14:20

On Thursday 10 September 2015 22:36:10 Albert Astals Cid wrote:
+1

For code using STL the define _GLIBCXX_DEBUG for GCC is helpful too (but it
slows down run time so it's maybe for something like nightly builds).

Cheers,
André

Re: RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

By Kevin Funk at 09/14/2015 - 07:02

On Thursday, September 10, 2015 10:36:10 PM Albert Astals Cid wrote:
Sounds good to me. We should try it out.

Worth the slowdown of the ASAN-enabled programs on the CI.

Cheers

Re: RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

By Volker Krause at 09/13/2015 - 05:34

On Thursday 10 September 2015 22:36:10 Albert Astals Cid wrote:
Good idea, definitely worth trying IMHO. There were a few test issues in pim
code recently where this would have been useful.

regards,
Volker

Re: RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

By Lamarque V. Souza at 09/10/2015 - 17:20

I agree but there is a problem: it can catch a lot of errors in our
dependency libraries (upstream bugs). I had this problem when I used it
with a program I develop at my work. Enabling it for all programs at once
and fixing all those upstream bugs can be overwhelming. Maybe we should do
it for a limited number of programs first and add more programs as we fix
the errors.

Lamarque V. Souza

<a href="http://planetkde.org/pt-br" title="http://planetkde.org/pt-br">http://planetkde.org/pt-br</a>

Re: RFC: Enabling -DECM_ENABLE_SANITIZERS='address' in jenkins

By Albert Astals Cid at 09/10/2015 - 17:34

El Dijous, 10 de setembre de 2015, a les 18:20:19, Lamarque Souza va escriure:
No, it can not, asan works only on code you have compiled with asan enabled
(which for most of our dependencies we do not compile or they don't use ECM).

Cheers,
Albert