Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp1484609iog; Thu, 16 Jun 2022 07:19:24 -0700 (PDT) X-Google-Smtp-Source: AGRyM1uRNLxAJmsG0dTArI+jYCx3CwgD2APbOP3WaJTJCPfs5G+jvrg0VlatYJvDtwJkjEmz4wxd X-Received: by 2002:a17:907:62a1:b0:6da:7952:d4d2 with SMTP id nd33-20020a17090762a100b006da7952d4d2mr4733200ejc.260.1655389164049; Thu, 16 Jun 2022 07:19:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655389164; cv=none; d=google.com; s=arc-20160816; b=PwCsWJzqUS68UvTNzYUXDUyPPhqqp6Bv/cHrTLf0mSZhLwZWwDhHLUalbNoRgR7LKB /GD6TuX0MY85MKAJLj4vGCRpajbRJVtLnFGXwwC1+CBq+GdmcrUIpvFgzggwtXAsaa4M lXUztVslKas9TMTCL22+YiCmULQTNnWZrT8SRtGHBjECJmzJkiVieAPwISf+ZdmXc3m1 j6F5d6J6+BKCavkulTXQozOXfpi/5L2DR5lmrwclNlvTXDHlbgMKWqatVekZ4DJ/v6hD YlzPNz4jARXFe4wsCt00Q5QXC/q0aqBUVvHYKMRgzKGHrbxCkZ0WwiBhukNAL06zajKh tu5Q== 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=C8HUoWbkEZfFi5Ww+b/aIrWTUO0EXGNVkEGEo9LVJjo=; b=nAPM7gj2VqxGv39C+l48jrPW3XUXuuQdJbs+QLo349+qlwX2nbwxea/rw7ANNAqL3Q syMqBKkBeEAdHBnrRu87UVlF1e/SN3H502LwIPzPzuxevDQcJAznQ9UzX1kRzJa94w0O VvJoDgatHwEJRhXhIqK+VIZOef6xbLhEs7uVNMmyWJ7p4A62wnLd9RjIF1AUYXVZOsb9 LlnmCyTSO2McPh7TBA9iPz+aRbTF8OFHYgMTy74eaTjOatEyjqszTk2aO+5KhPIPi06y edyC3qMqfcjs4xWkIs9t+TSyy063RB1QEVsEsmgmomy8EIx6sA5QYivWH5Pj0wY6kSj4 0oTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=nGXEooab; 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 g20-20020aa7c594000000b0042d5ad04360si856685edq.498.2022.06.16.07.18.57; Thu, 16 Jun 2022 07:19:24 -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=nGXEooab; 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 S1377439AbiFPN7N (ORCPT + 99 others); Thu, 16 Jun 2022 09:59:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36050 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377453AbiFPN6X (ORCPT ); Thu, 16 Jun 2022 09:58:23 -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 A45062F657 for ; Thu, 16 Jun 2022 06:58:21 -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=C8HUoWbkEZfFi5Ww+b/aIrWTUO0EXGNVkEGEo9LVJjo=; b=nGXEooabTbb0KLw5oHlgpsPeqx fPen/6rTxyKZGwJnQ0odoQUTMevOda2oR5cGjcV/WHjZ2cU/vnLk0Pu4ebiiZ0/Ypknuk2hdNVhNt igkit05wkwuyzfIBeeldUwXMzhFeoXk+gvHB8+U8bRfoct1HrVD6NsZXWHypy2pT3ShcPi2rKvDFP +xaiMXmZLXwOGyuqCH41y1mL7M+6bqy79sCWKcEXWtd04gnqfqu5QiXy2TV2w/F/6yAmVzvJXqml1 SMjsMCswQo9c2WHhlfjZwM3EC8d0zQ7scoomQ8TU2hFZPpJuXXrmbLvLsEbbV9kmJKzs2Ghnekx2X zR+c3IGA==; Received: from dhcp-077-249-017-003.chello.nl ([77.249.17.3] helo=noisy.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1o1q0R-008QMy-3Z; Thu, 16 Jun 2022 13:57:55 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id C474F300372; Thu, 16 Jun 2022 15:57:51 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id B17BF2029FD42; Thu, 16 Jun 2022 15:57:51 +0200 (CEST) Date: Thu, 16 Jun 2022 15:57:51 +0200 From: Peter Zijlstra To: Christophe Leroy Cc: "Naveen N. Rao" , Sathvika Vasireddy , "aik@ozlabs.ru" , Chen Zhongjin , "jpoimboe@redhat.com" , "linux-kernel@vger.kernel.org" , "linuxppc-dev@lists.ozlabs.org" , "mbenes@suse.cz" , "rostedt@goodmis.org" , Sathvika Vasireddy Subject: Re: [RFC PATCH 4/4] objtool/powerpc: Add --mcount specific implementation Message-ID: References: <20220523175548.922671-1-sv@linux.ibm.com> <20220523175548.922671-5-sv@linux.ibm.com> <6be5c941-07b0-64d5-7f36-fe5770fb5244@csgroup.eu> <59170f18-1356-1140-70e3-30cb627f00bc@linux.vnet.ibm.com> <578ec055-0d63-e579-0caa-ad57846b8995@csgroup.eu> <1655386289.uh0k7sgl1r.naveen@linux.ibm.com> <30f3791c-0fdd-e635-4a85-ec457f990fae@csgroup.eu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <30f3791c-0fdd-e635-4a85-ec457f990fae@csgroup.eu> 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 Thu, Jun 16, 2022 at 01:40:34PM +0000, Christophe Leroy wrote: > sizeof(u64) is always 8 by definition. > > So if size is 8 we are working on a binary file for a 64 bits target, if > not it means we are working for a 32 bits target. Cross-builds invalidate this I think. Best to look at something like: elf->ehdr.e_ident[EI_CLASS] == ELFCLASS32