From patchwork Tue May 8 15:20:21 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Hubicka X-Patchwork-Id: 910272 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-477368-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=ucw.cz Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="TwVI0lLg"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 40gNTv6KX4z9s27 for ; Wed, 9 May 2018 01:20:34 +1000 (AEST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:subject:message-id:mime-version:content-type; q=dns; s= default; b=UaVxdiyXBAzphh7/53xG9LPj4QOiwRcg+wX4EjpG3Brs0qUP+J2Yp muUgQd9cOeTaiqmDNw4OTLwlZVsH5PMZUdk7w6aPhn1aVkja8BZN6FKaWTjJfMUV qiSvYUgs+X2wczGsFKlpyUdYeGEATXjuTiOxrNcNiitKxrj0LQpx/g= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:subject:message-id:mime-version:content-type; s= default; bh=XRx32ksFj5aE+gwg5OY6RH0hegE=; b=TwVI0lLgkM2oecg/yY/o rUZcz1SbNYkh/AFhqiKLCMtTGK6zlHt1Cfx62IXE+koncJugTrCU1+NU3nQSPHI9 eTlweHmfwVMheT+PVSc2VkwF52ykPtdW+aWXZl7U1gnLxQorzifUx4M0kc8JFgn+ j43UgE1Z+S/Pi270bgO6fXI= Received: (qmail 96191 invoked by alias); 8 May 2018 15:20:25 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 96068 invoked by uid 89); 8 May 2018 15:20:24 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-10.4 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY autolearn=ham version=3.3.2 spammy= X-HELO: nikam.ms.mff.cuni.cz Received: from nikam.ms.mff.cuni.cz (HELO nikam.ms.mff.cuni.cz) (195.113.20.16) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 08 May 2018 15:20:23 +0000 Received: by nikam.ms.mff.cuni.cz (Postfix, from userid 16202) id 63F14540A3E; Tue, 8 May 2018 17:20:21 +0200 (CEST) Date: Tue, 8 May 2018 17:20:21 +0200 From: Jan Hubicka To: rguenther@suse.de, gcc-patches@gcc.gnu.org Subject: Incremental LTO linking part 4: lto-opts support Message-ID: <20180508152021.GD16916@kam.mff.cuni.cz> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.23 (2014-03-12) Hi, this patch prevents lto-option to store some flags that does not make snese to store, in partiuclar dumpdir and -fresolution. These definitly should not be preserved from compile time to link time and in case of incremental linking they caused trouble with wrong resolution file being used in some cases. I guess this is just tip of iceberg - I think we should switch to whitelisting options that needs saving rather than saving everything with few exceptions. This is however a separate issue. Bootstrapped/regtested x86_64-linux, OK? * lto-opts.c (lto_write_options): Skip OPT_dumpdir, OPT_fresolution_. Index: lto-opts.c =================================================================== --- lto-opts.c (revision 260042) +++ lto-opts.c (working copy) @@ -109,6 +109,8 @@ case OPT_SPECIAL_ignore: case OPT_SPECIAL_program_name: case OPT_SPECIAL_input_file: + case OPT_dumpdir: + case OPT_fresolution_: continue; default: