public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Warning: conditional outside an IT block for Thumb.
@ 2022-08-25  6:40 Mathieu Malaterre
  2022-08-25 10:28 ` Richard Earnshaw
  0 siblings, 1 reply; 5+ messages in thread
From: Mathieu Malaterre @ 2022-08-25  6:40 UTC (permalink / raw)
  To: gcc-help

Hi all,

I am seeing a flood of warnings when compiling openvdb+tbb on Debian/armel:

[...]
 [  2%] Building CXX object
openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Archive.cc.o
 cd /<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb &&
/usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
-DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
-Dopenvdb_shared_EXPORTS -I/<<PK
GBUILDDIR>>/openvdb/openvdb/..
-I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb
-I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
-I/<<PKGBUILDDIR>>/openvdb/openvdb/. -I/usr/include/Imat
h -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong
-Wformat -Werror=format-security -Wno-psabi -fvisibility=hidden
-fvisibility-inlines-hidden -Wa,-mimplicit-it=thumb -Wdate-time
-D_FORTIFY
_SOURCE=2 -fPIC -std=c++17 -MD -MT
openvdb/openvdb/CMakeFiles/openvdb_shared.dir/Grid.cc.o -MF
CMakeFiles/openvdb_shared.dir/Grid.cc.o.d -o
CMakeFiles/openvdb_shared.dir/Grid.cc.o -c /<<PKGBUILDDIR>>/openvdb/o
penvdb/Grid.cc
 cd /<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb &&
/usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
-DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
-Dopenvdb_shared_EXPORTS -I/<<PK
GBUILDDIR>>/openvdb/openvdb/..
-I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb
-I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
-I/<<PKGBUILDDIR>>/openvdb/openvdb/. -I/usr/include/Imat
h -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong
-Wformat -Werror=format-security -Wno-psabi -fvisibility=hidden
-fvisibility-inlines-hidden -Wa,-mimplicit-it=thumb -Wdate-time
-D_FORTIFY
_SOURCE=2 -fPIC -std=c++17 -MD -MT
openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Archive.cc.o -MF
CMakeFiles/openvdb_shared.dir/io/Archive.cc.o.d -o
CMakeFiles/openvdb_shared.dir/io/Archive.cc.o -c /<<PKGBU
ILDDIR>>/openvdb/openvdb/io/Archive.cc
/tmp/ccFlliCl.s: Assembler messages:
/tmp/ccFlliCl.s:294: Warning: conditional outside an IT block for Thumb.
/tmp/ccFlliCl.s:338: Warning: conditional outside an IT block for Thumb.
[...]

There are so many warnings that it eventually times out the compilation.

I could not find a way to tell gcc not to print a warning. Is there a
way to remove this warning ?

For reference the very large log:

* https://buildd.debian.org/status/fetch.php?pkg=openvdb&arch=armel&ver=9.1.0-4&stamp=1661358853&raw=0

Thanks much,
-- 
Mathieu

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Warning: conditional outside an IT block for Thumb.
  2022-08-25  6:40 Warning: conditional outside an IT block for Thumb Mathieu Malaterre
@ 2022-08-25 10:28 ` Richard Earnshaw
  2022-08-25 13:48   ` Mathieu Malaterre
  0 siblings, 1 reply; 5+ messages in thread
From: Richard Earnshaw @ 2022-08-25 10:28 UTC (permalink / raw)
  To: Mathieu Malaterre, gcc-help



On 25/08/2022 07:40, Mathieu Malaterre via Gcc-help wrote:
> Hi all,
> 
> I am seeing a flood of warnings when compiling openvdb+tbb on Debian/armel:
> 
> [...]
>   [  2%] Building CXX object
> openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Archive.cc.o
>   cd /<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb &&
> /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
> -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
> -Dopenvdb_shared_EXPORTS -I/<<PK
> GBUILDDIR>>/openvdb/openvdb/..
> -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb
> -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
> -I/<<PKGBUILDDIR>>/openvdb/openvdb/. -I/usr/include/Imat
> h -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong
> -Wformat -Werror=format-security -Wno-psabi -fvisibility=hidden
> -fvisibility-inlines-hidden -Wa,-mimplicit-it=thumb -Wdate-time
> -D_FORTIFY
> _SOURCE=2 -fPIC -std=c++17 -MD -MT
> openvdb/openvdb/CMakeFiles/openvdb_shared.dir/Grid.cc.o -MF
> CMakeFiles/openvdb_shared.dir/Grid.cc.o.d -o
> CMakeFiles/openvdb_shared.dir/Grid.cc.o -c /<<PKGBUILDDIR>>/openvdb/o
> penvdb/Grid.cc
>   cd /<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb &&
> /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
> -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
> -Dopenvdb_shared_EXPORTS -I/<<PK
> GBUILDDIR>>/openvdb/openvdb/..
> -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb
> -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
> -I/<<PKGBUILDDIR>>/openvdb/openvdb/. -I/usr/include/Imat
> h -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong
> -Wformat -Werror=format-security -Wno-psabi -fvisibility=hidden
> -fvisibility-inlines-hidden -Wa,-mimplicit-it=thumb -Wdate-time
> -D_FORTIFY
> _SOURCE=2 -fPIC -std=c++17 -MD -MT
> openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Archive.cc.o -MF
> CMakeFiles/openvdb_shared.dir/io/Archive.cc.o.d -o
> CMakeFiles/openvdb_shared.dir/io/Archive.cc.o -c /<<PKGBU
> ILDDIR>>/openvdb/openvdb/io/Archive.cc
> /tmp/ccFlliCl.s: Assembler messages:
> /tmp/ccFlliCl.s:294: Warning: conditional outside an IT block for Thumb.
> /tmp/ccFlliCl.s:338: Warning: conditional outside an IT block for Thumb.
> [...]
> 
> There are so many warnings that it eventually times out the compilation.
> 
> I could not find a way to tell gcc not to print a warning. Is there a
> way to remove this warning ?

The warning is coming from the assembler.  But I don't think it should 
be just 'ignored'.  You'll need to track down why it's happening at all. 
  The most likely case is that there is some inlined assembly code 
somewhere that was written on the assumption that the compiler would be 
targeting the A32 state rather than the T32 state (thumb), but there's 
not enough information here to work out what's happened for sure.

What we need is a snippet of the assembler output when compiled with 
debugging information, so that we can track back to the source code that 
is generating this.

> 
> For reference the very large log:
> 
> * https://buildd.debian.org/status/fetch.php?pkg=openvdb&arch=armel&ver=9.1.0-4&stamp=1661358853&raw=0
> 
> Thanks much,

The log isn't much help, it's the contents of the file that's being 
assembled that will tell us what we need to know.

R.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Warning: conditional outside an IT block for Thumb.
  2022-08-25 10:28 ` Richard Earnshaw
