From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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 777793850232 for ; Tue, 14 Jun 2022 00:45:50 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 777793850232 Received: from mail-oa1-f71.google.com (mail-oa1-f71.google.com [209.85.160.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-423-7tlncV39NAyOkez4HkhtCQ-1; Mon, 13 Jun 2022 20:45:48 -0400 X-MC-Unique: 7tlncV39NAyOkez4HkhtCQ-1 Received: by mail-oa1-f71.google.com with SMTP id 586e51a60fabf-10139448dd6so2951461fac.0 for ; Mon, 13 Jun 2022 17:45:48 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=ASIRjG/2ldYKshOJo9xH5U7uHqacFLNydzkukLeR3ZM=; b=rB+F5BoSsBSL5HvIsu8ukt7Z7Kt3Wdi/Qugn4Ywl+uho2SdWehyUhgwvpXA0TNsW/6 NhnhfLDfrB0HSK1FBcOZKVSVxPR0ERKXqfyJI1Le+WjWApruj3bY8yVMx8aWq4TRZqQh 2HXdU/3X02m2FbRNKNizoBdhKxjsvDDXdTHjAUT1dtjk+H6P7qaVaXtrbG24YZDYTjlj cxmMGgb0ycw/F8zXQBkvnCS18nT4NBKuVXmVGrwGxHjyTxlsF9SVzrjSh8cpYvUKdstw hYNxKzgmjFgYm/xUiY9cCBEBa4yyxm21/RRTNkLXVkNSQk6bBAL4L4k2nSC939LytW7a he0A== X-Gm-Message-State: AJIora9nzks8euP+Hi2sz3htA5yyNfMJgciR9U5+C1HQKZYVAKUot1am LdI2JvibQWzkpa54O49PZwL7nYNp/abHqtV0jxbftdVTjUy9nSg24reXwTiJDsu80rGuLlmFtAx PzVFwH3odEb1r6RU4rPSzV3uWuq8gSrFLcA== X-Received: by 2002:a05:6870:4307:b0:f2:3989:e85f with SMTP id w7-20020a056870430700b000f23989e85fmr874967oah.265.1655167548078; Mon, 13 Jun 2022 17:45:48 -0700 (PDT) X-Google-Smtp-Source: AGRyM1vfUShejHicllqaCNUntZH2ShTLrXbGahaoxoyEvIBZu84r+slDNa/r11FzXqI73dWV/RZ7Y+wrrMH4G+Xr2wo= X-Received: by 2002:a05:6870:4307:b0:f2:3989:e85f with SMTP id w7-20020a056870430700b000f23989e85fmr874948oah.265.1655167547802; Mon, 13 Jun 2022 17:45:47 -0700 (PDT) MIME-Version: 1.0 References: <20220523192834.3785673-1-dmalcolm@redhat.com> <20220523192834.3785673-8-dmalcolm@redhat.com> <2edbd394896697ef6c72c3203a2fd22ecdb637fb.camel@redhat.com> In-Reply-To: <2edbd394896697ef6c72c3203a2fd22ecdb637fb.camel@redhat.com> From: Aldy Hernandez Date: Mon, 13 Jun 2022 20:45:37 -0400 Message-ID: Subject: Re: PING Re: [PATCH 07/10] value-relation.h: add 'final' and 'override' to relation_oracle vfunc impls To: David Malcolm Cc: gcc-patches , Andrew MacLeod X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-Spam-Status: No, score=-12.5 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, HTML_MESSAGE, KAM_SHORT, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 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-List-Received-Date: Tue, 14 Jun 2022 00:45:54 -0000 Final implies we can't further derive from the derived class, right? If so we may want just override. Andrew, what are your thoughts? Thanks for doing this. Aldy On Mon, Jun 13, 2022, 14:28 David Malcolm wrote: > Ping re this patch: > https://gcc.gnu.org/pipermail/gcc-patches/2022-May/595438.html > > OK for trunk? > > Thanks > Dave > > > On Mon, 2022-05-23 at 15:28 -0400, David Malcolm wrote: > > gcc/ChangeLog: > > * value-relation.h: Add "final" and "override" to > > relation_oracle > > vfunc implementations as appropriate. > > > > Signed-off-by: David Malcolm > > --- > > gcc/value-relation.h | 38 +++++++++++++++++++++----------------- > > 1 file changed, 21 insertions(+), 17 deletions(-) > > > > diff --git a/gcc/value-relation.h b/gcc/value-relation.h > > index 19762d8ce2b..478729be0bf 100644 > > --- a/gcc/value-relation.h > > +++ b/gcc/value-relation.h > > @@ -130,14 +130,15 @@ public: > > equiv_oracle (); > > ~equiv_oracle (); > > > > - const_bitmap equiv_set (tree ssa, basic_block bb); > > + const_bitmap equiv_set (tree ssa, basic_block bb) final override; > > void register_relation (basic_block bb, relation_kind k, tree ssa1, > > - tree ssa2); > > + tree ssa2) override; > > > > - relation_kind query_relation (basic_block, tree, tree); > > - relation_kind query_relation (basic_block, const_bitmap, > > const_bitmap); > > - void dump (FILE *f, basic_block bb) const; > > - void dump (FILE *f) const; > > + relation_kind query_relation (basic_block, tree, tree) override; > > + relation_kind query_relation (basic_block, const_bitmap, > > const_bitmap) > > + override; > > + void dump (FILE *f, basic_block bb) const override; > > + void dump (FILE *f) const override; > > > > protected: > > bitmap_obstack m_bitmaps; > > @@ -185,14 +186,16 @@ public: > > dom_oracle (); > > ~dom_oracle (); > > > > - void register_relation (basic_block bb, relation_kind k, tree op1, > > tree op2); > > + void register_relation (basic_block bb, relation_kind k, tree op1, > > tree op2) > > + final override; > > > > - relation_kind query_relation (basic_block bb, tree ssa1, tree ssa2); > > + relation_kind query_relation (basic_block bb, tree ssa1, tree ssa2) > > + final override; > > relation_kind query_relation (basic_block bb, const_bitmap b1, > > - const_bitmap b2); > > + const_bitmap b2) final override; > > > > - void dump (FILE *f, basic_block bb) const; > > - void dump (FILE *f) const; > > + void dump (FILE *f, basic_block bb) const final override; > > + void dump (FILE *f) const final override; > > private: > > bitmap m_tmp, m_tmp2; > > bitmap m_relation_set; // Index by ssa-name. True if a relation > > exists > > @@ -229,15 +232,16 @@ class path_oracle : public relation_oracle > > public: > > path_oracle (relation_oracle *oracle = NULL); > > ~path_oracle (); > > - const_bitmap equiv_set (tree, basic_block); > > - void register_relation (basic_block, relation_kind, tree, tree); > > + const_bitmap equiv_set (tree, basic_block) final override; > > + void register_relation (basic_block, relation_kind, tree, tree) > > final override; > > void killing_def (tree); > > - relation_kind query_relation (basic_block, tree, tree); > > - relation_kind query_relation (basic_block, const_bitmap, > > const_bitmap); > > + relation_kind query_relation (basic_block, tree, tree) final > > override; > > + relation_kind query_relation (basic_block, const_bitmap, > > const_bitmap) > > + final override; > > void reset_path (); > > void set_root_oracle (relation_oracle *oracle) { m_root = oracle; } > > - void dump (FILE *, basic_block) const; > > - void dump (FILE *) const; > > + void dump (FILE *, basic_block) const final override; > > + void dump (FILE *) const final override; > > private: > > void register_equiv (basic_block bb, tree ssa1, tree ssa2); > > equiv_chain m_equiv; > > >