This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/68785] [6 Regression] valgrind reports issues with folding on x86_64


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

--- Comment #1 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
Created attachment 36952
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=36952&action=edit
unreduced testcase

Here's a reproducer:

trippels@CFARM-IUT-TLSE3 linux % valgrind --track-origins=yes
--trace-children=yes /home/trippels/gcc_test/usr/local/bin/gcc -O3 -c
nsaccess.i
...
==67322== Conditional jump or move depends on uninitialised value(s)
==67322==    at 0xD6F632: get_int_cst_ext_nunits(tree_node*,
generic_wide_int<wide_int_storage> const&) (wide-int.h:795)
==67322==    by 0xD90B52: wide_int_to_tree(tree_node*,
generic_wide_int<wide_int_ref_storage<false> > const&) (tree.c:1432)
==67322==    by 0x808EB4: native_interpret_expr(tree_node*, unsigned char
const*, int) (fold-const.c:7305)
==67322==    by 0x871C03: fold_ctor_reference(tree_node*, tree_node*, unsigned
long, unsigned long, tree_node*) (gimple-fold.c:5500)
==67322==    by 0x8721C9: fold_const_aggregate_ref_1(tree_node*, tree_node*
(*)(tree_node*)) (gimple-fold.c:5616)
==67322==    by 0x87311F: gimple_fold_stmt_to_constant_1(gimple*, tree_node*
(*)(tree_node*), tree_node* (*)(tree_node*)) (gimple-fold.c:5095)
==67322==    by 0xBEE645: evaluate_stmt(gimple*) (tree-ssa-ccp.c:1214)
==67322==    by 0xBEFA0A: visit_assignment(gimple*, tree_node**)
(tree-ssa-ccp.c:2290)
==67322==    by 0xBEFAD7: ccp_visit_stmt(gimple*, edge_def**, tree_node**)
(tree-ssa-ccp.c:2368)
==67322==    by 0xC7E82C: simulate_stmt(gimple*) (tree-ssa-propagate.c:331)
==67322==    by 0xC80385: ssa_propagate(ssa_prop_result (*)(gimple*,
edge_def**, tree_node**), ssa_prop_result (*)(gphi*))
(tree-ssa-propagate.c:509)
==67322==    by 0xBE83E4: (anonymous namespace)::pass_ccp::execute(function*)
(tree-ssa-ccp.c:2408)
==67322==  Uninitialised value was created by a stack allocation
==67322==    at 0x870CED: fold_ctor_reference(tree_node*, tree_node*, unsigned
long, unsigned long, tree_node*) (gimple-fold.c:5468)
...

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]