@ 2022-08-25 13:48   ` Mathieu Malaterre
  2022-08-25 13:58     ` Mathieu Malaterre
  0 siblings, 1 reply; 5+ messages in thread
From: Mathieu Malaterre @ 2022-08-25 13:48 UTC (permalink / raw)
  To: Richard Earnshaw; +Cc: gcc-help

Hi Richard,

Thanks for the kind help.

On Thu, Aug 25, 2022 at 12:28 PM Richard Earnshaw
<Richard.Earnshaw@foss.arm.com> wrote:
>
>
>
> On 25/08/2022 07:40, Mathieu Malaterre via Gcc-help wrote:
> > Hi all,
> >
> > I am seeing a flood of warnings when compiling openvdb+tbb on Debian/armel:
> >
> > [...]
> >   [  2%] Building CXX object
> > openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Archive.cc.o
> >   cd /<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb &&
> > /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
> > -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
> > -Dopenvdb_shared_EXPORTS -I/<<PK
> > GBUILDDIR>>/openvdb/openvdb/..
> > -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb
> > -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
> > -I/<<PKGBUILDDIR>>/openvdb/openvdb/. -I/usr/include/Imat
> > h -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong
> > -Wformat -Werror=format-security -Wno-psabi -fvisibility=hidden
> > -fvisibility-inlines-hidden -Wa,-mimplicit-it=thumb -Wdate-time
> > -D_FORTIFY
> > _SOURCE=2 -fPIC -std=c++17 -MD -MT
> > openvdb/openvdb/CMakeFiles/openvdb_shared.dir/Grid.cc.o -MF
> > CMakeFiles/openvdb_shared.dir/Grid.cc.o.d -o
> > CMakeFiles/openvdb_shared.dir/Grid.cc.o -c /<<PKGBUILDDIR>>/openvdb/o
> > penvdb/Grid.cc
> >   cd /<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb &&
> > /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
> > -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
> > -Dopenvdb_shared_EXPORTS -I/<<PK
> > GBUILDDIR>>/openvdb/openvdb/..
> > -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb
> > -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
> > -I/<<PKGBUILDDIR>>/openvdb/openvdb/. -I/usr/include/Imat
> > h -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong
> > -Wformat -Werror=format-security -Wno-psabi -fvisibility=hidden
> > -fvisibility-inlines-hidden -Wa,-mimplicit-it=thumb -Wdate-time
> > -D_FORTIFY
> > _SOURCE=2 -fPIC -std=c++17 -MD -MT
> > openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Archive.cc.o -MF
> > CMakeFiles/openvdb_shared.dir/io/Archive.cc.o.d -o
> > CMakeFiles/openvdb_shared.dir/io/Archive.cc.o -c /<<PKGBU
> > ILDDIR>>/openvdb/openvdb/io/Archive.cc
> > /tmp/ccFlliCl.s: Assembler messages:
> > /tmp/ccFlliCl.s:294: Warning: conditional outside an IT block for Thumb.
> > /tmp/ccFlliCl.s:338: Warning: conditional outside an IT block for Thumb.
> > [...]
> >
> > There are so many warnings that it eventually times out the compilation.
> >
> > I could not find a way to tell gcc not to print a warning. Is there a
> > way to remove this warning ?
>
> The warning is coming from the assembler.  But I don't think it should
> be just 'ignored'.  You'll need to track down why it's happening at all.
>   The most likely case is that there is some inlined assembly code
> somewhere that was written on the assumption that the compiler would be
> targeting the A32 state rather than the T32 state (thumb), but there's
> not enough information here to work out what's happened for sure.
>
> What we need is a snippet of the assembler output when compiled with
> debugging information, so that we can track back to the source code that
> is generating this.
>
> >
> > For reference the very large log:
> >
> > * https://buildd.debian.org/status/fetch.php?pkg=openvdb&arch=armel&ver=9.1.0-4&stamp=1661358853&raw=0
> >
> > Thanks much,
>
> The log isn't much help, it's the contents of the file that's being
> assembled that will tell us what we need to know.

