From patchwork Thu Jan 18 07:36:19 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jakub Jelinek X-Patchwork-Id: 84321 Return-Path: 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 36E0D385842D for ; Thu, 18 Jan 2024 07:37:02 +0000 (GMT) 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 555C13858427 for ; Thu, 18 Jan 2024 07:36:27 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 555C13858427 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 555C13858427 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.129.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1705563388; cv=none; b=r5bYcAnf43xf7UUooBYcXtffLDukQB9iyoYtzBJ1B8xXIDZuyRHAFAZoUl5oKaEE/CJ/B7skZL23Gm/C3cBYYppStPza3i9Sot7SzY5+p9lBuDF33LICGbC6UWrUztvcRuKZoTCPSxnZ5MWXP4QycCQYHfBuZVViRfNtdminJxY= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1705563388; c=relaxed/simple; bh=w4Pebn5v1RofGaZq9E1pCvXzPnXIFfb/onFrFx/ukmY=; h=DKIM-Signature:Date:From:To:Subject:Message-ID:MIME-Version; b=hvImLmBhTpIMYCEH80CBzGD5cL5XbDOcSBdUZsPs6ofpackQVpA9ucd+FhiTAqyDW2TF3u36SiGwR+VZ8vONl3t1unxqERv4VjcdWkHi31/u08SkwTNODEWJhCZzTqlg4ge7uNTf5/zMCm7h0Ha0q8R7X/+YdIfVGhlubo7U2pA= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1705563386; h=from:from:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type; bh=FmzAcIoyHYqxFbHpCr525ef2FXhBjYIvzVhIZqoABaA=; b=I+Kohl7pw1WAkUfBhD9UCsoJWK1GA27RF1qUQA1boHRNglhRAy2fMSrC3pVCLlpjllWO/C YITGsQUPY+GlTwDGoWPrgBJCvCzT9yzryb2AVxpDBEhIZx+SWK4owKV2znpLOjrtqLUSIE YmG3dz271mFR2bp5rBuRQkUnoyj7eHQ= Received: from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-373-k3by5DIUOo-0FdsL-rOHkg-1; Thu, 18 Jan 2024 02:36:24 -0500 X-MC-Unique: k3by5DIUOo-0FdsL-rOHkg-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id B7E401C29EB7; Thu, 18 Jan 2024 07:36:23 +0000 (UTC) Received: from tucnak.zalov.cz (unknown [10.39.192.70]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 7C74E2166B33; Thu, 18 Jan 2024 07:36:23 +0000 (UTC) Received: from tucnak.zalov.cz (localhost [127.0.0.1]) by tucnak.zalov.cz (8.17.1/8.17.1) with ESMTPS id 40I7aKJx226827 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Thu, 18 Jan 2024 08:36:21 +0100 Received: (from jakub@localhost) by tucnak.zalov.cz (8.17.1/8.17.1/Submit) id 40I7aKpp226826; Thu, 18 Jan 2024 08:36:20 +0100 Date: Thu, 18 Jan 2024 08:36:19 +0100 From: Jakub Jelinek To: Richard Biener , Jeff Law Cc: gcc-patches@gcc.gnu.org Subject: [PATCH] opts: Fix up -ffold-mem-offsets option keywords Message-ID: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.6 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Disposition: inline X-Spam-Status: No, score=-4.6 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL, 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 X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Jakub Jelinek Errors-To: gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org Hi! While the option was originally meant to be a Target option for a single target, it is an option for all targets, so should be Common rather than Target, and because it is an optimization option which could be different in between different LTO TUs, I've added Optimization keyword too. From what I can see, Bool is a non-documented non-existing keyword (at least, grep Bool *.awk shows nothing, so I've dropped that too. Seems that the option parsing simply parses and ignores any non-existing keywords. Guess we should drop the Bool keywords from the gcc/config/riscv/riscv.opt file eventually, so that people don't copy this around. Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? 2024-01-18 Jakub Jelinek PR other/113399 * common.opt (ffold-mem-offsets): Remove Target and Bool keywords, add Common and Optimization. Jakub --- gcc/common.opt.jj 2024-01-03 11:51:31.467732078 +0100 +++ gcc/common.opt 2024-01-17 17:22:05.975424001 +0100 @@ -1262,7 +1262,7 @@ Common Var(flag_cprop_registers) Optimiz Perform a register copy-propagation optimization pass. ffold-mem-offsets -Target Bool Var(flag_fold_mem_offsets) Init(1) +Common Var(flag_fold_mem_offsets) Init(1) Optimization Fold instructions calculating memory offsets to the memory access instruction if possible. fcrossjumping