From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 86CEC3858C50; Tue, 12 Sep 2023 11:49:50 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 86CEC3858C50 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1694519390; bh=JN2X4zQ58Jg0z7z8i6gSyfXRvbQNGNPyVPuxpU9Phi8=; h=From:To:Subject:Date:In-Reply-To:References:From; b=K9JJLqwGBvoWjC7RT5BEX+WqpY5xN9AuMQCX13ze5LVLdq08SLEkFowXC11SK97pJ PARrRwZYW/7bomZE4shpTrM0eyB3SjbM9H0Vx7E4vQSveb5AFyT6xw32IM/EsYAftl sxDP+lsTUf9DjQ2osfHLhHnzs1FYdi9uKitxn4ro= From: "juzhe.zhong at rivai dot ai" To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/111337] ICE in gimple-isel.cc for RISC-V port Date: Tue, 12 Sep 2023 11:49:50 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: middle-end X-Bugzilla-Version: 14.0 X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: juzhe.zhong at rivai dot ai X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D111337 --- Comment #3 from JuzheZhong --- (In reply to Richard Biener from comment #2) > vect_patt_67.34_168 =3D VEC_COND_EXPR }>; > vect_patt_68.35_169 =3D (vector([4,4]) int) vect_patt_67.34_168; >=20 > -> >=20 > vect_patt_68.35_169 =3D VEC_COND_EXPR }>; >=20 > this one looks odd - it's probably >=20 > /* Sink unary conversions to branches, but only if we do fold both=20 > and the target's truth type is the same as we already have. */ > (simplify > (convert (vec_cond:s @0 @1 @2)) > (if (VECTOR_TYPE_P (type)=20 > && types_match (TREE_TYPE (@0), truth_type_for (type))) > (vec_cond @0 (convert! @1) (convert! @2))))=20 >=20 > the problem is that this happily produces a vec_cond we might not be able > to expand - having the same truth type for the data type isn't enough > if there's no optab with a matching data mode. Same for the view_convert > case. >=20 > It's a bit convoluted to ask for target support here, can you double-check > it isn't possible to add native riscv expanders for the missing case? You mean support(In reply to Richard Biener from comment #2) > vect_patt_67.34_168 =3D VEC_COND_EXPR }>; > vect_patt_68.35_169 =3D (vector([4,4]) int) vect_patt_67.34_168; >=20 > -> >=20 > vect_patt_68.35_169 =3D VEC_COND_EXPR }>; >=20 > this one looks odd - it's probably >=20 > /* Sink unary conversions to branches, but only if we do fold both=20 > and the target's truth type is the same as we already have. */ > (simplify > (convert (vec_cond:s @0 @1 @2)) > (if (VECTOR_TYPE_P (type)=20 > && types_match (TREE_TYPE (@0), truth_type_for (type))) > (vec_cond @0 (convert! @1) (convert! @2))))=20 >=20 > the problem is that this happily produces a vec_cond we might not be able > to expand - having the same truth type for the data type isn't enough > if there's no optab with a matching data mode. Same for the view_convert > case. >=20 > It's a bit convoluted to ask for target support here, can you double-check > it isn't possible to add native riscv expanders for the missing case? You mean we should add "vcond" patterns back ?=