Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp4844849pxb; Wed, 20 Apr 2022 11:12:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJznjcS1yfynuKxE/hIR2xpOUxUXTQuZCsLOOM8C9ZxqH6+rmUBNqKmHSlmIuN6NGV+9yyOA X-Received: by 2002:a17:906:34d5:b0:6ef:af55:702 with SMTP id h21-20020a17090634d500b006efaf550702mr14663948ejb.430.1650478348000; Wed, 20 Apr 2022 11:12:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650478347; cv=none; d=google.com; s=arc-20160816; b=h3cLCHFc43xO9Q33OeVT+BN2HhB63AXbFVeSc10+jEpsQWJ6BdWoDj21pKcDVBs4If 2U20+fBz1h4bzQPhj54pTcRFs6DKMOAEMMZZ2w2vC3pt4c0oKX9Kv3wj7dY9xF6GmpRZ s/HKXDjL9fd9tFZYTlxHo1FCJXlCJQyQN4qrCTELPMl3B/eI1kLkGAPX7VA9FXHFYMrb WPRhoxsruU7OmX7o4VCyoHtF8gUNE32sCqBoUp2FiTljzl6CGQo/FI2rYK8JTMmNE3/I IBe9cIf+1lnprypzcMSG6Ki83IgyraTF9/TFF0Ss54+45jluFhziSxfT8v7VcMaYHnvW 1e5w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=YPzpNFwfMxcQ3d+BB5WrKajsMYmCUuQAh/UeGoRBLqQ=; b=fmFk27LxNO7vgzgnunFO8DWKR6rGhiNtqfzFmXBCFTN+xLurqrszj0QfqYZeF9h6sK NHH0n9eOWIFnvnFgEPDW1EfoU3JnDK6TZKfa3y7brWl0u0deDzMNbCViPy9lQog4/juq y89gJAWw0KG06296qibTAyNX0gcKIqpdNSlCZIYIoBXn0nMTXhGB9tL8hl16xDp7zbbT WE7a9fWpchYeqdCXe2oiAosQUjlag9UYOAc6qEzT9OSRR1Tqj2CfdcJ7KW/acovEhKGn BafhKi5F+ccb+fuIQvzJxhMwLGgVSO6Wp9JYls4eQI9QRk2JQXkW/GazOtcUrMo3bRZt 7Cgw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=MD0Db92t; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w22-20020a50d796000000b0042126899d90si2313264edi.128.2022.04.20.11.12.01; Wed, 20 Apr 2022 11:12:27 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=MD0Db92t; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1350762AbiDTHAR (ORCPT + 99 others); Wed, 20 Apr 2022 03:00:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48526 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1350625AbiDTHAP (ORCPT ); Wed, 20 Apr 2022 03:00:15 -0400 Received: from desiato.infradead.org (desiato.infradead.org [IPv6:2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 48B433526F for ; Tue, 19 Apr 2022 23:57:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=YPzpNFwfMxcQ3d+BB5WrKajsMYmCUuQAh/UeGoRBLqQ=; b=MD0Db92tQu7MRh3cWD6F+yor1S 5hC9Oidrll7q5JVVnscNaZrh7kaeLkAX6RB2hpz+QyfoCKjGbiUFfYLf8WouXQowbe34PWH6Zfm64 /rDlt6fSJKBtVc3xmVdWPBRVPGVpnvQd+ysLw3oAZSzy1ZwZgTGgjdTxwaz3M3W3+ZwlE+zjqt8UU 3B/J+zsghV3TF2f/vb1+Pdcl/MDmRLd+qpRtr23tdue1khcvQRa7vsVpwurXoi/eHEqkRECJRCBjN x7p22J56IPdw0jYK45aRyFr/Ig+FkzQBMg86k5v70UjSdrPtMXkVfCEzKFB9C/HwbfaBdylBKBlUf nDJa83VA==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=worktop.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nh4HC-0072p3-Mx; Wed, 20 Apr 2022 06:57:23 +0000 Received: by worktop.programming.kicks-ass.net (Postfix, from userid 1000) id 98F219861A4; Wed, 20 Apr 2022 08:57:20 +0200 (CEST) Date: Wed, 20 Apr 2022 08:57:20 +0200 From: Peter Zijlstra To: Josh Poimboeuf Cc: x86@kernel.org, linux-kernel@vger.kernel.org, mbenes@suse.cz Subject: Re: [PATCH 2/2] objtool: Fix code relocs vs weak symbols Message-ID: <20220420065720.GA2731@worktop.programming.kicks-ass.net> References: <20220419203254.034493341@infradead.org> <20220419203807.655552918@infradead.org> <20220420021601.kiughdji3avh2uua@treble> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220420021601.kiughdji3avh2uua@treble> X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE,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 lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Apr 19, 2022 at 07:16:01PM -0700, Josh Poimboeuf wrote: > On Tue, Apr 19, 2022 at 10:32:56PM +0200, Peter Zijlstra wrote: > > + /* XXX create ? */ > > + if (symtab_shndx) { > > Not sure what this comment means? I'm not sure if we will trip the case where the input ELF will not have/need the extended table, but our output file would need it. That said, upon thinking about it this morning, it wouldn't be this code path triggering it I think. Specifically, we only create section symbols for text sections and objtool doesn't generate text sections (you've talked me out of that). So the number of text sections doesn't change, so section index number shouldn't increase due to all this.