https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102196

--- Comment #2 from Jan-Benedict Glaw <jbg...@lug-owl.de> ---
Declaration and possibly uninitialized usage are shown. Ie for said Binutils, I
get these messages:

 microblaze-{elf,linux}
~~~~~~~~~~~~~~~~~~~~~~~~
[all 2021-09-03 18:17:30] depbase=`echo config/tc-microblaze.o | sed
's|[^/]*$|.deps/&|;s|\.o$||'`;\
[all 2021-09-03 18:17:30] /usr/lib/gcc-snapshot/bin/gcc -DHAVE_CONFIG_H -I. 
-I. -I. -I../bfd -I./config -I./../include -I./.. -I./../bfd
-DLOCALEDIR="\"/tmp/gas-microblaze-elf/share/locale\""  -W -Wall
-Wstrict-prototypes -Wmissing-prototypes -Wshadow -Wstack-usage=262144 -Werror
-Wwrite-strings -I./../zlib -g -O2   -MT config/tc-microblaze.o -MD -MP -MF
$depbase.Tpo -c -o config/tc-microblaze.o config/tc-microblaze.c &&\
[all 2021-09-03 18:17:30] mv -f $depbase.Tpo $depbase.Po
[all 2021-09-03 18:17:32] config/tc-microblaze.c: In function 'md_assemble':
[all 2021-09-03 18:17:32] config/tc-microblaze.c:1170:27: error: 'immed' may be
used uninitialized [-Werror=maybe-uninitialized]
[all 2021-09-03 18:17:32]  1170 |       if (immed != (immed % 32))
[all 2021-09-03 18:17:32]       |                    ~~~~~~~^~~~~
[all 2021-09-03 18:17:32] config/tc-microblaze.c:918:16: note: 'immed' declared
here
[all 2021-09-03 18:17:32]   918 |   unsigned int immed, temp;
[all 2021-09-03 18:17:32]       |                ^~~~~
[all 2021-09-03 18:17:32] config/tc-microblaze.c:1746:27: error: 'immed' may be
used uninitialized [-Werror=maybe-uninitialized]
[all 2021-09-03 18:17:32]  1746 |       if (immed != (immed % 32)) {
[all 2021-09-03 18:17:32]       |                    ~~~~~~~^~~~~
[all 2021-09-03 18:17:32] config/tc-microblaze.c:918:16: note: 'immed' declared
here
[all 2021-09-03 18:17:32]   918 |   unsigned int immed, temp;
[all 2021-09-03 18:17:32]       |                ^~~~~
[all 2021-09-03 18:17:32] cc1: all warnings being treated as errors
[all 2021-09-03 18:17:32] make[3]: *** [Makefile:1238: config/tc-microblaze.o]
Error 1


 mcore-elf
~~~~~~~~~~~
[all 2021-09-03 18:17:17] depbase=`echo config/tc-mcore.o | sed
's|[^/]*$|.deps/&|;s|\.o$||'`;\
[all 2021-09-03 18:17:17] /usr/lib/gcc-snapshot/bin/gcc -DHAVE_CONFIG_H -I. 
-I. -I. -I../bfd -I./config -I./../include -I./.. -I./../bfd
-DLOCALEDIR="\"/tmp/gas-mcore-elf/share/locale\""  -W -Wall -Wstrict-prototypes
-Wmissing-prototypes -Wshadow -Wstack-usage=262144 -Werror -Wwrite-strings
-I./../zlib -g -O2   -MT config/tc-mcore.o -MD -MP -MF $depbase.Tpo -c -o
config/tc-mcore.o config/tc-mcore.c &&\
[all 2021-09-03 18:17:17] mv -f $depbase.Tpo $depbase.Po
[all 2021-09-03 18:17:19] config/tc-mcore.c: In function 'md_assemble':
[all 2021-09-03 18:17:19] config/tc-mcore.c:1599:9: error: 'output' may be used
uninitialized [-Werror=maybe-uninitialized]
[all 2021-09-03 18:17:19]  1599 |   output[0] = INST_BYTE0 (inst);
[all 2021-09-03 18:17:19]       |   ~~~~~~^~~
[all 2021-09-03 18:17:19] config/tc-mcore.c:855:10: note: 'output' declared
here
[all 2021-09-03 18:17:19]   855 |   char * output;
[all 2021-09-03 18:17:19]       |          ^~~~~~
[all 2021-09-03 18:17:19] config/tc-mcore.c:1599:9: error: 'output' may be used
uninitialized [-Werror=maybe-uninitialized]
[all 2021-09-03 18:17:19]  1599 |   output[0] = INST_BYTE0 (inst);
[all 2021-09-03 18:17:19]       |   ~~~~~~^~~
[all 2021-09-03 18:17:19] config/tc-mcore.c:855:10: note: 'output' declared
here
[all 2021-09-03 18:17:19]   855 |   char * output;
[all 2021-09-03 18:17:19]       |          ^~~~~~
[all 2021-09-03 18:17:19] config/tc-mcore.c:1599:9: error: 'output' may be used
uninitialized [-Werror=maybe-uninitialized]
[all 2021-09-03 18:17:19]  1599 |   output[0] = INST_BYTE0 (inst);
[all 2021-09-03 18:17:19]       |   ~~~~~~^~~
[all 2021-09-03 18:17:19] config/tc-mcore.c:855:10: note: 'output' declared
here
[all 2021-09-03 18:17:19]   855 |   char * output;
[all 2021-09-03 18:17:19]       |          ^~~~~~
[all 2021-09-03 18:17:20] cc1: all warnings being treated as errors
[all 2021-09-03 18:17:20] make[3]: *** [Makefile:1238: config/tc-mcore.o] Error
1


Unfortunately, the toolchain testing host isn't yet publically hosted, so it's
not yet IPv4-reachable... Once moved to the DC, I'll announce it.

Reply via email to