From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3958 invoked by alias); 17 Oct 2005 02:00:56 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 3841 invoked by uid 48); 17 Oct 2005 02:00:50 -0000 Date: Mon, 17 Oct 2005 02:00:00 -0000 Message-ID: <20051017020050.3840.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug rtl-optimization/17356] [4.0/4.1 Regression] [Ada] [ia64] ACATS c41325a & other ICE, also while building libada In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "wilson at gcc dot gnu dot org" X-SW-Source: 2005-10/txt/msg02243.txt.bz2 List-Id: ------- Comment #15 from wilson at gcc dot gnu dot org 2005-10-17 02:00 ------- It is dying in rest_of_handle_flow2 -> split_all_insns -> verify_flow_info. We have non-call insns with EDGE_ABNORMAL_CALL edges attached to them. The insns are coming from post-reload call insn splits. Before splitting, we have (call_insn 118 116 3807 4 (parallel [ (set (reg:OI 8 r8) (call (mem:DI (symbol_ref:DI ("ada__text_io__editing__parse_num\ber_string") [flags 0x3] ) [0 S8 A64]) (const_int 1 [0x1]))) (clobber (reg:DI 320 b0)) (clobber (scratch:DI)) (clobber (scratch:DI)) ]) 257 {call_value_gp} (insn_list:REG_DEP_TRUE 117 (nil)) (expr_list:REG_EH_REGION (const_int 1 [0x1]) (nil)) (expr_list:REG_DEP_TRUE (use (reg:DI 1 r1)) (expr_list:REG_DEP_TRUE (use (reg:TI 120 out0 [ D.1574 ])) (nil)))) after splitting we have (call_insn 4891 116 4892 4 (parallel [ (set (reg:OI 8 r8) (call (mem:DI (symbol_ref:DI ("ada__text_io__editing__parse_num\ber_string") [flags 0x3] ) [0 S8 A64]) (const_int 0 [0x0]))) (clobber (reg:DI 320 b0)) ]) 254 {call_value_nogp} (nil) (expr_list:REG_EH_REGION (const_int 1 [0x1]) (nil)) (expr_list:REG_DEP_TRUE (use (reg:DI 1 r1)) (expr_list:REG_DEP_TRUE (use (reg:TI 120 out0 [ D.1574 ])) (nil)))) (insn 4892 4891 4893 4 (set (reg:DI 1 r1) (plus:DI (reg/f:DI 111 loc79) (const_int -80 [0xffffffffffffffb0]))) 105 {adddi3} (nil) (nil)) (insn 4893 4892 3807 4 (set (reg:DI 1 r1) (mem:DI (reg:DI 1 r1) [0 S8 A64])) 5 {*movdi_internal} (nil) (expr_list:REG_EH_REGION (const_int 1 [0x1]) (nil))) We call find_bb_boundaries to split this into two blocks, and then purge_dead_edges should delete the abnormal call edge on the load. But there is a problem here... Ada sets flag_non_call_exceptions by default. So the load is a trapping insn, just not a call-trapping insn. In purge_dead_edges, we first verify that an EH edge is OK, then we verify that an abnormal call edge is OK. But since an abnormal call edge is always an EH edge, the first test triggers, and passes, because we do need an EH edge here. We can fix this problem by switching the order of the tests. With this patch, a cross-compiler ada build got all of the way to gnattools, where it died building make.adb. This means libada built successfully. The make.adb error is a different unrelated problem. gcc -c -I./ -I/usr/lib64/gcc-lib/x86_64-suse-linux/3.3.3/adalib/../adainclude -\I/usr/lib64/gcc-lib/x86_64-suse-linux/3.3.3/adalib/ -I. -I/home/wilson/GCC/gcc/\gcc/ada -g -O2 -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototype\s -fno-common -gnatpg -gnata -I- /home/wilson/GCC/gcc/gcc/ada/gnatvsn.adb gcc -c -I./ -I/usr/lib64/gcc-lib/x86_64-suse-linux/3.3.3/adalib/../adainclude -\I/usr/lib64/gcc-lib/x86_64-suse-linux/3.3.3/adalib/ -I. -I/home/wilson/GCC/gcc/\gcc/ada -g -O2 -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototype\s -fno-common -gnatpg -gnata -I- /home/wilson/GCC/gcc/gcc/ada/make.adb make.adb:3577:45: Unmatched actual in call make.adb:3581:45: Unmatched actual in call make.adb:3804:13: invalid parameter list in call (use -gnatf for details) make.adb:5709:10: invalid parameter list in call (use -gnatf for details) mlib.ads:75:15: "Attribute" is undefined mlib.ads:75:28: "Time_Stamps" is undefined I am assuming this is good enough to close the problem after a proper bootstrap test. I'll have to try a native ia64 bootstrap now. -- wilson at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|unassigned at gcc dot gnu |wilson at gcc dot gnu dot |dot org |org Status|NEW |ASSIGNED Last reconfirmed|2005-06-12 15:03:55 |2005-10-17 02:00:49 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17356