https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79052
Bug ID: 79052 Summary: bootstrap-ubsan failures due to warnings Product: gcc Version: 7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: bootstrap Assignee: unassigned at gcc dot gnu.org Reporter: msebor at gcc dot gnu.org Target Milestone: --- While verifying fixes for bug 79029 and bug 78608 I see the following errors during bootstrap-ubsan (there might be others, these were just the first few that showed up in a parallel build before it stopped). /opt/notnfs/msebor/src/gcc/trunk/gcc/dwarf2out.c:2060:37: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare] gcc_assert (val1->v.val_unsigned == DWARF2_ADDR_SIZE); /opt/notnfs/msebor/src/gcc/trunk/gcc/system.h:731:14: note: in definition of macro ‘gcc_assert’ ((void)(!(EXPR) ? fancy_abort (__FILE__, __LINE__, __FUNCTION__), 0 : 0)) ^~~~ ... /opt/notnfs/msebor/src/gcc/trunk/gcc/c/gimple-parser.c: In function ‘void c_parser_parse_gimple_body(c_parser*)’: /opt/notnfs/msebor/src/gcc/trunk/gcc/c/gimple-parser.c:1301:34: error: ‘exp1.c_expr::value’ may be used uninitialized in this function [-Werror=maybe-uninitialized] case_label = build_case_label (exp1.value, NULL_TREE, ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~ decl); ~~~~~ /opt/notnfs/msebor/src/gcc/trunk/gcc/c/gimple-parser.c:1283:10: note: ‘exp1.c_expr::value’ was declared here c_expr exp1; ^~~~ /opt/notnfs/msebor/src/gcc/trunk/gcc/c/gimple-parser.c:1377:49: error: ‘cond_expr.c_expr::value’ may be used uninitialized in this function [-Werror=maybe-uninitialized] gimple_seq_add_stmt (seq, gimple_build_switch (cond_expr.value, ~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~ default_label, labels)); ~~~~~~~~~~~~~~~~~~~~~~ /opt/notnfs/msebor/src/gcc/trunk/gcc/c/gimple-parser.c:1255:10: note: ‘cond_expr.c_expr::value’ was declared here c_expr cond_expr; ^~~~~~~~~ ... /opt/notnfs/msebor/src/gcc/trunk/gcc/c-family/c-cppbuiltin.c: In function ‘void c_cpp_builtins(cpp_reader*)’: /opt/notnfs/msebor/src/gcc/trunk/gcc/c-family/c-cppbuiltin.c:848:1: error: ‘%s’ directive argument is null [-Werror=format-length=] c_cpp_builtins (cpp_reader *pfile) ^~~~~~~~~~~~~~ ... /opt/notnfs/msebor/src/gcc/trunk/gcc/c/c-typeck.c: In function ‘char* print_spelling(char*)’: /opt/notnfs/msebor/src/gcc/trunk/gcc/c/c-typeck.c:7022:59: error: null destination pointer [-Werror=format-length=] sprintf (d, "[" HOST_WIDE_INT_PRINT_UNSIGNED "]", p->u.i); ^