Bug 45626 - [4.6 Regression] Segfault in fold_const_aggregate_ref
Summary: [4.6 Regression] Segfault in fold_const_aggregate_ref
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: tree-optimization (show other bugs)
Version: 4.6.0
: P3 normal
Target Milestone: 4.6.0
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-09-10 03:02 UTC by Ryan Mansfield
Modified: 2010-09-21 13:56 UTC (History)
2 users (show)

See Also:
Host: i686-pc-linux-gnu
Target: i686-pc-linux-gnu
Build: i686-pc-linux-gnu
Known to work:
Known to fail:
Last reconfirmed: 2010-09-10 04:27:15


Attachments
preprocessed source (2.76 KB, text/plain)
2010-09-10 03:03 UTC, Ryan Mansfield
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ryan Mansfield 2010-09-10 03:02:42 UTC
$ ./xgcc -v
Using built-in specs.
COLLECT_GCC=./xgcc
Target: i686-pc-linux-gnu
Configured with: ../configure --enable-languages=c --disable-bootstrap --enable-checking=all
Thread model: posix
gcc version 4.6.0 20100909 (experimental) [trunk revision 164131] (GCC) 


$ ./xgcc -B. -O -g ~/t.i
<snip>
/home/ryan/t.i: In function ‘yyparse’:
/home/ryan/t.i:19:5: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.


#0  fold_const_aggregate_ref (t=0xb7ea47a8) at ../../gcc/tree-ssa-ccp.c:1351
#1  0x08beb6a3 in maybe_fold_reference (expr=0xb7ea47a8, is_lhs=0 '\000')
    at ../../gcc/gimple-fold.c:480
#2  0x08bf203e in fold_stmt_1 (gsi=<value optimized out>, 
    inplace=<value optimized out>) at ../../gcc/gimple-fold.c:1559
#3  0x08791c6e in fold_marked_statements (first=<value optimized out>, 
    statements=0x8f68418) at ../../gcc/tree-inline.c:4114
#4  0x08797943 in optimize_inline_calls (fn=0xb7f18e80)
    at ../../gcc/tree-inline.c:4213
#5  0x087668d8 in inline_transform (node=0xb7ead7a8)
    at ../../gcc/ipa-inline.c:2165
#6  0x084152be in execute_one_ipa_transform_pass () at ../../gcc/passes.c:1473
#7  execute_all_ipa_transforms () at ../../gcc/passes.c:1504
#8  0x08584c30 in tree_rest_of_compilation (fndecl=0xb7f18e80)
    at ../../gcc/tree-optimize.c:445
#9  0x0875a2bc in cgraph_expand_function (node=<value optimized out>)
    at ../../gcc/cgraphunit.c:1469
#10 0x0875d621 in cgraph_expand_all_functions () at ../../gcc/cgraphunit.c:1548
#11 cgraph_optimize () at ../../gcc/cgraphunit.c:1804
#12 0x0875daaa in cgraph_finalize_compilation_unit ()
    at ../../gcc/cgraphunit.c:1012
#13 0x080d5ea6 in c_write_global_declarations () at ../../gcc/c-decl.c:9736
#14 0x08523104 in compile_file (argc=15, argv=0xbffff154)
Comment 1 Ryan Mansfield 2010-09-10 03:03:11 UTC
Created attachment 21759 [details]
preprocessed source
Comment 2 H.J. Lu 2010-09-10 04:27:15 UTC
It is caused by revision 163808:

http://gcc.gnu.org/ml/gcc-cvs/2010-09/msg00099.html
Comment 3 Richard Biener 2010-09-21 13:56:52 UTC
Fixed.