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 rtl-optimization/54783] New: [4.8 Regression] valgrind reports using uninitialised data in mark_pseudo_regno_live and make_object_born on basic code


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54783

             Bug #: 54783
           Summary: [4.8 Regression] valgrind reports using uninitialised
                    data in mark_pseudo_regno_live and make_object_born on
                    basic code
    Classification: Unclassified
           Product: gcc
           Version: 4.8.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: rtl-optimization
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: zsojka@seznam.cz


Created attachment 28331
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28331
reduced testcase

Compiler output:
$ gcc testcase.c -wrapper valgrind,-q,--track-origins=yes,--num-callers=40
==11379== Conditional jump or move depends on uninitialised value(s)
==11379==    at 0x8A14AD: mark_pseudo_regno_live(int) (sparseset.h:147)
==11379==    by 0x8A27AC: process_bb_node_lives(ira_loop_tree_node*)
(ira-lives.c:1326)
==11379==    by 0x888C1A: ira_traverse_loop_tree(bool, ira_loop_tree_node*,
void (*)(ira_loop_tree_node*), void (*)(ira_loop_tree_node*))
(ira-build.c:1495)
==11379==    by 0x8A3AB1: ira_create_allocno_live_ranges() (ira-lives.c:1591)
==11379==    by 0x88B52C: ira_build() (ira-build.c:3093)
==11379==    by 0x883936: rest_of_handle_ira() (ira.c:4223)
==11379==    by 0x8FF80C: execute_one_pass(opt_pass*) (passes.c:2191)
==11379==    by 0x8FFBC4: execute_pass_list(opt_pass*) (passes.c:2246)
==11379==    by 0x8FFBD6: execute_pass_list(opt_pass*) (passes.c:2247)
==11379==    by 0x6C26A7: expand_function(cgraph_node*) (cgraphunit.c:1601)
==11379==    by 0x6C4811: compile() (cgraphunit.c:1794)
==11379==    by 0x6C4B34: finalize_compilation_unit() (cgraphunit.c:2080)
==11379==    by 0x5A171F: c_write_global_declarations() (c-decl.c:10116)
==11379==    by 0x9E6234: compile_file() (toplev.c:560)
==11379==    by 0x9E7E09: toplev_main(int, char**) (toplev.c:1863)
==11379==    by 0x5A334BC: (below main) (in /lib64/libc-2.15.so)
==11379==  Uninitialised value was created by a heap allocation
==11379==    at 0x4C29A80: malloc (in
/usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==11379==    by 0x1168107: xmalloc (xmalloc.c:147)
==11379==    by 0x9CC85F: sparseset_alloc(unsigned long) (sparseset.c:33)
==11379==    by 0x8A3A3F: ira_create_allocno_live_ranges() (ira-lives.c:1583)
==11379==    by 0x88B52C: ira_build() (ira-build.c:3093)
==11379==    by 0x883936: rest_of_handle_ira() (ira.c:4223)
==11379==    by 0x8FF80C: execute_one_pass(opt_pass*) (passes.c:2191)
==11379==    by 0x8FFBC4: execute_pass_list(opt_pass*) (passes.c:2246)
==11379==    by 0x8FFBD6: execute_pass_list(opt_pass*) (passes.c:2247)
==11379==    by 0x6C26A7: expand_function(cgraph_node*) (cgraphunit.c:1601)
==11379==    by 0x6C4811: compile() (cgraphunit.c:1794)
==11379==    by 0x6C4B34: finalize_compilation_unit() (cgraphunit.c:2080)
==11379==    by 0x5A171F: c_write_global_declarations() (c-decl.c:10116)
==11379==    by 0x9E6234: compile_file() (toplev.c:560)
==11379==    by 0x9E7E09: toplev_main(int, char**) (toplev.c:1863)
==11379==    by 0x5A334BC: (below main) (in /lib64/libc-2.15.so)
==11379== 
==11379== Conditional jump or move depends on uninitialised value(s)
==11379==    at 0x8A138A: make_object_born(ira_object*) (sparseset.h:147)
==11379==    by 0x8A14CA: mark_pseudo_regno_live(int) (ira-lives.c:295)
==11379==    by 0x8A27AC: process_bb_node_lives(ira_loop_tree_node*)
(ira-lives.c:1326)
==11379==    by 0x888C1A: ira_traverse_loop_tree(bool, ira_loop_tree_node*,
void (*)(ira_loop_tree_node*), void (*)(ira_loop_tree_node*))
(ira-build.c:1495)
==11379==    by 0x8A3AB1: ira_create_allocno_live_ranges() (ira-lives.c:1591)
==11379==    by 0x88B52C: ira_build() (ira-build.c:3093)
==11379==    by 0x883936: rest_of_handle_ira() (ira.c:4223)
==11379==    by 0x8FF80C: execute_one_pass(opt_pass*) (passes.c:2191)
==11379==    by 0x8FFBC4: execute_pass_list(opt_pass*) (passes.c:2246)
==11379==    by 0x8FFBD6: execute_pass_list(opt_pass*) (passes.c:2247)
==11379==    by 0x6C26A7: expand_function(cgraph_node*) (cgraphunit.c:1601)
==11379==    by 0x6C4811: compile() (cgraphunit.c:1794)
==11379==    by 0x6C4B34: finalize_compilation_unit() (cgraphunit.c:2080)
==11379==    by 0x5A171F: c_write_global_declarations() (c-decl.c:10116)
==11379==    by 0x9E6234: compile_file() (toplev.c:560)
==11379==    by 0x9E7E09: toplev_main(int, char**) (toplev.c:1863)
==11379==    by 0x5A334BC: (below main) (in /lib64/libc-2.15.so)
==11379==  Uninitialised value was created by a heap allocation
==11379==    at 0x4C29A80: malloc (in
/usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==11379==    by 0x1168107: xmalloc (xmalloc.c:147)
==11379==    by 0x9CC85F: sparseset_alloc(unsigned long) (sparseset.c:33)
==11379==    by 0x8A3A3F: ira_create_allocno_live_ranges() (ira-lives.c:1583)
==11379==    by 0x88B52C: ira_build() (ira-build.c:3093)
==11379==    by 0x883936: rest_of_handle_ira() (ira.c:4223)
==11379==    by 0x8FF80C: execute_one_pass(opt_pass*) (passes.c:2191)
==11379==    by 0x8FFBC4: execute_pass_list(opt_pass*) (passes.c:2246)
==11379==    by 0x8FFBD6: execute_pass_list(opt_pass*) (passes.c:2247)
==11379==    by 0x6C26A7: expand_function(cgraph_node*) (cgraphunit.c:1601)
==11379==    by 0x6C4811: compile() (cgraphunit.c:1794)
==11379==    by 0x6C4B34: finalize_compilation_unit() (cgraphunit.c:2080)
==11379==    by 0x5A171F: c_write_global_declarations() (c-decl.c:10116)
==11379==    by 0x9E6234: compile_file() (toplev.c:560)
==11379==    by 0x9E7E09: toplev_main(int, char**) (toplev.c:1863)
==11379==    by 0x5A334BC: (below main) (in /lib64/libc-2.15.so)
==11379== 

Tested revisions:
r191953 - fail
r191586 - fail
4.7 r191640 - OK


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