From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate.crashing.org (gate.crashing.org [63.228.1.57]) by sourceware.org (Postfix) with ESMTP id 33FE33858406 for ; Tue, 20 Sep 2022 22:36:08 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 33FE33858406 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=kernel.crashing.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=kernel.crashing.org Received: from gate.crashing.org (localhost.localdomain [127.0.0.1]) by gate.crashing.org (8.14.1/8.14.1) with ESMTP id 28KMZ7Xe011273; Tue, 20 Sep 2022 17:35:07 -0500 Received: (from segher@localhost) by gate.crashing.org (8.14.1/8.14.1/Submit) id 28KMZ6ea011268; Tue, 20 Sep 2022 17:35:06 -0500 X-Authentication-Warning: gate.crashing.org: segher set sender to segher@kernel.crashing.org using -f Date: Tue, 20 Sep 2022 17:35:06 -0500 From: Segher Boessenkool To: will schmidt Cc: GCC patches , David Edelsohn , "Kewen.Lin" Subject: Re: [PATCH, rs6000] Eliminate TARGET_CTZ,TARGET_FCTIDZ,FCTIWUZ defines Message-ID: <20220920223506.GC25951@gate.crashing.org> References: <2cc39864b6a4c52b948f86d54e5988e4d5a37ecb.camel@vnet.ibm.com> <20220920211424.GA25951@gate.crashing.org> <318b813e51ef4c49a63281a146bfe8a4a9d1ce3c.camel@vnet.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <318b813e51ef4c49a63281a146bfe8a4a9d1ce3c.camel@vnet.ibm.com> User-Agent: Mutt/1.4.2.3i X-Spam-Status: No, score=-3.1 required=5.0 tests=BAYES_00,JMQ_SPF_NEUTRAL,KAM_DMARC_STATUS,SPF_HELO_PASS,SPF_PASS,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 List-Id: On Tue, Sep 20, 2022 at 05:01:53PM -0500, will schmidt wrote: > On Tue, 2022-09-20 at 16:14 -0500, Segher Boessenkool wrote: > > > TARGET_FCTIWUZ has a low number of uses, and can be directly > > > replaced with TARGET_POPCNTD. > > > > It is a p7 (ISA 2.06) insn. Please make a TARGET_P7 or such? > > Yes. I do have a change later in the (unposted) series to replace > POPCNTD with POWER7, at a glance thats #17 down the line. In review I > agree with your comment that the in-between changes aren't the best > choices. I'll see about skipping the in-between values and going > straight for POPCNTD->POWER7. First make new TARGET_Px and OPTION_MASK_Px for all "x" you want, and do nothing else than enabling it in the respective CPUs in rs6000-cpus.def . This can be just one patch of course, it is a) bloody simple and b) all is the same. Have that as the very first patch. After that most things will be simple and obvious. But please do keep most later things split out, it is much easier to review. > I am looking at the TARGET_POWER10 notation as the target style, versus > TARGET_P7, but I can go that direction if we think that would be > preferred. Maybe it is since this is a retro-fix versus new. :-) I think TARGET_P7 is a nicely shorter name. It adds up :-) The existing TARGET_P10_SOMETHING do not write it out either btw (and same for P9 and P8). But this is not very important of course. It helps to pick good names from the get go of course, much less work than fixing things later. > > (Don't let me dicsourage you btw, most is pretty straightforward). > > Absolutely.. I do have this mostly covered locally, I just need to > refine a few parts. :-) Looking forward to it! Segher