From patchwork Mon Sep 19 13:52:29 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Patrick Palka X-Patchwork-Id: 1297 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5044:0:0:0:0:0 with SMTP id h4csp973888wrt; Mon, 19 Sep 2022 06:53:18 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6UazPx1IOVk237/LaCx+TJb6CAniX/bdlxqR1P53r8IGPsRYuUfaZBicV14Fms7x0vXUTT X-Received: by 2002:a17:906:6a0e:b0:77c:a049:7cfc with SMTP id qw14-20020a1709066a0e00b0077ca0497cfcmr12531252ejc.732.1663595598697; Mon, 19 Sep 2022 06:53:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663595598; cv=none; d=google.com; s=arc-20160816; b=ItAqWZteY6f6UbBk/xHLiVB/Lxsu/WGLmfOqMjnO/EzKrnPwclbVaEpIUdXqgVqBGv BF4Le/dG+buUmSGD02FlZhAO7ZFEg80tkz3PG13IWi1peaargR5Mi+68BXN7ffdbmD+M TUvDFOEIsbUboYxeNdd9Zm3ifvpA2A4YYOYWkejCjFYBeO6AxSPmmMORkd3YQbHB5W+9 G5KNuEwOW3Z3ackViY+oGGtYz0Xj9VJyYPukb7idSIvNxYKuAi96MYfrmLDpbi8MKfdy HTndH+JqXZzvEO85Ga2Gxm8+Bf5fhacPuv7oX/qL+ohWtLC1eFxapj/0HXivsrSltmyD VfnQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc: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:to :dmarc-filter:delivered-to:dkim-signature:dkim-filter; bh=UPGQ0c4GVb1hYvj3+jU+w7sd4nhQTApOSJcIP1mdF74=; b=xuXhpO5fYI4fmKvXvnBY7XKJHMe9ZkmzvAtto1nxovrs9KVHVtshQGscEg1MdzCrMO yIoxklOgR72IMm5WW/7BPxQ7qAnglbcRYFNojKvk2AbshTm60ihtLdB5Bo8vPetPP8bB I6FMvh9PRBFaMCoFz2Ad+glAY/16fTeTHZQ2u3ujme0LF9o5XI0IIoNcs+JpSuYZAOmj jdAOU06OOk+of3BlCbL8lz3xbgrpTwARmXBV/1Rb06i2uupEHeWRWo7ccOKyFnYcAdbN ecC6lloa4nWDzVYz3ZuDVu8jS0RDw1L4TJxIarpLfVS4SsRB4Vrvc4sCasSpFZonuPO1 PSrg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=Zon3KRo+; 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 sourceware.org (server2.sourceware.org. [2620:52:3:1:0:246e:9693:128c]) by mx.google.com with ESMTPS id i11-20020a1709064fcb00b0077984f39dcfsi12220065ejw.408.2022.09.19.06.53.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Sep 2022 06:53:18 -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=Zon3KRo+; 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 80C273858418 for ; Mon, 19 Sep 2022 13:53:17 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 80C273858418 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1663595597; bh=UPGQ0c4GVb1hYvj3+jU+w7sd4nhQTApOSJcIP1mdF74=; h=To:Subject:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:Cc:From; b=Zon3KRo+4mY4sc1cmZpKJDDBlhbD2WgwGohCacj9bkL8goEfeI0qW0gDioNxqbumU +xBt1Fgi8sYulxJ7n2pzcZjXDSRD5bX8LB/1g6pPTd7+HTeqF/gv4Fb7asNBbq/Mth mP6MKaxz/6BhjYtL9pE31nuK+XShP65NtCqbuhLw= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id 200703858D28 for ; Mon, 19 Sep 2022 13:52:35 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 200703858D28 Received: from mail-qk1-f197.google.com (mail-qk1-f197.google.com [209.85.222.197]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-457-mA0ILnN6P22EErj30k8grA-1; Mon, 19 Sep 2022 09:52:33 -0400 X-MC-Unique: mA0ILnN6P22EErj30k8grA-1 Received: by mail-qk1-f197.google.com with SMTP id n15-20020a05620a294f00b006b5768a0ed0so24136392qkp.7 for ; Mon, 19 Sep 2022 06:52:33 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date; bh=UPGQ0c4GVb1hYvj3+jU+w7sd4nhQTApOSJcIP1mdF74=; b=ZhZqmKdfIRJlKeFQ+xxgJQBUVv/PfgNTUEwoAM83G71RA1uJvVlgLDovbg1qHzq7Bd Ro3xnJTCxKveV5J84Z2N84hDIiu1/bxujvdQ7bD3ijXfsCZLPVi2vfq8dwyo7OOf7wSv 3CEYif3KGxA87NqAvmyFtBpHB3vckwwAVdmJ7e18h9nu0g0U/eXIrQEoXdh7mP/8WnPt F7HVWJita3Ojsrqd/YIkj0BGCH+MFZ3UwGvpM3GzZ9DkTJRrnpo6C5DqB000MxXYDg0h qSio4Grc3ael8JWIKueJCCx3DVXz21J7Gf2MKCDIwEdhQaLwTGG8eROE5mQ5Xatic51t L6nQ== X-Gm-Message-State: ACrzQf3AsznXZfl+HyxvSeqkfsnhDQFPqZXmVLAVadQ0vjlSbav8XmiW Ga24eFjhNwE94cqEGyjf1qqluQeZLrNNI8Q5eHCKDde5pg8NpQNOrSCs43kKX0zH8IQ9EkuLv3o AlLbQQs35Mn/9uM0IKPWHhED/vNdeQy3g6fYSDQZTI7dgGiNZOK0tI4ioP5srAgi+8F8= X-Received: by 2002:a05:6214:e6f:b0:4ad:d5a:f09b with SMTP id jz15-20020a0562140e6f00b004ad0d5af09bmr13919302qvb.34.1663595552713; Mon, 19 Sep 2022 06:52:32 -0700 (PDT) X-Received: by 2002:a05:6214:e6f:b0:4ad:d5a:f09b with SMTP id jz15-20020a0562140e6f00b004ad0d5af09bmr13919268qvb.34.1663595552428; Mon, 19 Sep 2022 06:52:32 -0700 (PDT) Received: from localhost.localdomain (ool-457670bb.dyn.optonline.net. [69.118.112.187]) by smtp.gmail.com with ESMTPSA id n7-20020a05620a294700b006b949afa980sm13307846qkp.56.2022.09.19.06.52.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Sep 2022 06:52:31 -0700 (PDT) To: gcc-patches@gcc.gnu.org Subject: [PATCH] c++: stream PACK_EXPANSION_EXTRA_ARGS [PR106761] Date: Mon, 19 Sep 2022 09:52:29 -0400 Message-Id: <20220919135229.86545-1-ppalka@redhat.com> X-Mailer: git-send-email 2.38.0.rc0 MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-Spam-Status: No, score=-14.4 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_LOW, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham 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.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Patrick Palka via Gcc-patches From: Patrick Palka Reply-To: Patrick Palka Cc: nathan@acm.org Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1744406418259767394?= X-GMAIL-MSGID: =?utf-8?q?1744406418259767394?= It looks like some xtreme-header-* tests are failing after the libstdc++ change r13-2158-g02f6b405f0e9dc ultimately because we're neglecting to stream PACK_EXPANSION_EXTRA_ARGS, which leads to false equivalences of different partial instantiations of _TupleConstraints::__constructible. Tested on x86_64-pc-linux-gnu, does this look OK for trunk? PR c++/106761 gcc/cp/ChangeLog: * module.cc (trees_out::type_node) : Stream PACK_EXPANSION_EXTRA_ARGS. (trees_in::tree_node) : Likewise. --- gcc/cp/module.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gcc/cp/module.cc b/gcc/cp/module.cc index 1a1ff5be574..9a9ef4e3332 100644 --- a/gcc/cp/module.cc +++ b/gcc/cp/module.cc @@ -8922,6 +8922,7 @@ trees_out::type_node (tree type) if (streaming_p ()) u (PACK_EXPANSION_LOCAL_P (type)); tree_node (PACK_EXPANSION_PARAMETER_PACKS (type)); + tree_node (PACK_EXPANSION_EXTRA_ARGS (type)); break; case TYPENAME_TYPE: @@ -9455,12 +9456,14 @@ trees_in::tree_node (bool is_use) { bool local = u (); tree param_packs = tree_node (); + tree extra_args = tree_node (); if (!get_overrun ()) { tree expn = cxx_make_type (TYPE_PACK_EXPANSION); SET_TYPE_STRUCTURAL_EQUALITY (expn); PACK_EXPANSION_PATTERN (expn) = res; PACK_EXPANSION_PARAMETER_PACKS (expn) = param_packs; + PACK_EXPANSION_EXTRA_ARGS (expn) = extra_args; PACK_EXPANSION_LOCAL_P (expn) = local; res = expn; }