CFT: tuple changes for ADA

Laurent GUERBY laurent@guerby.net
Sat Nov 11 23:59:00 GMT 2006


On Sat, 2006-11-11 at 06:02 -0400, Aldy Hernandez wrote:
> > Did you test the Ada part? On any recent distro it's
> > just a matter of figuring the package name (on ubuntu it's
> > sudo apt-get install gnat).
> 
> Not yet.  Thanks.

I bootstraped c,ada on x86_64-linux on gimple-tuples-branch (r118663)
and no major breakage Ada-wise:

                === acats tests ===
FAIL:   cdd2a02
FAIL:   cxh1001

                === acats Summary ===
# of expected passes            2313
# of unexpected failures        2

                === gnat tests ===


Running target unix
FAIL: gnat.dg/frame_overflow.adb  (test for errors, line 12)
FAIL: gnat.dg/frame_overflow.adb  (test for errors, line 21)
FAIL: gnat.dg/varsize_temp.adb (test for excess errors)

                === gnat Summary ===

# of expected passes            31
# of unexpected failures        3

The only "new" FAIL against 4.3 mainline from 20061102 is
gnat.dg/varsize_temp.adb:

+===========================GNAT BUG DETECTED==============================+
| 4.3.0 20061030 (experimental) (x86_64-unknown-linux-gnu) Storage_Error stack overflow (or erroneous memory access)|
| Error detected at system.ads:153:5                                       |

To reproduce:

$ gdb /home/guerby/tmp/tuple-build/gcc/gnat1
(gdb) r -I/home/guerby/tmp/gimple-tuples-branch/gcc/testsuite/gnat.dg/
-I/home/guerby/tmp/tuple-build/gcc/ada/rts
-I/home/guerby/tmp/tuple-build/gcc/ada/rts -I- -quiet -dumpbase
varsize_temp.adb
-mtune=generic /home/guerby/tmp/gimple-tuples-branch/gcc/testsuite/gnat.dg/varsize_temp.adb -o varsize_temp.s

Program received signal SIGSEGV, Segmentation fault.
0x00002ac1021610f0 in strlen () from /lib/libc.so.6
(gdb) bt
#0  0x00002ac1021610f0 in strlen () from /lib/libc.so.6
#1  0x000000000096e62d in pp_base_string (pp=0x137e010, str=0x101040101010100 <Address 0x101040101010100 out of bounds>)
    at ../../gimple-tuples-branch/gcc/pretty-print.c:804
#2  0x000000000096f25a in pp_base_format (pp=0x137e010, text=0x7fffa8e57690) at ../../gimple-tuples-branch/gcc/pretty-print.c:449
#3  0x000000000096fde1 in pp_base_format_verbatim (pp=0x101040101010100, text=0x101040101010100) at ../../gimple-tuples-branch/gcc/pretty-print.c:585
#4  0x000000000041df12 in internal_error_function (msgid=0xc4dd88 "tree check: expected class %qs, have %qs (%s) in %s, at %s:%d", ap=0x7fffa8e577a0)
    at ../../gimple-tuples-branch/gcc/ada/misc.c:391
#5  0x0000000000710a91 in diagnostic_report_diagnostic (context=0x12dfe20, diagnostic=0x7fffa8e57760) at ../../gimple-tuples-branch/gcc/diagnostic.c:195
#6  0x0000000000710cee in internal_error (gmsgid=<value optimized out>) at ../../gimple-tuples-branch/gcc/diagnostic.c:588
#7  0x0000000000941069 in tree_class_check_failed (node=0x2ac1023f08c0, cl=tcc_gimple_stmt, file=<value optimized out>, line=541, 
    function=0xba208e "get_rhs") at ../../gimple-tuples-branch/gcc/tree.c:6411