I did add '-save-temps' to one TU compilation:

 % cd /home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
&& /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
-DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
-Dopenvdb_shared_EXPORTS
-I/home/malat/openvdb-9.1.0/openvdb/openvdb/..
-I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
-I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
-I/home/malat/openvdb-9.1.0/openvdb/openvdb/. -I/usr/include/Imath -g
-O2 -ffile-prefix-map=/home/malat/openvdb-9.1.0=.
-fstack-protector-strong -Wformat -Werror=format-security -Wno-psabi
-fvisibility=hidden -fvisibility-inlines-hidden
-Wa,-mimplicit-it=thumb -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC
-std=c++17 -MD -MT
openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -MF
CMakeFiles/openvdb_shared.dir/io/Compression.cc.o.d -o
CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -save-temps -c
/home/malat/openvdb-9.1.0/openvdb/openvdb/io/Compression.cc

Output is:

 % cd /home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
&& /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
-DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
-Dopenvdb_shared_EXPORTS
-I/home/malat/openvdb-9.1.0/openvdb/openvdb/..
-I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
-I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
-I/home/malat/openvdb-9.1.0/openvdb/openvdb/. -I/usr/include/Imath -g
-O2 -ffile-prefix-map=/home/malat/openvdb-9.1.0=.
-fstack-protector-strong -Wformat -Werror=format-security -Wno-psabi
-fvisibility=hidden -fvisibility-inlines-hidden
-Wa,-mimplicit-it=thumb -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC
-std=c++17 -MD -MT
openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -MF
CMakeFiles/openvdb_shared.dir/io/Compression.cc.o.d -o
CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -save-temps -c
/home/malat/openvdb-9.1.0/openvdb/openvdb/io/Compression.cc
CMakeFiles/openvdb_shared.dir/io/Compression.cc.s: Assembler messages:
CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:146: Warning:
conditional outside an IT block for Thumb.
CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:162: Warning:
conditional outside an IT block for Thumb.
CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:215: Warning:
conditional outside an IT block for Thumb.
CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:330: Warning:
conditional outside an IT block for Thumb.
CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:344: Warning:
conditional outside an IT block for Thumb.
CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:352: Warning:
conditional outside an IT block for Thumb.
CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:598: Warning:
conditional outside an IT block for Thumb.
CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:768: Warning:
conditional outside an IT block for Thumb.
CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:934: Warning:
conditional outside an IT block for Thumb.
[truncated]

