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 1DA443858C50 for ; Sun, 23 Apr 2023 20:21:05 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1DA443858C50 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 33NKJ0Zp023593; Sun, 23 Apr 2023 15:19:00 -0500 Received: (from segher@localhost) by gate.crashing.org (8.14.1/8.14.1/Submit) id 33NKJ0Tj023592; Sun, 23 Apr 2023 15:19:00 -0500 X-Authentication-Warning: gate.crashing.org: segher set sender to segher@kernel.crashing.org using -f Date: Sun, 23 Apr 2023 15:19:00 -0500 From: Segher Boessenkool To: Paul Koning Cc: gcc-patches@gcc.gnu.org Subject: Re: [PATCH] Turn on LRA on all targets Message-ID: <20230423201900.GJ19790@gate.crashing.org> References: <283c45ca085ced958cbce6e64331252c83a5899f.1682268126.git.segher@kernel.crashing.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,JMQ_SPF_NEUTRAL,KAM_DMARC_STATUS,SPF_HELO_PASS,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE 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: Hi! On Sun, Apr 23, 2023 at 02:36:05PM -0400, Paul Koning wrote: > > On Apr 23, 2023, at 12:47 PM, Segher Boessenkool wrote: > > 1) Targets that already always have LRA, but that redefine the hook > > anyway. These are gcn, pdp11, rx, sparc, vax, and xtensa. Nothing > > really changes for these targets with this patch (but later patches > > will delete the superfluous hook implementations). > > I thought that the existing coding for pdp11 makes LRA selectable (via -mlra) and defaults to off. static bool pdp11_lra_p (void) { return TARGET_LRA; } Ah, that is a target flag, not an enum value or such? Aha! mlra Target Mask(LRA) Use LRA register allocator. This is true for sparc and vax and xtensa as well, and rx with TARGET_ENABLE_LRA. gcn does in fact do #define TARGET_LRA_P hook_bool_void_true which is a funny way to have the same effect as not defining it at all. So these five targets are category 2). Thanks for correcting me! > I had planned to change it to default to on but leave it selectable. I suppose just having it on is ok too, although the code from LRA wasn't as efficient as the old last I looked (which is a while ago). The plan is to delete old reload completely, with all follow-up simplifications and cleanups. Segher