Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp707443iob; Wed, 18 May 2022 11:05:46 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwrAfjpipg8/ke1xTaBetsk1tdVFAhMIOZbpl8Toj7IXsokbEB6z4zf9QT8XfbVLcPqSI77 X-Received: by 2002:a17:90a:e7cd:b0:1dc:74eb:7526 with SMTP id kb13-20020a17090ae7cd00b001dc74eb7526mr669043pjb.144.1652897146388; Wed, 18 May 2022 11:05:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652897146; cv=none; d=google.com; s=arc-20160816; b=p6YQ92T/mz1LK0QwJsKwW6tDuXtx7x0R4stOuQDWCbH9QL8nItKYx7DeL5Eu3eJH7A PsVC4Sguq6Nw2ID12SHaZcz9OWAInvcv5FzoUG5gBpvAHoymVgUvnsAcbgyEPUY6iEOL EppMa3xezH74Mpp1qoyJAY55KqqpcXntSZlyNf/i7tsj/6Pm04bsi/UZYSYOOpmZ8JsM c1eq+kZlMX9r0FzR56VJWoBOpeV8IOe5G0/VXROfjrtQiR7qXfV2eKhvT9ZXXbVO+8Tg JpNGhlH4c45Yhf782EsyQgFtWdaxBfswK3J2h2XTAcgZn8C5QcKWY2RGI0KHrZGeR8Pl GWJw== 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=j4NYBIJ7hPaBQPWRUlhiZtptdk3k6Y0xddcRShIJCVg=; b=fWMHWPOwZkvHpYmhblEoLYxrJ3IKevNWCUb6GCeoC6+Ucgj7K28tOkaQDmtyKnKagF uejkrtRCdlKLcFWOZ4IbfrDKN01TEAajB437f7q99S5rIOBq+6KxOUSSWFLvjUQPtdht rx96FpB+crdk+mrvG61U7mYv2/ZjKjhiNhkizutxQbU0bH5IiN5SKDEfjR21+irkKJrF CCD7CkqwT2F70N1U4ZF7w+eW3RB4i3F87oMtHnmswzNRlbqQH6+3jE9YhY8LyuhtI93v oexyDvBEPVodHLU2LsdhoDoxLt71/T9VSJ1Xcfh4h4AI3Yc4yyB20w9t/99+eyi473lT tBlQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=aRY8v8BQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id q12-20020a170902f34c00b00158e93cfafesi2980070ple.132.2022.05.18.11.05.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 May 2022 11:05:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=aRY8v8BQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 56FF617B845; Wed, 18 May 2022 11:04:47 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231422AbiERSEh (ORCPT + 99 others); Wed, 18 May 2022 14:04:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60076 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230522AbiERSEd (ORCPT ); Wed, 18 May 2022 14:04:33 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C3F6617B845 for ; Wed, 18 May 2022 11:04:31 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 5DC38617AD for ; Wed, 18 May 2022 18:04:31 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 72E90C385A9; Wed, 18 May 2022 18:04:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1652897070; bh=WgouBQbqLvRYIiDEBmX7GonuTuvke3EKEAJwjoD1z7c=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=aRY8v8BQgQ+fFlpAlT6dhPVrxS3tazMgc3P2Fp+AAgph5Seun637xPoHQ+QRzYHMN /vsbi29VNxroevsGxuAsGAAHMqvwaWn5TbkJp/q4DQUsEgGkfC80fRcEmVUH0xDuzv L+EpVqMmuDZHx/ETDm0bnmnkCB4Nb5aI7oWRBjx1/rV5iH9IDNHrxESl0joId5Ku0g scWjKsFMnl/7HXKz3SFZY5nf5KOssClhlZoRuASqkjskkwH+yvfQYHcL90NDt7k1EI qLhm/is0IPL7mbI5OPLygxN81Co2w+10a/rd7lHeOOrugixcRZHeDgj2/GElPyDyXW /QNygaJxfI3Fw== Date: Wed, 18 May 2022 11:04:28 -0700 From: Josh Poimboeuf To: Peter Zijlstra Cc: Nathan Chancellor , Nick Desaulniers , llvm@lists.linux.dev, linux-kernel@vger.kernel.org, kasan-dev@googlegroups.com Subject: Re: objtool "no non-local symbols" error with tip of tree LLVM Message-ID: <20220518180428.6yxf6tcqvzdvtfxb@treble> References: <20220516214005.GQ76023@worktop.programming.kicks-ass.net> <20220518012429.4zqzarvwsraxivux@treble> <20220518161725.2bkzavre2bg4xu72@treble> <20220518172513.GH10117@worktop.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20220518172513.GH10117@worktop.programming.kicks-ass.net> X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 Wed, May 18, 2022 at 07:25:13PM +0200, Peter Zijlstra wrote: > So while writing the global symbol can always use the new data section, > writing the new symbol can need arbitrary iteration of the data blocks. > > Something somewhat similar is when there's no global symbols, then the > new symbol needs to go in the new data block instead of the old. > > So it all became a tangled mess and I ended up with the one generic > function that could do it all (which is both simpler and less code than > trying to deal with all the weird cases). Makes sense, and matches my post-bike-ride insights. Thanks :-) -- Josh