My gcc version is:

 % /usr/bin/c++ -v
Using built-in specs.
COLLECT_GCC=/usr/bin/c++
COLLECT_LTO_WRAPPER=/usr/lib/gcc/arm-linux-gnueabi/12/lto-wrapper
Target: arm-linux-gnueabi
Configured with: ../src/configure -v --with-pkgversion='Debian
12.2.0-1' --with-bugurl=file:///usr/share/doc/gcc-12/README.Bugs
--enable-languages=c,ada,c++,go,d,fortran,objc,obj-c++,m2
--prefix=/usr --with-gcc-major-version-only --program-suffix=-12
--program-prefix=arm-linux-gnueabi- --enable-shared
--enable-linker-build-id --libexecdir=/usr/lib
--without-included-gettext --enable-threads=posix --libdir=/usr/lib
--enable-nls --enable-clocale=gnu --enable-libstdcxx-debug
--enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new
--enable-gnu-unique-object --disable-libitm --disable-libquadmath
--disable-libquadmath-support --enable-plugin --enable-default-pie
--with-system-zlib --enable-libphobos-checking=release
--with-target-system-zlib=auto --enable-objc-gc=auto
--enable-multiarch --disable-sjlj-exceptions --with-arch=armv5te
--with-float=soft --disable-werror --enable-checking=release
--build=arm-linux-gnueabi --host=arm-linux-gnueabi
--target=arm-linux-gnueabi
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 12.2.0 (Debian 12.2.0-1)

*.ii file:
https://people.debian.org/~malat/openvdb/Compression.cc.ii.xz


