Message ID | 20230911221328.26133-1-kmatsui@gcc.gnu.org |
---|---|
Headers |
Return-Path: <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9ecd:0:b0:3f2:4152:657d with SMTP id t13csp34024vqx; Mon, 11 Sep 2023 15:15:16 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGfyxvqWoHlfc1oyK3bRR6+T7PYpJ9hROvTJq+H7HOQOtxisAuJqSQRbCao/5mxOFw5hizX X-Received: by 2002:a50:fb06:0:b0:525:7da6:be26 with SMTP id d6-20020a50fb06000000b005257da6be26mr8507868edq.28.1694470516408; Mon, 11 Sep 2023 15:15:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694470516; cv=none; d=google.com; s=arc-20160816; b=qxISPMZqLrI/amlS2fDWAMObsja3wffN5dafUz+8W4iyNS3LoQWl5Ky4ms8/M8nGzR nIBdYoDmXjFTQsjwKGDyZ0G8Zvg0gR3PI+yKJ8ryGMkS4U4/CPs4wmsSbCksigDcnDi6 ucsZNWrD5OScNUj0BpYQ0IDDfNeXZfSwsmi+IM4kIG5mOrXE/an1OkhNY3FMLN+Qt2PF 7UK54Vfwp0fHk1grFidQ7oImz/nfP8xMaCYq9CeAg5ZG8Il2nEq++14td8VRp+LV3Zg1 vnBCvJguTAeZKcoVEWF4kUmS+SHMrr53imRpCetVtNsthO6y6j1UibAASiq49Z5CR+ZD czPw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:reply-to:from:list-subscribe:list-help:list-post :list-archive:list-unsubscribe:list-id:precedence :content-transfer-encoding:mime-version:message-id:date:subject:cc :to:dmarc-filter:delivered-to:dkim-signature:dkim-filter; bh=IIXuhvakgdGWLCSbjk1XWM52stHlRo7IcGIfxkhZQ0M=; fh=kSSy/oyUXqQD15FLeKdymIgDBFPFITPA1Gj52CNOxRQ=; b=Px3aGsv0bNWZrp68q7IFHp+TvX13TZfawv1KAuKyhM62SMpPzy4aLTSPQDLUu7u+Yb oFSQZZd7c6yTtZVKsqSmrbEextpdst7vzmj2v70tRrdiODcqXRVAPnUTZ7N5dnouZjES 5HsldlurnjiQiNYUqiSBjYhNLfO5kVSBYtsCBdqM8vOxrkl2PsA2Cbl038fWeZnMryxB c7BDqVX/f2Rlwrg2JeulIzs3Wtt0zUs8LA5fjfc8cfJQC9ocuE3VT3j+2J/tkNuBehOc EIDKb4XS3hLRe0qoGYGUKuSk0VwvblijMW1XliI4xPTbsxmbNRIQWfQrfAzJR4gR5/F2 NsLQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=Nul0+1uO; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from server2.sourceware.org (server2.sourceware.org. [2620:52:3:1:0:246e:9693:128c]) by mx.google.com with ESMTPS id ay14-20020a056402202e00b00523228f6149si6809281edb.100.2023.09.11.15.15.16 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 11 Sep 2023 15:15:16 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) client-ip=2620:52:3:1:0:246e:9693:128c; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=Nul0+1uO; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id F01D53857BB3 for <ouuuleilei@gmail.com>; Mon, 11 Sep 2023 22:14:43 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org F01D53857BB3 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1694470484; bh=IIXuhvakgdGWLCSbjk1XWM52stHlRo7IcGIfxkhZQ0M=; h=To:Cc:Subject:Date:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From:Reply-To:From; b=Nul0+1uO+RaMVIATf1ncwM6gYbKGKqlLAf5/CsZXFOuQyMjT+cfo6xNiEptfkiAGf h/jGA5eCLHtxKJEhkP8uUdeSRr/pX4p2yf5iOHmYP6fR4H0zZwyfZpU3k1e0C7mcAs dH2AWkhy/mgKJNrraUKeCFp/OcaAwvgGSdqUxTBY= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mx0a-00641c01.pphosted.com (mx0a-00641c01.pphosted.com [205.220.165.146]) by sourceware.org (Postfix) with ESMTPS id 25F623858D38; Mon, 11 Sep 2023 22:14:00 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 25F623858D38 Received: from pps.filterd (m0247474.ppops.net [127.0.0.1]) by mx0a-00641c01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 38BLxkNJ030320; Mon, 11 Sep 2023 22:13:59 GMT Received: from mxout22.s.uw.edu (mxout22.s.uw.edu [128.95.242.222]) by mx0a-00641c01.pphosted.com (PPS) with ESMTPS id 3t0g25p1u5-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 11 Sep 2023 22:13:58 +0000 Received: from smtp.washington.edu (smtp.washington.edu [128.208.60.132]) by mxout22.s.uw.edu (8.14.4+UW20.07/8.14.4+UW22.04) with ESMTP id 38BMDThY004929 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 11 Sep 2023 15:13:29 -0700 X-Auth-Received: from localhost.localdomain ([10.154.74.234]) (authenticated authid=kmatsui) by smtp.washington.edu (8.16.1+UW21.10/8.14.4+UW19.10) with ESMTPSA id 38BMDTZi024250 (version=TLSv1.2 cipher=DHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT); Mon, 11 Sep 2023 15:13:29 -0700 X-UW-Orig-Sender: kmatsui@smtp.washington.edu To: gcc-patches@gcc.gnu.org Cc: libstdc++@gcc.gnu.org, Ken Matsui <kmatsui@gcc.gnu.org> Subject: [PATCH 0/2] Optimize is_unbounded_array trait performance Date: Mon, 11 Sep 2023 15:11:40 -0700 Message-ID: <20230911221328.26133-1-kmatsui@gcc.gnu.org> X-Mailer: git-send-email 2.42.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Proofpoint-GUID: YkKmN2WxotUxjuLYOaoOC9zdkrCofdOS X-Proofpoint-ORIG-GUID: YkKmN2WxotUxjuLYOaoOC9zdkrCofdOS X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.267,Aquarius:18.0.957,Hydra:6.0.601,FMLib:17.11.176.26 definitions=2023-09-11_18,2023-09-05_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 malwarescore=0 bulkscore=0 impostorscore=0 priorityscore=1501 mlxscore=0 suspectscore=0 phishscore=0 mlxlogscore=343 spamscore=0 lowpriorityscore=0 adultscore=0 clxscore=1034 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2308100000 definitions=main-2309110205 X-Spam-Status: No, score=-7.0 required=5.0 tests=BAYES_00, JMQ_SPF_NEUTRAL, KAM_DMARC_STATUS, RCVD_IN_DNSWL_LOW, SPF_HELO_NONE, SPF_NEUTRAL, TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> From: Ken Matsui via Gcc-patches <gcc-patches@gcc.gnu.org> Reply-To: Ken Matsui <kmatsui@gcc.gnu.org> Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1776781116409490135 X-GMAIL-MSGID: 1776781116409490135 |
Series |
Optimize is_unbounded_array trait performance
|
|
Message
Ken Matsui
Sept. 11, 2023, 10:11 p.m. UTC
This patch series optimizes is_unbounded_array trait performance. The first patch implements __is_unbounded_array built-in trait. The second patch optimizes is_unbounded_array trait performance by using __is_unbounded_array built-in trait if available. The performance improvement is shown in the following benchmark: https://github.com/ken-matsui/gsoc23/blob/main/is_unbounded_array_v.md#mon-sep-11-030125-pm-pdt-2023 Time: -2.79908% Peak Memory Usage: -1.11666% Total Memory Usage: -2.48356% Ken Matsui (2): c++: Implement __is_unbounded_array built-in trait libstdc++: Optimize is_unbounded_array trait performance gcc/cp/constraint.cc | 3 ++ gcc/cp/cp-trait.def | 1 + gcc/cp/semantics.cc | 4 ++ gcc/testsuite/g++.dg/ext/has-builtin-1.C | 3 ++ gcc/testsuite/g++.dg/ext/is_unbounded_array.C | 37 +++++++++++++++++++ libstdc++-v3/include/std/type_traits | 5 +++ 6 files changed, 53 insertions(+) create mode 100644 gcc/testsuite/g++.dg/ext/is_unbounded_array.C