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 tree-optimization/42931] New: -ftree-loop-linear - valgrind warns about using uninitialized variable


Command line:
valgrind --trace-children=yes gcc -O1 -ftree-loop-linear -c testcase.c

Tested revisions:
trunk r156367 - fail
trunk r155363 - fail
trunk r153685 - fail
4.4 r156256 - fail
4.4 r155966 - fail
4.4 r155463 - fail
4.4 r155365 - fail
4.4 r154975 - fail
4.4 r153668 - OK
4.4 r149995 - OK
4.4.2 (gentoo) - OK
4.3.4 (gentoo) - fail

Output:
$ valgrind --track-origins=yes
/mnt/svn/gcc-trunk/binary-156367-lto/libexec/gcc/x86_64-unknown-linux-gnu/4.5.0/cc1
-O1 -ftree-loop-linear jquant2-noempty.i
...
Analyzing compilation unit                                                      
Performing interprocedural optimizations                                        
 <visibility> <*free_lang_data> <early_local_cleanups> <whole-program> <inline>
<static-var> <pure-const>Assembling functions:                               
 prescan_quantize update_box==15347== Conditional jump or move depends on
uninitialised value(s)                                                          
==15347==    at 0x61E845: mul_double_with_sign (fold-const.c:422)               
==15347==    by 0xBE645C: double_int_mul (double-int.c:179)                     
==15347==    by 0xC63273: linear_transform_loops (tree-loop-linear.c:249)       
==15347==    by 0x8955A6: tree_linear_transform (tree-ssa-loop.c:261)           
==15347==    by 0x72261A: execute_one_pass (passes.c:1561)                      
==15347==    by 0x7228A4: execute_pass_list (passes.c:1616)                     
==15347==    by 0x7228B6: execute_pass_list (passes.c:1617)                     
==15347==    by 0x7228B6: execute_pass_list (passes.c:1617)                     
==15347==    by 0x818364: tree_rest_of_compilation (tree-optimize.c:413)        
==15347==    by 0x9997D0: cgraph_expand_function (cgraphunit.c:1543)            
==15347==    by 0x99C1F4: cgraph_optimize (cgraphunit.c:1622)                   
==15347==    by 0x99C754: cgraph_finalize_compilation_unit (cgraphunit.c:1093)  
==15347==  Uninitialised value was created by a stack allocation                
==15347==    at 0xC62B71: linear_transform_loops (tree-loop-linear.c:317)       
==15347==                                                                       
==15347== Conditional jump or move depends on uninitialised value(s)            
==15347==    at 0x61E854: mul_double_with_sign (fold-const.c:427)               
==15347==    by 0xBE645C: double_int_mul (double-int.c:179)                     
==15347==    by 0xC63273: linear_transform_loops (tree-loop-linear.c:249)       
==15347==    by 0x8955A6: tree_linear_transform (tree-ssa-loop.c:261)           
==15347==    by 0x72261A: execute_one_pass (passes.c:1561)                      
==15347==    by 0x7228A4: execute_pass_list (passes.c:1616)                     
==15347==    by 0x7228B6: execute_pass_list (passes.c:1617)                     
==15347==    by 0x7228B6: execute_pass_list (passes.c:1617)                     
==15347==    by 0x818364: tree_rest_of_compilation (tree-optimize.c:413)        
==15347==    by 0x9997D0: cgraph_expand_function (cgraphunit.c:1543)            
==15347==    by 0x99C1F4: cgraph_optimize (cgraphunit.c:1622)                   
==15347==    by 0x99C754: cgraph_finalize_compilation_unit (cgraphunit.c:1093)  
==15347==  Uninitialised value was created by a stack allocation                
==15347==    at 0xC62B71: linear_transform_loops (tree-loop-linear.c:317)       
==15347==                                                                       
 fill_inverse_cmap {GC 5348k -> 2791k} pass2_no_dither pass2_fs_dither
init_error_limit finish_pass1 finish_pass2 new_color_map_2_quant
start_pass_2_quant jinit_2pass_quantizer


-- 
           Summary: -ftree-loop-linear - valgrind warns about using
                    uninitialized variable
           Product: gcc
           Version: 4.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: zsojka at seznam dot cz
  GCC host triplet: x86(_64)-pc-linux-gnu
GCC target triplet: x86(_64)-pc-linux-gnu


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


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