Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp3929888pxb; Tue, 10 Nov 2020 03:56:48 -0800 (PST) X-Google-Smtp-Source: ABdhPJzBlkejxnmUjAnB/huYytTVYE9yk5cJXZJ+iQCV0h57ANmmIbAdcQf9Otr/3axDRNpGowoa X-Received: by 2002:a17:906:81da:: with SMTP id e26mr19105385ejx.491.1605009408418; Tue, 10 Nov 2020 03:56:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605009408; cv=none; d=google.com; s=arc-20160816; b=Cd9BTeF3d0MssKIV52xOI3rX4t0ULdUUcRq3+vxusoQntb9RtKFTHlkN9S5eePa215 85wd15A0+wbSWKefVKGG17Vt1ag8rHj2AYwF5yX7EEz7VUuSnkPEQt4gwAp2CUxVG+8h 3oYmNPOuWz8u0ru/HT7L4wmXlOQR5ka4DraGVxTExgsaMrdN0CyCgPe2EEjGwTTx7Qzu zBx8lm7wgM2yhFx3nkR/yfrHZWS/Geat3QkT0kRTp75DbL7+W1tobULp3P/NvA6ugRVB mGSNJS295a8GqxcPicosSYt+klt0CLJzJAZ+0ywRWHJaytVkNoCtO3CIeJjYmlQZWjiY sRRA== 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=h1zSkrduEyJzM0lRmqcENuSEoWGmJgxX5fZOoCcajcM=; b=ZIc8nhUJRrQBE2YNgBvsyekam+2LQvgQ9eevPnOVD88356oWo35bM1OQRZP82jhhok hCCAtgnuaWVhere/Rp3hhYev3zUS76rwC2aN8G597f1SP0JFBOjsuCtbbFEwESVSdwyJ wXzjlQ7tdYE/PYf92ihd7pnpioA+a8JXrVELm0ANckd0b8bE5XLKrLy/5CbV9B5R/zTB JLsTM3h4WlzaHxa/clcuEhUGZjR6RoxRUFa/Yl/Fe/F9Ik/bD5v2pldF5z/UzgTRsK7r /RNVuEBoUV3e3lLgIOZdo+w3cLXVE7bUFIJrIhtj960IKFMz1x/jJHePPKPHnWho97Ca xz5A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=jadnfzZo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.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 vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id oz31si8494722ejb.484.2020.11.10.03.56.23; Tue, 10 Nov 2020 03:56:48 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=jadnfzZo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.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: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730117AbgKJLya (ORCPT + 99 others); Tue, 10 Nov 2020 06:54:30 -0500 Received: from mail.kernel.org ([198.145.29.99]:57582 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730074AbgKJLy3 (ORCPT ); Tue, 10 Nov 2020 06:54:29 -0500 Received: from quaco.ghostprotocols.net (unknown [179.97.37.151]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id DC02420678; Tue, 10 Nov 2020 11:54:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605009269; bh=PvWS/x4ZnDgyuuUmQLOqDDxuJUYgOngYLMICgwkSUcM=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=jadnfzZo0tvmOLgLumDyXVtT1VpgWQRklw22VzA/a44rWNmZ3cxrcD+NBpH9W/P5b OSsH3cd+oeZWq6IXyRxwSOZVUbwkOTKAP5ACRrSFd4rsHL6lUOprh6LMUcZ6+43B9L RqHAoo4LDtbnNJ1cZNFBP5Pp+TF/2ylR4ckFSXYA= Received: by quaco.ghostprotocols.net (Postfix, from userid 1000) id 96401411D1; Tue, 10 Nov 2020 08:54:26 -0300 (-03) Date: Tue, 10 Nov 2020 08:54:26 -0300 From: Arnaldo Carvalho de Melo To: Peter Zijlstra Cc: Jiri Olsa , lkml , Ingo Molnar , Mark Rutland , Namhyung Kim , Alexander Shishkin , Michael Petlan , Song Liu , Ian Rogers , Stephane Eranian , Alexey Budankov , Andi Kleen , Adrian Hunter Subject: Re: [PATCH 03/24] perf: Add build id data in mmap2 event Message-ID: <20201110115426.GA348806@kernel.org> References: <20201109215415.400153-1-jolsa@kernel.org> <20201109215415.400153-4-jolsa@kernel.org> <20201110080716.GU2594@hirez.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201110080716.GU2594@hirez.programming.kicks-ass.net> X-Url: http://acmel.wordpress.com Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Em Tue, Nov 10, 2020 at 09:07:16AM +0100, Peter Zijlstra escreveu: > On Mon, Nov 09, 2020 at 10:53:54PM +0100, Jiri Olsa wrote: > > Adding support to carry build id data in mmap2 event. > > > > The build id data replaces maj/min/ino/ino_generation > > fields, whichc are also used to identify map's binary, > > so it's ok to replace them with build id data: > > > > union { > > struct { > > u32 maj; > > u32 min; > > u64 ino; > > u64 ino_generation; > > }; > > struct { > > u8 build_id[20]; > > u8 build_id_size; > > What's the purpose of a size field for a fixed size array? Also, I'd > flip the order of these fields, first have the size and then the array. There can be different types of build-ids, with different sizes, flipping the order of the fields is indeed sensible, as we could then support even larger build_ids if the need arises :) - Arnaldo > > u8 __reserved_1; > > u16 __reserved_2; > > }; > > }; > > > > Replaced maj/min/ino/ino_generation fields give us size > > of 24 bytes. We use 20 bytes for build id data, 1 byte > > for size and rest is unused. -- - Arnaldo