Message ID | 20240802071210.413366-23-poulhies@adacore.com |
---|---|
State | Committed |
Commit | 913fa16483256daacd576476312dfcc2d2421517 |
Headers |
Return-Path: <gcc-patches-bounces~patchwork=sourceware.org@gcc.gnu.org> X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id DD9A1385E833 for <patchwork@sourceware.org>; Fri, 2 Aug 2024 07:18:02 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-wr1-x431.google.com (mail-wr1-x431.google.com [IPv6:2a00:1450:4864:20::431]) by sourceware.org (Postfix) with ESMTPS id 2E2783858430 for <gcc-patches@gcc.gnu.org>; Fri, 2 Aug 2024 07:12:43 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 2E2783858430 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=adacore.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=adacore.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 2E2783858430 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2a00:1450:4864:20::431 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1722582765; cv=none; b=FGgN58Bc85MC1C52+iKIqEETZYM4YQGQiSlLrheodQE1pPgKuJP/qSEu5C3BKtSazOpQ9aUi2A23rSJnb60c0MK34kW6L9IBM4BZTPTxLtDoocqVsTVKi+4OQr0buX2Lo6IL9JM4HBlYWCo543GECC4/e+1HhhXXEQOLZ8EXwlU= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1722582765; c=relaxed/simple; bh=7hCBWVZOzTO6dgkDBQq6w2JHpZN1W5Iuu5G5NbTDqWM=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=ufDeJXvECJ8J2Qi21Shn60yUDoskAhWxZj8WOti4+RxPHSfkgL7bpTj664yLgq8OSE/8ekGR3onRDEJf//CZuCUUdxOWQg+Tdu9KM9efqIcHe8ToOkpJh62Kdg131lC4OW0DxBpNA9rzMYFpSMtULiQzaVtiduzyxBWJ6eveGk8= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-wr1-x431.google.com with SMTP id ffacd0b85a97d-3685a5e7d3cso4530025f8f.1 for <gcc-patches@gcc.gnu.org>; Fri, 02 Aug 2024 00:12:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=adacore.com; s=google; t=1722582762; x=1723187562; darn=gcc.gnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=o6dhh/nunSGuruYxvhHHYS+1PZk2dXaIhsH0OYnekdI=; b=baNhXPYsHPvjUzUeYQ9mL/yhgW+1b441MpWi5V3lSD3HEL7i1vm/Fl/t7mrFfZdrth dB85ZJjGwokiFIGzdZIPDi2EX6J5KfRNm5rkBm4x/bxN9OqYgdA2xWubrqNUXWySIbkP A6DfKGypyfwF07ticlisv6vAI65gxlbyZiVuoullPuNkOEmiEf6I5qjWFi8wDft6h/X1 u6lh77YMpBVat3Ajd0mhqiKxDW1SQNQpjKwvYyCP6EOB9X60Q8o0SOQLvSgvZMIeONjJ /OBbraGcMywW29FpsFT2QBVXRLJSkdrCR4qfryhiREwFf1fh67uB2pErFBURKeKWFV7z xBvQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1722582762; x=1723187562; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=o6dhh/nunSGuruYxvhHHYS+1PZk2dXaIhsH0OYnekdI=; b=v10ivg0Vlq4nDn8QGtr87HBfrJKRsQIlIkUck64tIVzmG3FEWHbetXxIDdJpp+aRg7 qiSjmyOCBcOdOXl8eO5W+GUBxbWMy/bIb2x5MIiKlivmWHXZ7C55e4efJSkhkCNfgIgy OOTStCZrXaxOUpAdyzeolCFgu+jAstbC4/G4EwRrgVeJhxk9y8Ktsf6UdGwDw9syGhuo VpkhXbTgI7UTEeJHY3lXNjDV+oYS9mR6fRL5Axm9PkCxIBSDtp6mORtDxA2kuNjIm50X lqmuV9k7uLshQGiPRTMXbjGkmkaFCeeKrJA2RYSfA7vqc0mYyRWoQX7KtgxAhyyRW3qc 0oCw== X-Gm-Message-State: AOJu0YzUKRGV7dCC3cQiuBbNg9g95fm1GmktlAef0a9poBgsV+otYhni 2n74jUcxzCL/G0CQyMz93sST8LtZxwzw0QHaVbXQrcXhRrTa+oWOok9OrRQxEftHzrpTN7AUcgv iEA== X-Google-Smtp-Source: AGHT+IG0MfVBcgjtaNC3Ge/h1OGqq9arcRahjOy4fCGPvA0qp9ZM4OZSH1S7qii84iqshFu5Kiu3yw== X-Received: by 2002:a5d:568f:0:b0:367:9621:6fa with SMTP id ffacd0b85a97d-36bbc131530mr1506113f8f.37.1722582761938; Fri, 02 Aug 2024 00:12:41 -0700 (PDT) Received: from localhost.localdomain ([2001:861:3382:1a90:b6aa:4751:9ea1:da1e]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-36bbd059932sm1195770f8f.69.2024.08.02.00.12.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 Aug 2024 00:12:41 -0700 (PDT) From: =?utf-8?q?Marc_Poulhi=C3=A8s?= <poulhies@adacore.com> To: gcc-patches@gcc.gnu.org Cc: Piotr Trojanek <trojanek@adacore.com> Subject: [COMMITTED 23/26] ada: Simplify manipulation of the list with loop actions Date: Fri, 2 Aug 2024 09:11:40 +0200 Message-ID: <20240802071210.413366-23-poulhies@adacore.com> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20240802071210.413366-1-poulhies@adacore.com> References: <20240802071210.413366-1-poulhies@adacore.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-13.7 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, 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.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> Errors-To: gcc-patches-bounces~patchwork=sourceware.org@gcc.gnu.org |
Series |
[COMMITTED,01/26] ada: Fix detection of suspicious loop patterns
|
|
Checks
Context | Check | Description |
---|---|---|
linaro-tcwg-bot/tcwg_gcc_build--master-arm | fail | Patch failed to apply |
linaro-tcwg-bot/tcwg_gcc_build--master-aarch64 | fail | Patch failed to apply |
Commit Message
Marc Poulhiès
Aug. 2, 2024, 7:11 a.m. UTC
From: Piotr Trojanek <trojanek@adacore.com>
Code cleanup; behavior is unaffected.
gcc/ada/
* exp_aggr.adb (Add_Loop_Actions): Change manipulation of list
to avoid unnecessary calls to Parent and Loop_Actions.
Tested on x86_64-pc-linux-gnu, committed on master.
---
gcc/ada/exp_aggr.adb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gcc/ada/exp_aggr.adb b/gcc/ada/exp_aggr.adb index 7a2d0570dbd..8496fcd9b00 100644 --- a/gcc/ada/exp_aggr.adb +++ b/gcc/ada/exp_aggr.adb @@ -1262,9 +1262,9 @@ package body Exp_Aggr is elsif Nkind (Parent (Expr)) = N_Component_Association and then Present (Loop_Actions (Parent (Expr))) then - Append_List (Lis, Loop_Actions (Parent (Expr))); Res := Loop_Actions (Parent (Expr)); Set_Loop_Actions (Parent (Expr), No_List); + Append_List (Lis, To => Res); return Res; else