From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR01-HE1-obe.outbound.protection.outlook.com (mail-he1eur01on20600.outbound.protection.outlook.com [IPv6:2a01:111:f403:2601::600]) by sourceware.org (Postfix) with ESMTPS id 47EC33858D35 for ; Mon, 24 Jun 2024 14:12:28 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 47EC33858D35 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=arm.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 47EC33858D35 Authentication-Results: server2.sourceware.org; arc=pass smtp.remote-ip=2a01:111:f403:2601::600 ARC-Seal: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1719238351; cv=pass; b=YALEIk1fqSaMtl8Diyxnhg4dW72/KHvwlKvDS75NVn/46Tbmpa5ipdaHM/pqoq8kqoXv8UCKzyKFig6PEnWIhtgAG4x9BarXQikgeh0YvrdusK4UQvNdaCzDTWoJFhi8KafBcHQjXePf0D4dw8t6R/mXg8tBO5sdODkHpZN/f8c= ARC-Message-Signature: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1719238351; c=relaxed/simple; bh=Kn4Kjq+rvC8DLKDqfdBLLzbKikguIpBinXyQ5JtXaIA=; h=DKIM-Signature:DKIM-Signature:From:To:Subject:Date:Message-ID: MIME-Version; b=X/tJ3ZPAGaTSaIZS+Q4hPr98s0GVucshk7EmuRTCFd6iBg3uEtSYVcJBhp30ru2Rzjoi6wEolf+Rchh3f+yUOtCVhqJtL0uh9h3gup/DksTvAViGY2sFejLmdNL6UBR8gq+cNei/h35PNzRvrCVrdmvbSf87s7B063UE7INIo/c= ARC-Authentication-Results: i=3; server2.sourceware.org ARC-Seal: i=2; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=pass; b=Nn5KsE522LikH6EPJYH7wiYU/EnUcEq0MsiTF9woRp7Iowkko31heysGL50O98HQnxG7FRTgKW153YgCltjfAdFwNftZGueM54XtZDbVnizScChuB8J0UU6+Iu3lJ9gCNBpjWwOZFZVstcsx8lfZl2lfLBBVdtPGpvc5u3Q78GJGTIj6y6sNjNjCqpIlsl33yGW08n6v4EgkqXKRJjUWGIFcaIsjCUlo0iX4zhvaaXxXoPwchWKah+HLJ3MVbgsmUGFhe7olbz11+kTEMzUfu/j8qtODEf6T2Ol6AJ5xsAFUkLp2vCmIEZ3Qk/PWrgWCJWX0bH2guFn034lfdPKGdA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=fnAy4s3zIwLeWk3L2gzzu/B4pnCZxh6G+IFtKS8tS7Q=; b=fK//g6fg6wsNA28Ai+51cUxN/HKSRmNwGelrr9BQOC6D3RsPJL3agRdjwl/Hqdh31KrD3IxybgMKylM5pnXGjrhdR37uyVr8noYvH92HtEa5A9TaZY6XSnymK761fC1KzQWK/Y1VJN0Wg94UrAr4mbXzGDWHIiLzkRXoxzQHLA2slB6EiIDIQFqfmPfR/BCjd3cOa0zj+bOVqUvQ+uU0vfhuEw30mlFTvAUjglSU5KoMlhAyeGEJfqick+Pgy77NWrS5s/ZUXyo56RI36YHX2FGCbQIA+xShInbcoO1UNu6CePyTvDB0DCEHLQpZ6id4JVZBfuG86uysvwCtBAtXrw== ARC-Authentication-Results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 63.35.35.123) smtp.rcpttodomain=gcc.gnu.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass (signature was verified) header.d=arm.com; arc=pass (0 oda=1 ltdi=1 spf=[1,1,smtp.mailfrom=arm.com] dkim=[1,1,header.d=arm.com] dmarc=[1,1,header.from=arm.com]) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arm.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=fnAy4s3zIwLeWk3L2gzzu/B4pnCZxh6G+IFtKS8tS7Q=; b=MDuzzjhfEn/5Vum7x/4UPZ84iKL0chQGls6kfQyLmpifc0HbxsmSvWQDvC6VqYT6fbuRVq4qxggnmDPiAtdKnJ1SGz0433tsWpgc9VIbLMVCKRoaQ1QGtdV5kqWtdaD3ZZNsp4LFJ0+bY0WoE8xX42JocbW7wZMlWCgXApygF8U= Received: from DBBPR09CA0047.eurprd09.prod.outlook.com (2603:10a6:10:d4::35) by PAWPR08MB9518.eurprd08.prod.outlook.com (2603:10a6:102:2ed::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7698.29; Mon, 24 Jun 2024 14:12:22 +0000 Received: from DU2PEPF00028D02.eurprd03.prod.outlook.com (2603:10a6:10:d4:cafe::85) by DBBPR09CA0047.outlook.office365.com (2603:10a6:10:d4::35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7677.38 via Frontend Transport; Mon, 24 Jun 2024 14:12:22 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; dkim=pass (signature was verified) header.d=arm.com;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; pr=C Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by DU2PEPF00028D02.mail.protection.outlook.com (10.167.242.186) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.7677.15 via Frontend Transport; Mon, 24 Jun 2024 14:12:20 +0000 Received: ("Tessian outbound ab863c298a0f:v347"); Mon, 24 Jun 2024 14:12:20 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: a8d7cb467f544b6f X-CR-MTA-TID: 64aa7808 Received: from dffa43b45ad2.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id D22C5652-1032-42F2-BF32-900D4FD642BF.1; Mon, 24 Jun 2024 14:12:14 +0000 Received: from EUR04-DB3-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id dffa43b45ad2.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Mon, 24 Jun 2024 14:12:14 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ZBYmx/56lnGj7F8MSjmBeqKIxwFjoAwcGxCpvuw8CGW9sSGu0kCYK32ULRDNPpi/hLYNW07RIqzex58JvAJpl6VlwFFaV3nqyfdgpyL8Tgt4tWG8GdImJKeDhQ4tim2m7NOHhIidxLbnzvbVTmaERVtevVV2LAn7FOAalEtDJ9tsCiupHgR8/cTQL7io6l49EwOdMGeY78rqsvphSgSY4AwNKoor5vY5w388QsMCgD2q78Olv7uShan2gg9jZ//zCUDpjSkfuBgLpnkGgcUkxD4koe26PZSCcgVP5+caItovVNfyKsTLzSSnIGjS2q80vXWDtrGtAohiM3eqwK6vlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=fnAy4s3zIwLeWk3L2gzzu/B4pnCZxh6G+IFtKS8tS7Q=; b=UIPnxe1ULvkN3xu8x07n36EF2hINJf7u5+Ny+aWtxUIJaAcN65u5FlMXUkcuz+Zb/Gc8z4uYlNR43sfE7+OAWypTD0fL/aAtpGZgsPcOcbnpvpwZsfZKXFnA59Gh7wzpFxDHXPP5TbPkKSF1a0UfW/gzz5x8qX3IJBUAPYPnNdpuKEwdSWn+P88inqJnE772gC0n5Rmo1g9IpYCnW/Es8KO+oIMBZD6bOeSsjgNfLbSCyH/PCsz1d7KyQbo8eqOqJiIjTIHoYCfunTPitodzNG0Bj9pNtiGzv/TU3jzXIY9RlOUN8cbhQ7FHsmE/fMnz9Jp7eUAyozgDk+Dsck6wgQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arm.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=fnAy4s3zIwLeWk3L2gzzu/B4pnCZxh6G+IFtKS8tS7Q=; b=MDuzzjhfEn/5Vum7x/4UPZ84iKL0chQGls6kfQyLmpifc0HbxsmSvWQDvC6VqYT6fbuRVq4qxggnmDPiAtdKnJ1SGz0433tsWpgc9VIbLMVCKRoaQ1QGtdV5kqWtdaD3ZZNsp4LFJ0+bY0WoE8xX42JocbW7wZMlWCgXApygF8U= Received: from VI1PR08MB5325.eurprd08.prod.outlook.com (2603:10a6:803:13e::17) by DB4PR08MB10343.eurprd08.prod.outlook.com (2603:10a6:10:3fd::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7698.29; Mon, 24 Jun 2024 14:12:11 +0000 Received: from VI1PR08MB5325.eurprd08.prod.outlook.com ([fe80::89dc:c731:362b:7c69]) by VI1PR08MB5325.eurprd08.prod.outlook.com ([fe80::89dc:c731:362b:7c69%7]) with mapi id 15.20.7698.025; Mon, 24 Jun 2024 14:12:11 +0000 From: Tamar Christina To: Richard Biener , "Hu, Lin1" CC: "gcc-patches@gcc.gnu.org" , "Liu, Hongtao" , "ubizjak@gmail.com" Subject: RE: [PATCH 1/3 v3] vect: generate suitable convert insn for int -> int, float -> float and int <-> float. Thread-Topic: [PATCH 1/3 v3] vect: generate suitable convert insn for int -> int, float -> float and int <-> float. Thread-Index: AQHau8vj4zRmR/2N80CCddvabC08GLHNckcAgAMfdICABlw+AIAAGjJg Date: Mon, 24 Jun 2024 14:12:11 +0000 Message-ID: References: <20240611064901.37222-1-lin1.hu@intel.com> <3n8ps3n3-7r70-75q1-436p-8n48r435o6qn@fhfr.qr> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: Authentication-Results-Original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com; x-ms-traffictypediagnostic: VI1PR08MB5325:EE_|DB4PR08MB10343:EE_|DU2PEPF00028D02:EE_|PAWPR08MB9518:EE_ X-MS-Office365-Filtering-Correlation-Id: fd972b35-0d73-43e2-8160-08dc9457a971 x-checkrecipientrouted: true nodisclaimer: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0;ARA:13230037|376011|1800799021|366013|38070700015; X-Microsoft-Antispam-Message-Info-Original: =?us-ascii?Q?c47kp1ozaMFNRFdfSvYBv0irROfffCMQuzQJ7yWIxN0DXpuhmJQPNVH/ODnu?= =?us-ascii?Q?J+t2ak2EHOBU/jxotqxBU9R+mBVtRMIICLHuBpifFe4/iv/7H+f/lXWRoYX+?= =?us-ascii?Q?BwID2Suqprjh2aMbhtYbp97wQJOLGKce7PrY4GzQkkN+1mw6dZ3O/8aRqa1D?= =?us-ascii?Q?feLTfDyou/UI2oTz0k+OVEL6rFqpzhxDk9LhIC8uklYDUD/ZkxX5L2+fJKMJ?= =?us-ascii?Q?JPvXsF4lK+NdzjZz0j5fdj4lyKf63XSO/4ElS6r9TukAHmYBW0f9/GDlO8So?= =?us-ascii?Q?bwf1WpO5t5FctVAmffZTxjrbQy+hWyHC2B5Gs9tcqLxDOHLk4QZ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8kC79bRlIDxN5wXXAb3mrmoT+D7JJcYz0ody?= =?us-ascii?Q?j5iFGl5o0E0xeINjl75eeSWwM+aaoeJb0i8ECyJwAoXxPiEMVE3TkHhvbbJp?= =?us-ascii?Q?Q8sd9K2DBv2QYZwk5vi6nOrnoo4E6bSDXF5L6gpYhYsG7NunUREHx/WNQKW/?= =?us-ascii?Q?umWCxn0=3D?= X-Forefront-Antispam-Report-Untrusted: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:VI1PR08MB5325.eurprd08.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230037)(376011)(1800799021)(366013)(38070700015);DIR:OUT;SFP:1101; Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB4PR08MB10343 Original-Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com; X-EOPAttributedMessage: 0 X-MS-Exchange-Transport-CrossTenantHeadersStripped: DU2PEPF00028D02.eurprd03.prod.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: 9a1aa8e4-55b1-4dd9-eb6f-08dc9457a40c X-Microsoft-Antispam: BCL:0;ARA:13230037|36860700010|376011|1800799021|35042699019|82310400023; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?zY3H9419XToCk5kJQUcIyUVnGWfq+9jh9kyyX2iV4t1KcRotY1bwsyeb3Nez?= =?us-ascii?Q?HObrx7JW4lGVAcAnhEqKcUoGQYV/nzQeiUvgMEdiA325ZesLpotOKdPxYmVM?= =?us-ascii?Q?CZDkenlad2WuAFvHmXmX/+Nqor+gdmlJ1sqtnrfwKTlpBUt0T5a5+tcgccSt?= =?us-ascii?Q?XR4fJrxzg9XnGtdzeMAAxeLmYqgLCKdw+cCNlEKOwd7jOAKZOIXfV5UbB7Bp?= =?us-ascii?Q?Uz5mcROvKfZ0ihfSs7We6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56/fgjv7G?= =?us-ascii?Q?I2exOM5oAQkmdBbBQ52ITSUIlPfK9dB1w3zs2Tr+zqGvVR5kcP62NddC4qNb?= =?us-ascii?Q?1RLpE+UIt9URbTaEUrfdCZwa/P84jLXhW+A/RHQ146Y8kcTLq+QMlzfcL63K?= =?us-ascii?Q?4UFiK2u+Hq8xGikICK97nH/+EkSHtVekksXeK4O0+NnTko8u5za4nbh5k3ws?= =?us-ascii?Q?Pwb20jHiyfBW6NT1IN2d2XNk8avepuVp5uvyOYE6P794Y1qHcmKW1fa+kgNr?= =?us-ascii?Q?ZO4X0psEzeEH7WyGr1M18qzbDmg4o2tQxM6YQRqrnA0jTSBL7A=3D=3D?= X-Forefront-Antispam-Report: CIP:63.35.35.123;CTRY:IE;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:64aa7808-outbound-1.mta.getcheckrecipient.com;PTR:ec2-63-35-35-123.eu-west-1.compute.amazonaws.com;CAT:NONE;SFS:(13230037)(36860700010)(376011)(1800799021)(35042699019)(82310400023);DIR:OUT;SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Jun 2024 14:12:20.5465 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: fd972b35-0d73-43e2-8160-08dc9457a971 X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d;Ip=[63.35.35.123];Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: DU2PEPF00028D02.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAWPR08MB9518 X-Spam-Status: No, score=-12.3 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FORGED_SPF_HELO,GIT_PATCH_0,SPF_HELO_PASS,SPF_NONE,TXREP,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: > -----Original Message----- > From: Richard Biener > Sent: Monday, June 24, 2024 1:34 PM > To: Hu, Lin1 > Cc: gcc-patches@gcc.gnu.org; Liu, Hongtao ; > ubizjak@gmail.com > Subject: RE: [PATCH 1/3 v3] vect: generate suitable convert insn for int = -> int, float > -> float and int <-> float. >=20 > On Thu, 20 Jun 2024, Hu, Lin1 wrote: >=20 > > > > else if (ret_elt_bits > arg_elt_bits) > > > > modifier =3D WIDEN; > > > > > > > > + if (supportable_convert_operation (code, ret_type, arg_type, &co= de1)) > > > > + { > > > > + g =3D gimple_build_assign (lhs, code1, arg); > > > > + gsi_replace (gsi, g, false); > > > > + return; > > > > + } > > > > > > Given the API change I suggest below it might make sense to have > > > supportable_indirect_convert_operation do the above and represent it = as > single- > > > step conversion? > > > > > > > OK, if you want to supportable_indirect_convert_operation can do > > something like supportable_convert_operation, I'll give it a try. This > > functionality is really the part that this function can cover. But this > > would require some changes not only the API change, because > > supportable_indirect_convert_operation originally only supported Float > > -> Int or Int ->Float. >=20 > I think I'd like to see a single API to handle direct and > (multi-)indirect-level converts that operate on vectors with all > the same number of lanes. >=20 > > > > > > > + code_helper code2 =3D ERROR_MARK, code3 =3D ERROR_MARK; > > > > + int multi_step_cvt =3D 0; > > > > + vec interm_types =3D vNULL; > > > > + if (supportable_indirect_convert_operation (NULL, > > > > + code, > > > > + ret_type, arg_type, > > > > + &code2, &code3, > > > > + &multi_step_cvt, > > > > + &interm_types, arg)) > > > > + { > > > > + new_rhs =3D make_ssa_name (interm_types[0]); > > > > + g =3D gimple_build_assign (new_rhs, (tree_code) code3, arg); > > > > + gsi_insert_before (gsi, g, GSI_SAME_STMT); > > > > + g =3D gimple_build_assign (lhs, (tree_code) code2, new_rhs); > > > > + gsi_replace (gsi, g, false); > > > > + return; > > > > + } > > > > + > > > > if (modifier =3D=3D NONE && (code =3D=3D FIX_TRUNC_EXPR || code = =3D=3D > > > FLOAT_EXPR)) > > > > { > > > > - if (supportable_convert_operation (code, ret_type, arg_type,= &code1)) > > > > - { > > > > - g =3D gimple_build_assign (lhs, code1, arg); > > > > - gsi_replace (gsi, g, false); > > > > - return; > > > > - } > > > > /* Can't use get_compute_type here, as supportable_convert_o= peration > > > > doesn't necessarily use an optab and needs two arguments. */ > > > > tree vec_compute_type > > > > diff --git a/gcc/tree-vect-stmts.cc b/gcc/tree-vect-stmts.cc index > > > > 05a169ecb2d..0aa608202ca 100644 > > > > --- a/gcc/tree-vect-stmts.cc > > > > +++ b/gcc/tree-vect-stmts.cc > > > > @@ -5175,7 +5175,7 @@ vectorizable_conversion (vec_info *vinfo, > > > > tree scalar_dest; > > > > tree op0, op1 =3D NULL_TREE; > > > > loop_vec_info loop_vinfo =3D dyn_cast (vinfo); > > > > - tree_code tc1, tc2; > > > > + tree_code tc1; > > > > code_helper code, code1, code2; > > > > code_helper codecvt1 =3D ERROR_MARK, codecvt2 =3D ERROR_MARK; > > > > tree new_temp; > > > > @@ -5384,92 +5384,17 @@ vectorizable_conversion (vec_info *vinfo, > > > > break; > > > > } > > > > > > > > - /* For conversions between float and integer types try wheth= er > > > > - we can use intermediate signed integer types to support the > > > > - conversion. */ > > > > - if (GET_MODE_SIZE (lhs_mode) !=3D GET_MODE_SIZE (rhs_mode) > > > > - && (code =3D=3D FLOAT_EXPR || > > > > - (code =3D=3D FIX_TRUNC_EXPR && !flag_trapping_math))) > > > > - { > > > > - bool demotion =3D GET_MODE_SIZE (rhs_mode) > GET_MODE_SIZE > > > (lhs_mode); > > > > - bool float_expr_p =3D code =3D=3D FLOAT_EXPR; > > > > - unsigned short target_size; > > > > - scalar_mode intermediate_mode; > > > > - if (demotion) > > > > - { > > > > - intermediate_mode =3D lhs_mode; > > > > - target_size =3D GET_MODE_SIZE (rhs_mode); > > > > - } > > > > - else > > > > - { > > > > - target_size =3D GET_MODE_SIZE (lhs_mode); > > > > - if (!int_mode_for_size > > > > - (GET_MODE_BITSIZE (rhs_mode), 0).exists > > > (&intermediate_mode)) > > > > - goto unsupported; > > > > - } > > > > - code1 =3D float_expr_p ? code : NOP_EXPR; > > > > - codecvt1 =3D float_expr_p ? NOP_EXPR : code; > > > > - opt_scalar_mode mode_iter; > > > > - FOR_EACH_2XWIDER_MODE (mode_iter, intermediate_mode) > > > > - { > > > > - intermediate_mode =3D mode_iter.require (); > > > > - > > > > - if (GET_MODE_SIZE (intermediate_mode) > target_size) > > > > - break; > > > > - > > > > - scalar_mode cvt_mode; > > > > - if (!int_mode_for_size > > > > - (GET_MODE_BITSIZE (intermediate_mode), 0).exists > > > (&cvt_mode)) > > > > - break; > > > > - > > > > - cvt_type =3D build_nonstandard_integer_type > > > > - (GET_MODE_BITSIZE (cvt_mode), 0); > > > > - > > > > - /* Check if the intermediate type can hold OP0's range. > > > > - When converting from float to integer this is not necessary > > > > - because values that do not fit the (smaller) target type are > > > > - unspecified anyway. */ > > > > - if (demotion && float_expr_p) > > > > - { > > > > - wide_int op_min_value, op_max_value; > > > > - if (!vect_get_range_info (op0, &op_min_value, > > > &op_max_value)) > > > > - break; > > > > - > > > > - if (cvt_type =3D=3D NULL_TREE > > > > - || (wi::min_precision (op_max_value, SIGNED) > > > > - > TYPE_PRECISION (cvt_type)) > > > > - || (wi::min_precision (op_min_value, SIGNED) > > > > - > TYPE_PRECISION (cvt_type))) > > > > - continue; > > > > - } > > > > - > > > > - cvt_type =3D get_vectype_for_scalar_type (vinfo, cvt_type, = slp_node); > > > > - /* This should only happened for SLP as long as loop vector= izer > > > > - only supports same-sized vector. */ > > > > - if (cvt_type =3D=3D NULL_TREE > > > > - || maybe_ne (TYPE_VECTOR_SUBPARTS (cvt_type), nunits_in) > > > > - || !supportable_convert_operation ((tree_code) code1, > > > > - vectype_out, > > > > - cvt_type, &tc1) > > > > - || !supportable_convert_operation ((tree_code) codecvt1, > > > > - cvt_type, > > > > - vectype_in, &tc2)) > > > > - continue; > > > > - > > > > - found_mode =3D true; > > > > - break; > > > > - } > > > > + if (supportable_indirect_convert_operation (vinfo, > > > > + code, > > > > + vectype_out, > > > > + vectype_in, > > > > + &code1, > > > > + &codecvt1, > > > > + &multi_step_cvt, > > > > + &interm_types, > > > > + op0,slp_node)) > > > > + break; > > > > > > > > - if (found_mode) > > > > - { > > > > - multi_step_cvt++; > > > > - interm_types.safe_push (cvt_type); > > > > - cvt_type =3D NULL_TREE; > > > > - code1 =3D tc1; > > > > - codecvt1 =3D tc2; > > > > - break; > > > > - } > > > > - } > > > > /* FALLTHRU */ > > > > unsupported: > > > > if (dump_enabled_p ()) > > > > @@ -14626,6 +14551,153 @@ supportable_narrowing_operation > > > (code_helper code, > > > > return false; > > > > } > > > > > > > > +/* Function supportable_indirect_convert_operation > > > > + > > > > + Check whether an operation represented by the code CODE is two > > > > + convert operations that are supported by the target platform in > > > > + vector form (i.e., when operating on arguments of type VECTYPE_= IN > > > > + producing a result of type VECTYPE_OUT). > > > > + > > > > + Convert operations we currently support directly are FIX_TRUNC = and > FLOAT. > > > > + This function checks if these operations are supported > > > > + by the target platform directly (via vector tree-codes). > > > > + > > > > + Output: > > > > + - CODE1 is the code of a vector operation to be used when > > > > + converting the operation in the first step, if available. > > > > + - CODE2 is the code of a vector operation to be used when > > > > + converting the operation in the second step, if available. > > > > + - MULTI_STEP_CVT determines the number of required intermediate= steps > > > in > > > > + case of multi-step conversion (like int->short->char - in that = case > > > > + MULTI_STEP_CVT will be 1). In the function, it should be 1. > > > > + - INTERM_TYPES contains the intermediate type required to perfo= rm the > > > > + convert operation (short in the above example). */ > > > > +bool > > > > +supportable_indirect_convert_operation (vec_info *vinfo, > > > > + code_helper code, > > > > + tree vectype_out, > > > > + tree vectype_in, > > > > + code_helper *code1, > > > > + code_helper *code2, > > > > + int *multi_step_cvt, > > > > + vec *interm_types, > > > > > > This API is somewhat awkward, as we're inventing a new one I guess we= can do > > > better. I think we want > > > > > > vec > *converts, > > > > > > covering all code1, code2, multi_step_cvt and interm_types with the > conversion > > > sequence being > > > > > > converts[0].first tem0 =3D converts[0].second op0; > > > converts[1].first tem1 =3D converts[1].second tem; > > > > > > > That's great, this really makes the function work better. > > > > > > > > ... while converts.length () determines the length of the chain, one = being a > direct > > > conversion where then converts[0].first is vectype_out. That would a= llow > > > double -> char to go double -> float -> int -> short -> char for exam= ple. > > > > > > > I'm trying to determine the requirements, do you want this function to > > support multiple conversions (the current implementation just does a > > two-step conversion, like double -> char, which becomes double -> int -= > > > char). Actually we should be able to do all conversions in two steps, i= f > > we have some suitable instructions. I can't think of a scenario where > > multiple conversions are needed yet. Could you give me some examples? O= f > > course, I could tweak this feature in advance if it is for future > > consideration. >=20 > I think the API should support multi-level, not only two levels. The > implementation doesn't need to cover that case unless we run into > such a requirement. Usually vector ISAs allow 2x integer > widening/shortening but not 4x, so a VnDImode -> VnQImode conversion > would need to go via VnSImode and VnHImode (of course some targets > might "help" the vectorizer by providing a VnDImode -> VnQImode > pattern that does the intermediate conversions behind the vectorizers > back). But yes, the original motivation for the vectorizer code > was that float<->int conversions are limited. >=20 I have a similar patch in this area but instead looking at unsigned int <->= double conversion. I would want to avoid complicating this area too much so it w= ould be good if the API doesn't care about sign either and allows the target to = choose the operation mode? My current patch has a backend target hook that asks if the current widenin= g is Preferred as multilevel or single level. For single level I just generate = VEC_PERM_EXPRs with a zero register. Just wanted to bring it up in case we can have a coherent story around this= conversions. Thanks, Tamar > Thanks, > Richard. >=20 > > > > > > > > > + tree op0, > > > > + slp_tree slp_node) > > > > > > I would like to avoid passing VINFO and SLP_NODE here, see below. > > > The same is true for OP0 where the existing use is wrong for SLP alre= ady, but I > > > guess that can stay for now (I opened PR115538 about the wrong-code i= ssue). > > > > > > > Thanks, I have removed them. > > > > > > > > > +{ > > > > + bool found_mode =3D false; > > > > + scalar_mode lhs_mode =3D GET_MODE_INNER (TYPE_MODE (vectype_out)= ); > > > > + scalar_mode rhs_mode =3D GET_MODE_INNER (TYPE_MODE (vectype_in))= ; > > > > + opt_scalar_mode mode_iter; > > > > + tree_code tc1, tc2; > > > > + > > > > + tree cvt_type =3D NULL_TREE; > > > > + poly_uint64 nelts =3D TYPE_VECTOR_SUBPARTS (vectype_in); > > > > + > > > > + (*multi_step_cvt) =3D 0; > > > > + /* For conversions between float and integer types try whether > > > > + we can use intermediate signed integer types to support the > > > > + conversion. */ > > > > + if (GET_MODE_SIZE (lhs_mode) !=3D GET_MODE_SIZE (rhs_mode) > > > > + && (code =3D=3D FLOAT_EXPR > > > > + || (code =3D=3D FIX_TRUNC_EXPR && !flag_trapping_math))) > > > > + { > > > > + bool demotion =3D GET_MODE_SIZE (rhs_mode) > GET_MODE_SIZE > > > (lhs_mode); > > > > + bool float_expr_p =3D code =3D=3D FLOAT_EXPR; > > > > + unsigned short target_size; > > > > + scalar_mode intermediate_mode; > > > > + if (demotion) > > > > + { > > > > + intermediate_mode =3D lhs_mode; > > > > + target_size =3D GET_MODE_SIZE (rhs_mode); > > > > + } > > > > + else > > > > + { > > > > + target_size =3D GET_MODE_SIZE (lhs_mode); > > > > + if (!int_mode_for_size > > > > + (GET_MODE_BITSIZE (rhs_mode), 0).exists (&intermediate_mode= )) > > > > + return false; > > > > + } > > > > + *code1 =3D float_expr_p ? code : NOP_EXPR; > > > > + *code2 =3D float_expr_p ? NOP_EXPR : code; > > > > + opt_scalar_mode mode_iter; > > > > + FOR_EACH_2XWIDER_MODE (mode_iter, intermediate_mode) > > > > + { > > > > + intermediate_mode =3D mode_iter.require (); > > > > + > > > > + if (GET_MODE_SIZE (intermediate_mode) > target_size) > > > > + break; > > > > + > > > > + scalar_mode cvt_mode; > > > > + if (!int_mode_for_size > > > > + (GET_MODE_BITSIZE (intermediate_mode), 0).exists (&cvt_mode= )) > > > > + break; > > > > + > > > > + cvt_type =3D build_nonstandard_integer_type > > > > + (GET_MODE_BITSIZE (cvt_mode), 0); > > > > + > > > > + /* Check if the intermediate type can hold OP0's range. > > > > + When converting from float to integer this is not necessary > > > > + because values that do not fit the (smaller) target type are > > > > + unspecified anyway. */ > > > > + if (demotion && float_expr_p) > > > > + { > > > > + wide_int op_min_value, op_max_value; > > > > + /* For vector form, it looks like op0 doesn't have RANGE_IN= FO. > > > > + In the future, if it is supported, changes may need to be made > > > > + to this part, such as checking the RANGE of each element > > > > + in the vector. */ > > > > + if (!SSA_NAME_RANGE_INFO (op0) > > > > + || !vect_get_range_info (op0, &op_min_value, > > > &op_max_value)) > > > > + break; > > > > + > > > > + if (cvt_type =3D=3D NULL_TREE > > > > + || (wi::min_precision (op_max_value, SIGNED) > > > > + > TYPE_PRECISION (cvt_type)) > > > > + || (wi::min_precision (op_min_value, SIGNED) > > > > + > TYPE_PRECISION (cvt_type))) > > > > + continue; > > > > + } > > > > + > > > > + if (vinfo !=3D NULL && slp_node !=3D NULL) > > > > + cvt_type =3D get_vectype_for_scalar_type (vinfo, cvt_type, sl= p_node); > > > > + else > > > > + { > > > > + bool uns =3D TYPE_UNSIGNED (TREE_TYPE (vectype_out)) > > > > + || TYPE_UNSIGNED (TREE_TYPE (vectype_in)); > > > > + cvt_type =3D build_nonstandard_integer_type > > > > + (GET_MODE_BITSIZE (cvt_mode), uns); > > > > + cvt_type =3D build_vector_type (cvt_type, nelts); > > > > + } > > > > > > So this would then become > > > > > > cvt_type =3D get_related_vectype_for_scalar_type (TYPE_MODE > > > (vectype_in), cvt_type, TYPE_VECTOR_SUBPARTS (vectype_in)); > > > > > > > + /* This should only happened for SLP as long as loop vectorizer > > > > + only supports same-sized vector. */ > > > > + if (cvt_type =3D=3D NULL_TREE > > > > + || maybe_ne (TYPE_VECTOR_SUBPARTS (cvt_type), nelts) > > > > + || !supportable_convert_operation ((tree_code) *code1, > > > > + vectype_out, > > > > + cvt_type, &tc1) > > > > + || !supportable_convert_operation ((tree_code) *code2, > > > > + cvt_type, > > > > + vectype_in, &tc2)) > > > > + continue; > > > > + > > > > + found_mode =3D true; > > > > + break; > > > > + } > > > > + > > > > + if (found_mode) > > > > + { > > > > + (*multi_step_cvt)++; > > > > + interm_types->safe_push (cvt_type); > > > > + cvt_type =3D NULL_TREE; > > > > + *code1 =3D tc1; > > > > + *code2 =3D tc2; > > > > + return true; > > > > + } > > > > + } > > > > + interm_types->release (); > > > > > > Hmm, ownership of interm_types is somewhat unclear here - the caller = should > > > release it, or is the situation that the caller is confused by stray = elements in it? > In > > > that case I'd suggest to instead do interm_types->truncate (0). > > > > > > > It's my fault, I just imitate supportable_narrowing/widening_operation, > > I think for this function, interm_types->release() is not needed.