From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-il1-x144.google.com (mail-il1-x144.google.com [IPv6:2607:f8b0:4864:20::144]) by sourceware.org (Postfix) with ESMTPS id 0B70A3861028 for ; Fri, 31 Jul 2020 11:44:00 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 0B70A3861028 Received: by mail-il1-x144.google.com with SMTP id s21so25054280ilk.5 for ; Fri, 31 Jul 2020 04:44:00 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=NmV9OqWo390LNbwgke+u9Bx7jv4VatjScCc4LjnyVYU=; b=A1nXsko9C/WBa8YoJVvWfSKi045yYZvP3zuTM7gR9MlxfvgQAkbU26z8gQ5WukChLJ kvvSjjofcy8VW8lJE0+QtkP5Cgb4lPIcp87EZlrWMizriWV223VHfHiiiSZYPocwo9fx yTHtyslmNWcIrDo1i2Bm6WpSyyofDNo+RqY6lt5jIFdb4XcMkAvsAvEa5i12U9g0VXlF Pe/ZlIaeIEGE4ULFLV4V9JZTLaykUEdcwHO/bs8PyS60RnzSUOXEihu0eCvIRJlZQ1Wv I+G7Z38u3aXeEDJzKosa9GSRFdMji8lJczUotpssA9ygUIViHutZFmPRnnFtqFmoZASY lrxw== X-Gm-Message-State: AOAM531T05fxFDgkVuXJdaUUiJYgT6mECG3d7Z+tkXIOWFnLhVBO4QUo H0k7nz4tZYMvKIrCJKBKy0h76c8SMN+ycrIaHu+yYENgNIE= X-Google-Smtp-Source: ABdhPJzFAHgpXyshuEeObrM6nBqApVT9cW8NpVmoxDiF/0ww5s60y219cwz76TFGAsaRTaSz18xy/lEr6T6yojQ5WCM= X-Received: by 2002:a92:bf0c:: with SMTP id z12mr3188469ilh.151.1596195839477; Fri, 31 Jul 2020 04:43:59 -0700 (PDT) MIME-Version: 1.0 References: <20200729222258.3016925-1-hjl.tools@gmail.com> <20200730093214.GT9601@bubble.grove.modra.org> <20200731081221.GV9601@bubble.grove.modra.org> <8a754335-b8b4-fa32-bd6b-ee004ff6af3f@redhat.com> <20200731110233.GW9601@bubble.grove.modra.org> In-Reply-To: <20200731110233.GW9601@bubble.grove.modra.org> From: "H.J. Lu" Date: Fri, 31 Jul 2020 04:43:23 -0700 Message-ID: Subject: Re: [PATCH] LTO: Ignore undefined symbols without relocation To: Alan Modra Cc: Nick Clifton , Binutils Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-3.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, KAM_SHORT, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: binutils@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 31 Jul 2020 11:44:01 -0000 On Fri, Jul 31, 2020 at 4:02 AM Alan Modra wrote: > > On Fri, Jul 31, 2020 at 11:07:53AM +0100, Nick Clifton wrote: > > Hi Alan, > > > > > Nick, would you please check that this cures the Fedora build problem? > > > > It works in my local tests. I am going to try a scratch build in Fedora and see if that shows up any problems. > > OK, that's good enough for me. Local testing here didn't show any > problems either. Patch pushed to master. > I compared the results of my fix vs yours: text data bss dec hex filename 46357 1408 712 48477 bd5d yours 45731 1408 712 47851 baeb mine One difference is that my fix doesn't have + U abort@@GLIBC_2.2.5 + U access@@GLIBC_2.2.5 + U __assert_fail@@GLIBC_2.2.5 + U bfd_arch_list + U bfd_close_all_done + U bfd_iterate_over_targets + U bfd_printable_arch_mach + U bfd_scan_vma + U getenv@@GLIBC_2.2.5 + U memset@@GLIBC_2.2.5 + U mkdtemp@@GLIBC_2.2.5 + U mkstemps@@GLIBC_2.11 + U __realpath_chk@@GLIBC_2.4 + U strcpy@@GLIBC_2.2.5 + U strdup@@GLIBC_2.2.5 + U strncmp@@GLIBC_2.2.5 in dynamic symbol table. There are no dynamic relocations against these symbols. These are caused by GCC bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96385 My patch removes these symbol from dynamic symbol table: https://sourceware.org/bugzilla/show_bug.cgi?id=26324 -- H.J.