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

--- Comment #3 from Zdenek Sojka <zsojka at seznam dot cz> ---
(In reply to Jakub Jelinek from comment #1)
> I certainly see a valgrind diagnostics on it:
> valgrind ./cc1 -quiet pr106830.c
> ==2461995== Memcheck, a memory error detector
> ==2461995== Copyright (C) 2002-2022, and GNU GPL'd, by Julian Seward et al.
> ==2461995== Using Valgrind-3.19.0 and LibVEX; rerun with -h for copyright
> info
> ==2461995== Command: ./cc1 -quiet pr106830.c
> ==2461995== 
> pr106830.c:1:1: warning: return type defaults to ‘int’ [-Wimplicit-int]
>     1 | foo0_u16_0() {
>       | ^~~~~~~~~~
> pr106830.c: In function ‘foo0_u16_0’:
> pr106830.c:2:14: warning: integer constant is so large that it is unsigned
>     2 |   (__int128)(18302628885633695743 << 4) ^ 0;
>       |              ^~~~~~~~~~~~~~~~~~~~
> ==2461995== Conditional jump or move depends on uninitialised value(s)
> ==2461995==    at 0xAFCE3D: parser_build_binary_op(unsigned int, tree_code,
> c_expr, c_expr) (c-typeck.cc:3992)
> ==2461995==    by 0xB4ABA2: c_parser_binary_expression(c_parser*, c_expr*,
> tree_node*) (c-parser.cc:8083)
> ==2461995==    by 0xB486A3: c_parser_conditional_expression(c_parser*,
> c_expr*, tree_node*) (c-parser.cc:7651)
> ==2461995==    by 0xB48308: c_parser_expr_no_commas(c_parser*, c_expr*,
> tree_node*) (c-parser.cc:7565)
> 
> so pressumably arg1.m_decimal is uninitialized.
> 

Ah right, my fault, I forgot to add --trace-children=yes, and run valgrind on
the gcc binary instead... thanks.

Reply via email to