Once again thanks again for your time,
-- 
Mathieu

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Warning: conditional outside an IT block for Thumb.
  2022-08-25 13:48   ` Mathieu Malaterre
@ 2022-08-25 13:58     ` Mathieu Malaterre
  2022-08-25 14:09       ` Richard Earnshaw
  0 siblings, 1 reply; 5+ messages in thread
From: Mathieu Malaterre @ 2022-08-25 13:58 UTC (permalink / raw)
  To: Richard Earnshaw; +Cc: gcc-help

On Thu, Aug 25, 2022 at 3:48 PM Mathieu Malaterre
<mathieu.malaterre@gmail.com> wrote:
>
> Hi Richard,
>
> Thanks for the kind help.
>
> On Thu, Aug 25, 2022 at 12:28 PM Richard Earnshaw
> <Richard.Earnshaw@foss.arm.com> wrote:
> >
> >
> >
> > On 25/08/2022 07:40, Mathieu Malaterre via Gcc-help wrote:
> > > Hi all,
> > >
> > > I am seeing a flood of warnings when compiling openvdb+tbb on Debian/armel:
> > >
> > > [...]
> > >   [  2%] Building CXX object
> > > openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Archive.cc.o
> > >   cd /<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb &&
> > > /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
> > > -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
> > > -Dopenvdb_shared_EXPORTS -I/<<PK
> > > GBUILDDIR>>/openvdb/openvdb/..
> > > -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb
> > > -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
> > > -I/<<PKGBUILDDIR>>/openvdb/openvdb/. -I/usr/include/Imat
> > > h -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong
> > > -Wformat -Werror=format-security -Wno-psabi -fvisibility=hidden
> > > -fvisibility-inlines-hidden -Wa,-mimplicit-it=thumb -Wdate-time
> > > -D_FORTIFY
> > > _SOURCE=2 -fPIC -std=c++17 -MD -MT
> > > openvdb/openvdb/CMakeFiles/openvdb_shared.dir/Grid.cc.o -MF
> > > CMakeFiles/openvdb_shared.dir/Grid.cc.o.d -o
> > > CMakeFiles/openvdb_shared.dir/Grid.cc.o -c /<<PKGBUILDDIR>>/openvdb/o
> > > penvdb/Grid.cc
> > >   cd /<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb &&
> > > /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
> > > -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
> > > -Dopenvdb_shared_EXPORTS -I/<<PK
> > > GBUILDDIR>>/openvdb/openvdb/..
> > > -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb
> > > -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
> > > -I/<<PKGBUILDDIR>>/openvdb/openvdb/. -I/usr/include/Imat
> > > h -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong
> > > -Wformat -Werror=format-security -Wno-psabi -fvisibility=hidden
> > > -fvisibility-inlines-hidden -Wa,-mimplicit-it=thumb -Wdate-time
> > > -D_FORTIFY
> > > _SOURCE=2 -fPIC -std=c++17 -MD -MT
> > > openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Archive.cc.o -MF
> > > CMakeFiles/openvdb_shared.dir/io/Archive.cc.o.d -o
> > > CMakeFiles/openvdb_shared.dir/io/Archive.cc.o -c /<<PKGBU
> > > ILDDIR>>/openvdb/openvdb/io/Archive.cc
> > > /tmp/ccFlliCl.s: Assembler messages:
> > > /tmp/ccFlliCl.s:294: Warning: conditional outside an IT block for Thumb.
> > > /tmp/ccFlliCl.s:338: Warning: conditional outside an IT block for Thumb.
> > > [...]
> > >
> > > There are so many warnings that it eventually times out the compilation.
> > >
> > > I could not find a way to tell gcc not to print a warning. Is there a
> > > way to remove this warning ?
> >
> > The warning is coming from the assembler.  But I don't think it should
> > be just 'ignored'.  You'll need to track down why it's happening at all.
> >   The most likely case is that there is some inlined assembly code
> > somewhere that was written on the assumption that the compiler would be
> > targeting the A32 state rather than the T32 state (thumb), but there's
> > not enough information here to work out what's happened for sure.
> >
> > What we need is a snippet of the assembler output when compiled with
> > debugging information, so that we can track back to the source code that
> > is generating this.
> >
> > >
> > > For reference the very large log:
> > >
> > > * https://buildd.debian.org/status/fetch.php?pkg=openvdb&arch=armel&ver=9.1.0-4&stamp=1661358853&raw=0
> > >
> > > Thanks much,
> >
> > The log isn't much help, it's the contents of the file that's being
> > assembled that will tell us what we need to know.
>
> I did add '-save-temps' to one TU compilation:
>
>  % cd /home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
> && /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
> -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
> -Dopenvdb_shared_EXPORTS
> -I/home/malat/openvdb-9.1.0/openvdb/openvdb/..
> -I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
> -I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
> -I/home/malat/openvdb-9.1.0/openvdb/openvdb/. -I/usr/include/Imath -g
> -O2 -ffile-prefix-map=/home/malat/openvdb-9.1.0=.
> -fstack-protector-strong -Wformat -Werror=format-security -Wno-psabi
> -fvisibility=hidden -fvisibility-inlines-hidden
> -Wa,-mimplicit-it=thumb -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC
> -std=c++17 -MD -MT
> openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -MF
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.o.d -o
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -save-temps -c
> /home/malat/openvdb-9.1.0/openvdb/openvdb/io/Compression.cc
>
> Output is:
>
>  % cd /home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
> && /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
> -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
> -Dopenvdb_shared_EXPORTS
> -I/home/malat/openvdb-9.1.0/openvdb/openvdb/..
> -I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
> -I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
> -I/home/malat/openvdb-9.1.0/openvdb/openvdb/. -I/usr/include/Imath -g
> -O2 -ffile-prefix-map=/home/malat/openvdb-9.1.0=.
> -fstack-protector-strong -Wformat -Werror=format-security -Wno-psabi
> -fvisibility=hidden -fvisibility-inlines-hidden
> -Wa,-mimplicit-it=thumb -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC
> -std=c++17 -MD -MT
> openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -MF
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.o.d -o
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -save-temps -c
> /home/malat/openvdb-9.1.0/openvdb/openvdb/io/Compression.cc
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s: Assembler messages:
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:146: Warning:
> conditional outside an IT block for Thumb.
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:162: Warning:
> conditional outside an IT block for Thumb.
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:215: Warning:
> conditional outside an IT block for Thumb.
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:330: Warning:
> conditional outside an IT block for Thumb.
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:344: Warning:
> conditional outside an IT block for Thumb.
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:352: Warning:
> conditional outside an IT block for Thumb.
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:598: Warning:
> conditional outside an IT block for Thumb.
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:768: Warning:
> conditional outside an IT block for Thumb.
> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:934: Warning:
> conditional outside an IT block for Thumb.
> [truncated]
>
> My gcc version is:
>
>  % /usr/bin/c++ -v
> Using built-in specs.
> COLLECT_GCC=/usr/bin/c++
> COLLECT_LTO_WRAPPER=/usr/lib/gcc/arm-linux-gnueabi/12/lto-wrapper
> Target: arm-linux-gnueabi
> Configured with: ../src/configure -v --with-pkgversion='Debian
> 12.2.0-1' --with-bugurl=file:///usr/share/doc/gcc-12/README.Bugs
> --enable-languages=c,ada,c++,go,d,fortran,objc,obj-c++,m2
> --prefix=/usr --with-gcc-major-version-only --program-suffix=-12
> --program-prefix=arm-linux-gnueabi- --enable-shared
> --enable-linker-build-id --libexecdir=/usr/lib
> --without-included-gettext --enable-threads=posix --libdir=/usr/lib
> --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug
> --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new
> --enable-gnu-unique-object --disable-libitm --disable-libquadmath
> --disable-libquadmath-support --enable-plugin --enable-default-pie
> --with-system-zlib --enable-libphobos-checking=release
> --with-target-system-zlib=auto --enable-objc-gc=auto
> --enable-multiarch --disable-sjlj-exceptions --with-arch=armv5te
> --with-float=soft --disable-werror --enable-checking=release
> --build=arm-linux-gnueabi --host=arm-linux-gnueabi
> --target=arm-linux-gnueabi
> Thread model: posix
> Supported LTO compression algorithms: zlib zstd
> gcc version 12.2.0 (Debian 12.2.0-1)
>
> *.ii file:
> https://people.debian.org/~malat/openvdb/Compression.cc.ii.xz
>
>
> Once again thanks again for your time,

I've removed:

-Wa,-mimplicit-it=thumb

from compilation line and it seems to be going much better

sorry for the noise. This seems to have been a hack for armhf/Debian
back in 2002...

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Warning: conditional outside an IT block for Thumb.
  2022-08-25 13:58     ` Mathieu Malaterre
