Re: RFC: (Unconditionally) enable -fno-strict-overflow for kernel builds

From: Eitan Adler <lists_at_eitanadler.com>
Date: Sat, 30 Nov 2013 23:38:45 -0500
On Sat, Nov 30, 2013 at 11:26 PM, Peter Wemm <peter_at_wemm.org> wrote:
> On Sat, Nov 30, 2013 at 4:33 PM, Adrian Chadd <adrian_at_freebsd.org> wrote:
> [..]
>> Are you able to have clang/llvm/gcc tell us where/when code is relying
>> on undefined behaviour? So we can, like, fix them?
>
> It wasn't all that long ago that we had this wonderful thing called
> -Werror and had a clean kernel build.
>
> The problem is that gcc and clang have different warning sets.  I seem
> to recall we had -Werror on for gcc and off for clang.  IMHO it would
> be more useful to do it the other way around.

Not all cases can be caught by static analysis.  They would all be
caught be the integer sanitizer.  However, these have not yet been
ported to FreeBSD.





-- 
Eitan Adler
Received on Sun Dec 01 2013 - 03:39:16 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:44 UTC