Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp466799pxa; Fri, 31 Jul 2020 17:49:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzO4Zk627OG6K7V4Dm1+4874ItOJOol8bNGYE8tbxr/qjFFWkFq/kuerkD6N+crrL9lCX5i X-Received: by 2002:a50:fb08:: with SMTP id d8mr6213071edq.79.1596242948149; Fri, 31 Jul 2020 17:49:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596242948; cv=none; d=google.com; s=arc-20160816; b=vv3A6TKtFvIg5pFYa6dgBGtAq3+G8x61Pp1JC8NG60O1Zt2MBKRW3CO7zswebQ5Eol Q3VjFJcSLvnQYdeFYiHxOXF7SZ/oW/OWsTTK6m9wXWdukU+YiQhrlPRO0d1rq9KE52Vv RQ0tUtJQnL0HdHE7EIdvOuO7lVViUUm+caGvC9b19PewVuxFCoeZiSsEtpo2KmgeZXQB qhqsNIdDkO4lz7n1bCZBYHi4iHr1lGVcWONEYy3fUTvp/ZpeKyAJWdUbBGhNgTKuR28C dkzuj7Xu5O12HoFzKamSFPlq5AZEVuvrNo4KjyYpN3Q7tePtF/DdMRGjOjyPf221avpm n6GQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=lpyhrCH4eKTJSelS4BtxCH/z19fxo1jSDpO/4tVrznQ=; b=juhRESuGDvaGL5XMDiCDt/H2mavlsGHPmx4eMvVrP9vuYcU+37vTrmGxZr+e6tZPBo Jnfk/Gf7pc7h2p5+vzI9GbxgXPdYehCvW1xwB8AvXHkeksQuUGGAMsbIp3H4ISTIMnZr usCiBwdzIfCvqkf2XfJX8L1oqpvJVwmokezgvuEGDKc3OtjZryDiBDC4LYCIcR0uvzzb 3jTSVaVKiA4pwDQXuoPG90jdG5d5wUro3REp1XAvP04Js1/5b0NX/2+PrBg8vD7gOk1P tH6m9vtDpztyzoFdnrL1iHvVzErAf12m6DmMwhAC+mIxhpqyGNgyM2aqOp7c9sDncUax YGqA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=TgF2kEGa; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bw19si6070065ejb.729.2020.07.31.17.48.45; Fri, 31 Jul 2020 17:49:08 -0700 (PDT) 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=@gmail.com header.s=20161025 header.b=TgF2kEGa; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727819AbgHAAq1 (ORCPT + 99 others); Fri, 31 Jul 2020 20:46:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60778 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726099AbgHAAq0 (ORCPT ); Fri, 31 Jul 2020 20:46:26 -0400 Received: from mail-qt1-x841.google.com (mail-qt1-x841.google.com [IPv6:2607:f8b0:4864:20::841]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8F185C06174A for ; Fri, 31 Jul 2020 17:46:26 -0700 (PDT) Received: by mail-qt1-x841.google.com with SMTP id s23so24381179qtq.12 for ; Fri, 31 Jul 2020 17:46:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=lpyhrCH4eKTJSelS4BtxCH/z19fxo1jSDpO/4tVrznQ=; b=TgF2kEGa6o9qpnnYlPeNuDYCLWN5/02F+nADdR3bQKNzQMXPLx5mDDJJT8TGy6GMwf nKKoIlZHKJ8loYbuU5NWqz5VbwrhDmrMjmjCGeKdfL/8WfkmbB3mmxjLPltBTP1CwK5O wePqmE78S4jrp8BOrpPyCZkz4Z6PK6nE7hhB63kE8pxrncittx0jG4S6cc2sg9v+TQ9Z 76K0+vdDR8v95Lww3aSVM4ri/eatSHuXAt179tCdZKLQthMQS/ZsDSPS42txv42nh9bX dCssrgtbMHio+2lB2iQD31oWjAnxvV7RHMuSuiym3IkvOPR9L2AiWDuNoFJnBGMRWWIT t0+A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=lpyhrCH4eKTJSelS4BtxCH/z19fxo1jSDpO/4tVrznQ=; b=qtJip8DTuE//u2U0le8uQz+tk4rNPTcxSj289iTtlPr0Lxm+DLfjzZ8wHMkl6IA3to uzBEJpNtTYbBlxIHeqpGwebsKS32FbjydsAj2emBfABLvMjWNAgsngk0mTUdoPaZTZ1p rEcbtvZlNGonY9AaS8Y8IGsM82kGRDq0cDzxcWbLKz1LcFenoliEDcA6KZKyKvaESEVh LyOPpl2Co47stgRW4GlJvg1NRY8inGFpKnTNW8ZnXZeqgT8u3XdYYauq5VjP05Q08IT7 hmqmprU+i2MwoKU9gvTXkosdTs42RGmYQTfx3I5USEPClDRNqqhLFKEWaBlDcesurebA OdCA== X-Gm-Message-State: AOAM532aPevW1MjR2qfW0S/dGIlAfCy8Gky3feSCxdbexLOqBSWvY7sN 3qXQsB/kpNPgbjBieRL3T1Y= X-Received: by 2002:ac8:774f:: with SMTP id g15mr6387982qtu.145.1596242785832; Fri, 31 Jul 2020 17:46:25 -0700 (PDT) Received: from ?IPv6:2601:284:8202:10b0:c147:b41e:be5e:8b7a? ([2601:284:8202:10b0:c147:b41e:be5e:8b7a]) by smtp.googlemail.com with ESMTPSA id j61sm10860360qtd.52.2020.07.31.17.46.22 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 31 Jul 2020 17:46:25 -0700 (PDT) Subject: Re: [PATCH 0/6] perf tools: Add wallclock time conversion support To: peterz@infradead.org, Andi Kleen Cc: Jiri Olsa , Jiri Olsa , Arnaldo Carvalho de Melo , lkml , Ingo Molnar , Namhyung Kim , Alexander Shishkin , Michael Petlan , Ian Rogers , =?UTF-8?Q?Genevi=c3=a8ve_Bastien?= , Wang Nan , Jeremie Galarneau References: <20200730213950.1503773-1-jolsa@kernel.org> <20200730221423.GH2638@hirez.programming.kicks-ass.net> <20200731074726.GA1485940@krava> <20200731153612.GC1299820@tassilo.jf.intel.com> <20200731180539.GA2674@hirez.programming.kicks-ass.net> From: David Ahern Message-ID: <27a4663d-bc71-5f52-5871-23d4061fe575@gmail.com> Date: Fri, 31 Jul 2020 18:46:21 -0600 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:68.0) Gecko/20100101 Thunderbird/68.11.0 MIME-Version: 1.0 In-Reply-To: <20200731180539.GA2674@hirez.programming.kicks-ass.net> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 7/31/20 12:05 PM, peterz@infradead.org wrote: > On Fri, Jul 31, 2020 at 08:36:12AM -0700, Andi Kleen wrote: >>> yep, we have a customer that needs to compare data from multiple servers >> >> It's also needed to correlate over different guests on the same machine. >> This is an important use case. > > Both these cases you want to sync up CLOCK_MONOTONIC, using walltime is > just utterly misguided. Every userspace component logs in walltime. You can say that is misguided, but that is the way it is. The missing piece is the ability to correlate kernel events to userspace logs. > > What happens if the servers have (per accident or otherwise) different > DST settings, or someone does a clock_setttime() for giggles. Yes, someone *could* change the time. Someone *could* start ntpd or other time server in the middle of a session. While technically such things can happen, that is not real life in most environments (e.g., Data center servers). ntpd (or other) is started at boot, and it is just the little misc adjustments that happen over time. We could add tracepoints and detect the changes and invalidate the reference time. We could add tracepoints to track the adjustments and update the reference time. In my experience over 9+ years using this tool (out of tree patches) that has never been the problem. > > All you really want is a clock that runs at the same rate but is not > subject to random jumps and user foibles. > All I want is to compare user logs to a kernel event via timestamps.