@ 2022-08-25 14:09       ` Richard Earnshaw
  0 siblings, 0 replies; 5+ messages in thread
From: Richard Earnshaw @ 2022-08-25 14:09 UTC (permalink / raw)
  To: Mathieu Malaterre; +Cc: gcc-help



On 25/08/2022 14:58, Mathieu Malaterre wrote:
> On Thu, Aug 25, 2022 at 3:48 PM Mathieu Malaterre
> <mathieu.malaterre@gmail.com> wrote:
>>
>> Hi Richard,
>>
>> Thanks for the kind help.
>>
>> On Thu, Aug 25, 2022 at 12:28 PM Richard Earnshaw
>> <Richard.Earnshaw@foss.arm.com> wrote:
>>>
>>>
>>>
>>> On 25/08/2022 07:40, Mathieu Malaterre via Gcc-help wrote:
>>>> Hi all,
>>>>
>>>> I am seeing a flood of warnings when compiling openvdb+tbb on Debian/armel:
>>>>
>>>> [...]
>>>>    [  2%] Building CXX object
>>>> openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Archive.cc.o
>>>>    cd /<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb &&
>>>> /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
>>>> -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
>>>> -Dopenvdb_shared_EXPORTS -I/<<PK
>>>> GBUILDDIR>>/openvdb/openvdb/..
>>>> -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb
>>>> -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
>>>> -I/<<PKGBUILDDIR>>/openvdb/openvdb/. -I/usr/include/Imat
>>>> h -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong
>>>> -Wformat -Werror=format-security -Wno-psabi -fvisibility=hidden
>>>> -fvisibility-inlines-hidden -Wa,-mimplicit-it=thumb -Wdate-time
>>>> -D_FORTIFY
>>>> _SOURCE=2 -fPIC -std=c++17 -MD -MT
>>>> openvdb/openvdb/CMakeFiles/openvdb_shared.dir/Grid.cc.o -MF
>>>> CMakeFiles/openvdb_shared.dir/Grid.cc.o.d -o
>>>> CMakeFiles/openvdb_shared.dir/Grid.cc.o -c /<<PKGBUILDDIR>>/openvdb/o
>>>> penvdb/Grid.cc
>>>>    cd /<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb &&
>>>> /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
>>>> -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
>>>> -Dopenvdb_shared_EXPORTS -I/<<PK
>>>> GBUILDDIR>>/openvdb/openvdb/..
>>>> -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb
>>>> -I/<<PKGBUILDDIR>>/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
>>>> -I/<<PKGBUILDDIR>>/openvdb/openvdb/. -I/usr/include/Imat
>>>> h -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong
>>>> -Wformat -Werror=format-security -Wno-psabi -fvisibility=hidden
>>>> -fvisibility-inlines-hidden -Wa,-mimplicit-it=thumb -Wdate-time
>>>> -D_FORTIFY
>>>> _SOURCE=2 -fPIC -std=c++17 -MD -MT
>>>> openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Archive.cc.o -MF
>>>> CMakeFiles/openvdb_shared.dir/io/Archive.cc.o.d -o
>>>> CMakeFiles/openvdb_shared.dir/io/Archive.cc.o -c /<<PKGBU
>>>> ILDDIR>>/openvdb/openvdb/io/Archive.cc
>>>> /tmp/ccFlliCl.s: Assembler messages:
>>>> /tmp/ccFlliCl.s:294: Warning: conditional outside an IT block for Thumb.
>>>> /tmp/ccFlliCl.s:338: Warning: conditional outside an IT block for Thumb.
>>>> [...]
>>>>
>>>> There are so many warnings that it eventually times out the compilation.
>>>>
>>>> I could not find a way to tell gcc not to print a warning. Is there a
>>>> way to remove this warning ?
>>>
>>> The warning is coming from the assembler.  But I don't think it should
>>> be just 'ignored'.  You'll need to track down why it's happening at all.
>>>    The most likely case is that there is some inlined assembly code
>>> somewhere that was written on the assumption that the compiler would be
>>> targeting the A32 state rather than the T32 state (thumb), but there's
>>> not enough information here to work out what's happened for sure.
>>>
>>> What we need is a snippet of the assembler output when compiled with
>>> debugging information, so that we can track back to the source code that
>>> is generating this.
>>>
>>>>
>>>> For reference the very large log:
>>>>
>>>> * https://buildd.debian.org/status/fetch.php?pkg=openvdb&arch=armel&ver=9.1.0-4&stamp=1661358853&raw=0
>>>>
>>>> Thanks much,
>>>
>>> The log isn't much help, it's the contents of the file that's being
>>> assembled that will tell us what we need to know.
>>
>> I did add '-save-temps' to one TU compilation:
>>
>>   % cd /home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
>> && /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
>> -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
>> -Dopenvdb_shared_EXPORTS
>> -I/home/malat/openvdb-9.1.0/openvdb/openvdb/..
>> -I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
>> -I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
>> -I/home/malat/openvdb-9.1.0/openvdb/openvdb/. -I/usr/include/Imath -g
>> -O2 -ffile-prefix-map=/home/malat/openvdb-9.1.0=.
>> -fstack-protector-strong -Wformat -Werror=format-security -Wno-psabi
>> -fvisibility=hidden -fvisibility-inlines-hidden
>> -Wa,-mimplicit-it=thumb -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC
>> -std=c++17 -MD -MT
>> openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -MF
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.o.d -o
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -save-temps -c
>> /home/malat/openvdb-9.1.0/openvdb/openvdb/io/Compression.cc
>>
>> Output is:
>>
>>   % cd /home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
>> && /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_IOSTREAMS_DYN_LINK
>> -DOPENVDB_DLL -DOPENVDB_PRIVATE -DOPENVDB_USE_LOG4CPLUS
>> -Dopenvdb_shared_EXPORTS
>> -I/home/malat/openvdb-9.1.0/openvdb/openvdb/..
>> -I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb
>> -I/home/malat/openvdb-9.1.0/obj-arm-linux-gnueabi/openvdb/openvdb/openvdb
>> -I/home/malat/openvdb-9.1.0/openvdb/openvdb/. -I/usr/include/Imath -g
>> -O2 -ffile-prefix-map=/home/malat/openvdb-9.1.0=.
>> -fstack-protector-strong -Wformat -Werror=format-security -Wno-psabi
>> -fvisibility=hidden -fvisibility-inlines-hidden
>> -Wa,-mimplicit-it=thumb -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC
>> -std=c++17 -MD -MT
>> openvdb/openvdb/CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -MF
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.o.d -o
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.o -save-temps -c
>> /home/malat/openvdb-9.1.0/openvdb/openvdb/io/Compression.cc
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s: Assembler messages:
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:146: Warning:
>> conditional outside an IT block for Thumb.
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:162: Warning:
>> conditional outside an IT block for Thumb.
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:215: Warning:
>> conditional outside an IT block for Thumb.
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:330: Warning:
>> conditional outside an IT block for Thumb.
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:344: Warning:
>> conditional outside an IT block for Thumb.
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:352: Warning:
>> conditional outside an IT block for Thumb.
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:598: Warning:
>> conditional outside an IT block for Thumb.
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:768: Warning:
>> conditional outside an IT block for Thumb.
>> CMakeFiles/openvdb_shared.dir/io/Compression.cc.s:934: Warning:
>> conditional outside an IT block for Thumb.
>> [truncated]
>>
>> My gcc version is:
>>
>>   % /usr/bin/c++ -v
>> Using built-in specs.
>> COLLECT_GCC=/usr/bin/c++
>> COLLECT_LTO_WRAPPER=/usr/lib/gcc/arm-linux-gnueabi/12/lto-wrapper
>> Target: arm-linux-gnueabi
>> Configured with: ../src/configure -v --with-pkgversion='Debian
>> 12.2.0-1' --with-bugurl=file:///usr/share/doc/gcc-12/README.Bugs
>> --enable-languages=c,ada,c++,go,d,fortran,objc,obj-c++,m2
>> --prefix=/usr --with-gcc-major-version-only --program-suffix=-12
>> --program-prefix=arm-linux-gnueabi- --enable-shared
>> --enable-linker-build-id --libexecdir=/usr/lib
>> --without-included-gettext --enable-threads=posix --libdir=/usr/lib
>> --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug
>> --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new
>> --enable-gnu-unique-object --disable-libitm --disable-libquadmath
>> --disable-libquadmath-support --enable-plugin --enable-default-pie
>> --with-system-zlib --enable-libphobos-checking=release
>> --with-target-system-zlib=auto --enable-objc-gc=auto
>> --enable-multiarch --disable-sjlj-exceptions --with-arch=armv5te
>> --with-float=soft --disable-werror --enable-checking=release
>> --build=arm-linux-gnueabi --host=arm-linux-gnueabi
>> --target=arm-linux-gnueabi
>> Thread model: posix
>> Supported LTO compression algorithms: zlib zstd
>> gcc version 12.2.0 (Debian 12.2.0-1)
>>
>> *.ii file:
>> https://people.debian.org/~malat/openvdb/Compression.cc.ii.xz
>>
>>
>> Once again thanks again for your time,
> 
> I've removed:
> 
> -Wa,-mimplicit-it=thumb
> 
> from compilation line and it seems to be going much better
> 
> sorry for the noise. This seems to have been a hack for armhf/Debian
> back in 2002...

Ah, I think Debian/Ubuntu normally use a compiler targetting Thumb code 
(--with-mode=thumb during configure), but that appears to be missing 
from your compiler, so you're probably getting Arm code generated.  GCC 
doesn't generate Arm code with the expectation that IT instructions will 
guard conditional instructions, so yes, you'd get a lot of warnings from 
the assembler in that case.

R.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-08-25 14:09 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-25  6:40 Warning: conditional outside an IT block for Thumb Mathieu Malaterre
2022-08-25 10:28 ` Richard Earnshaw
2022-08-25 13:48   ` Mathieu Malaterre
2022-08-25 13:58     ` Mathieu Malaterre
2022-08-25 14:09       ` Richard Earnshaw

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).