#8  0x00000000006ada8c in get_rhs (stmt=0x101040101010100) at ../../gimple-tuples-branch/gcc/tree-ssa-propagate.c:541
#9  0x0000000000a12cf7 in fold_stmt (stmt_p=0x2ac1023e7810) at ../../gimple-tuples-branch/gcc/tree-ssa-ccp.c:2368
#10 0x00000000009f2766 in remove_useless_stmts_1 (tp=0x101040101010100, data=0x7fffa8e579f0) at ../../gimple-tuples-branch/gcc/tree-cfg.c:1880
#11 0x00000000009f27e7 in remove_useless_stmts_1 (tp=<value optimized out>, data=0x7fffa8e579f0) at ../../gimple-tuples-branch/gcc/tree-cfg.c:1903
#12 0x00000000009f2988 in remove_useless_stmts_1 (tp=0x2ac1023df190, data=0x7fffa8e579f0) at ../../gimple-tuples-branch/gcc/tree-cfg.c:1726
#13 0x00000000009f344c in remove_useless_stmts () at ../../gimple-tuples-branch/gcc/tree-cfg.c:1937
#14 0x000000000097213d in execute_one_pass (pass=0xe75240) at ../../gimple-tuples-branch/gcc/passes.c:870
#15 0x00000000009722ac in execute_pass_list (pass=0xe75240) at ../../gimple-tuples-branch/gcc/passes.c:917
#16 0x000000000065ac28 in tree_lowering_passes (fn=<value optimized out>) at ../../gimple-tuples-branch/gcc/tree-optimize.c:370
#17 0x00000000009d0978 in cgraph_lower_function (node=0x2ac1023e1d80) at ../../gimple-tuples-branch/gcc/cgraphunit.c:457
#18 0x00000000009d1884 in cgraph_analyze_function (node=0x2ac1023e1d80) at ../../gimple-tuples-branch/gcc/cgraphunit.c:948
#19 0x00000000009d1ec8 in cgraph_finalize_function (decl=0x2ac1023df0e0, nested=0 '\0') at ../../gimple-tuples-branch/gcc/cgraphunit.c:486
#20 0x000000000043be12 in gnat_to_gnu (gnat_node=1658) at ../../gimple-tuples-branch/gcc/ada/trans.c:1569
#21 0x0000000000443319 in Compilation_Unit_to_gnu (gnat_node=1643) at ../../gimple-tuples-branch/gcc/ada/trans.c:2540
#22 0x0000000000445091 in gigi (gnat_root=16843008, max_gnat_node=<value optimized out>, number_name=<value optimized out>, 
    nodes_ptr=<value optimized out>, next_node_ptr=<value optimized out>, prev_node_ptr=<value optimized out>, elists_ptr=0x13a89c0, elmts_ptr=0x13a9010, 
    strings_ptr=0x14059b0, string_chars_ptr=0x1403290, list_headers_ptr=0x14207a0, number_units=2, file_info_ptr=0x7fffa8e57db0 "O��\021", 
    standard_integer=62, standard_long_long_float=92, standard_exception_type=1217, gigi_operating_mode=0) at ../../gimple-tuples-branch/gcc/ada/trans.c:247
#23 0x000000000065033e in back_end.call_back_end (mode=back_end__generate_object) at ../../gimple-tuples-branch/gcc/ada/back_end.adb:109
#24 0x0000000000650d1e in gnat1drv () at ../../gimple-tuples-branch/gcc/ada/gnat1drv.adb:626
#25 0x000000000041de3d in gnat_parse_file (set_yydebug=<value optimized out>) at ../../gimple-tuples-branch/gcc/ada/misc.c:249
#26 0x000000000093f1de in toplev_main (argc=<value optimized out>, argv=<value optimized out>) at ../../gimple-tuples-branch/gcc/toplev.c:1033
#27 0x00002ac1021090c4 in __libc_start_main () from /lib/libc.so.6
#28 0x0000000000403b69 in _start ()

I haven't seen this failure in my mainline run a week ago, and I don't
see it on gcc-testresults so it might be caused by something on the
branch. I'm rerunning a mainline bootstrap and check just to make sure.

Laurent




More information about the Gcc-patches mailing list