Date: Thu, 22 Dec 2011 00:43:14 -0800 From: Adrian Chadd <adrian@freebsd.org> To: Dimitry Andric <dim@freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r228783 - head/sys/conf Message-ID: <CAJ-VmomCntp_OM9yEFJvmK3DP37%2BEhJcVQzkL3MH9UYucR0j6Q@mail.gmail.com> In-Reply-To: <201112211701.pBLH1DpL077981@svn.freebsd.org> References: <201112211701.pBLH1DpL077981@svn.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
.. and once this LLVM regression has been fixed, do you plan on reverting this change to conf? Adrian On 21 December 2011 09:01, Dimitry Andric <dim@freebsd.org> wrote: > Author: dim > Date: Wed Dec 21 17:01:13 2011 > New Revision: 228783 > URL: http://svn.freebsd.org/changeset/base/228783 > > Log: > =A0When building with clang, disable -Wshift-count-negative and > =A0-Wshift-count-overflow for sys/dev/ath/ath_hal/ah_regdomain.c, as it > =A0gets multiple instances of the following warnings: > > =A0In file included from sys/dev/ath/ath_hal/ah_regdomain.c:99: > =A0sys/dev/ath/ath_hal/ah_regdomain/ah_rd_domains.h:69:15: warning: shift= count is negative [-Wshift-count-negative] > =A0 =A0 =A0 =A0 =A0 .chan11a =A0 =A0 =A0 =A0 =A0 =A0 =A0 =3D BM4(F1_4950_= 4980, > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0^~= ~~~~~~~~~~~~~~~ > =A0sys/dev/ath/ath_hal/ah_regdomain/ah_rd_domains.h:41:4: note: expanded = from: > =A0 =A0 =A0 =A0 =A0 =A0W1(_fa) | W1(_fb) | W1(_fc) | W1(_fd) } > =A0 =A0 =A0 =A0 =A0 =A0^ > =A0sys/dev/ath/ath_hal/ah_regdomain/ah_rd_domains.h:34:45: note: expanded= from: > =A0 =A0 =A0 =A0 =A0(((_a) > 63 && (_a) < 128 ? (((uint64_t) 1)<<((_a)-64)= ) : (uint64_t) 0)) > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 ^ ~~~~~~~~~ > > =A0and: > > =A0In file included from sys/dev/ath/ath_hal/ah_regdomain.c:99: > =A0sys/dev/ath/ath_hal/ah_regdomain/ah_rd_domains.h:629:15: error: shift = count >=3D width of type [-Werror,-Wshift-count-overflow] > =A0 =A0 =A0 =A0 =A0 .chan11a =A0 =A0 =A0 =A0 =A0 =A0 =A0 =3D BM4(W2_5260_= 5320, > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0^~= ~~~~~~~~~~~~~~~ > =A0sys/dev/ath/ath_hal/ah_regdomain/ah_rd_domains.h:40:34: note: expanded= from: > =A0 =A0 =A0 =A0 =A0{ W0(_fa) | W0(_fb) | W0(_fc) | W0(_fd), =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0\ > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0^ > =A0sys/dev/ath/ath_hal/ah_regdomain/ah_rd_domains.h:32:44: note: expanded= from: > =A0 =A0 =A0 =A0 =A0(((_a) >=3D 0 && (_a) < 64 ? (((uint64_t) 1)<<(_a)) : = (uint64_t) 0)) > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0^ ~~~~ > > =A0Both warnings are false positives, caused by LLVM PR 10030. =A0For glo= bal > =A0initializations, clang fails to detect that the branch of the ternary > =A0operator causing the warning is dead. > > =A0MFC after: =A0 =A01 week > > Modified: > =A0head/sys/conf/files > =A0head/sys/conf/kern.mk > > Modified: head/sys/conf/files > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/sys/conf/files Wed Dec 21 16:47:01 2011 =A0 =A0 =A0 =A0(r228782) > +++ head/sys/conf/files Wed Dec 21 17:01:13 2011 =A0 =A0 =A0 (r228783) > @@ -613,7 +613,7 @@ dev/ath/ath_hal/ah_eeprom_9287.c \ > =A0 =A0 =A0 =A0optional ath_hal | ath_ar9287 \ > =A0 =A0 =A0 =A0compile-with "${NORMAL_C} -I$S/dev/ath" > =A0dev/ath/ath_hal/ah_regdomain.c optional ath \ > - =A0 =A0 =A0 compile-with "${NORMAL_C} -I$S/dev/ath" > + =A0 =A0 =A0 compile-with "${NORMAL_C} ${NO_WSHIFT_COUNT_NEGATIVE} ${NO_= WSHIFT_COUNT_OVERFLOW} -I$S/dev/ath" > =A0# ar5210 > =A0dev/ath/ath_hal/ar5210/ar5210_attach.c =A0 =A0 =A0 =A0 optional ath_ha= l | ath_ar5210 \ > =A0 =A0 =A0 =A0compile-with "${NORMAL_C} -I$S/dev/ath -I$S/dev/ath/ath_ha= l" > > Modified: head/sys/conf/kern.mk > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/sys/conf/kern.mk =A0 =A0 =A0 Wed Dec 21 16:47:01 2011 =A0 =A0 = =A0 =A0(r228782) > +++ head/sys/conf/kern.mk =A0 =A0 =A0 Wed Dec 21 17:01:13 2011 =A0 =A0 = =A0 (r228783) > @@ -17,6 +17,8 @@ CWARNFLAGS?=3D =A0-Wall -Wredundant-decls -Wn > =A0.if ${CC:T:Mclang} =3D=3D "clang" > =A0NO_WCONSTANT_CONVERSION=3D =A0 =A0 =A0 -Wno-constant-conversion > =A0NO_WARRAY_BOUNDS=3D =A0 =A0 =A0 =A0 =A0 =A0 =A0-Wno-array-bounds > +NO_WSHIFT_COUNT_NEGATIVE=3D =A0 =A0 =A0-Wno-shift-count-negative > +NO_WSHIFT_COUNT_OVERFLOW=3D =A0 =A0 =A0-Wno-shift-count-overflow > =A0.endif > > =A0#
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAJ-VmomCntp_OM9yEFJvmK3DP37%2BEhJcVQzkL3MH9UYucR0j6Q>