Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp1311079ybg; Tue, 2 Jun 2020 06:50:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxdnnZDsBUAFKqMgCIi2cyo3FAapAP5lo+1NUSCFJNgoZnVHZ1sgjVGAi8TJRIHmL7TnLWF X-Received: by 2002:a17:906:d0d7:: with SMTP id bq23mr10026181ejb.259.1591105804444; Tue, 02 Jun 2020 06:50:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591105804; cv=none; d=google.com; s=arc-20160816; b=d72tywEHCXWUgyGzLxsXqyMSa6NCGYX9E9F3VUDeC/qGiuGKzH59ZqIl1Dl3Pp5gJ/ VJNpYou3H/FJ3ahWTdCgs1nO7f0CAlv4nvRfbpyK/R4F2Z3f9Fyx6UZCC5JWyeRUSqzy FS/UhIQQFVOo7MYzGl7Xiu7/ohE0icHQdmASy8MCk5CsKTKb81scE+2IHZv3Nu7ub4Wc frwZREUxgJ3iy/BZXGoAsucjtWxakYTn84zarLqfosW2MjVudrKVaJDkBPT9ckrewMQn ui/EcLnEqgxpmSccedx2UXBGTg6u3JK3oD5OyvL7PKOT477yChryel5M99k4dQ9a8KP0 Cw+w== 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:organization:from:references:cc:to:subject:ironport-sdr :ironport-sdr; bh=I1fBL/rn/OCyHKviMeTBZFz1EWUakMAvQaNKuxZ+Ycs=; b=e8hykZKG8AMuueBQA3ysEHy7QcfK21bKYOIkT5a/E5vuH5NLnKgydo9a3mnu9n8tOy +FXnbQZo91MUKDlSxVuB6768UO86TwzLYY+Ks871ivxM/H288qX1rLoASqB4NU7llTT7 TUhTYMVP7+YAt9dzQAIdxfcT1Z3/d9yHjQ9+nkaa67seWZ/EgBhVdzBvZ2scwg8qGprz rbUzYrbAbNsIXT0aJ4IMrRvEbyvF5npHut36yAxpxGQk9/wipAmoo45f3H8iv+5PoKkh ig1HTQcw1G7xssVm9W+svsTB1jPHo67JZoBVGfz6H3QrOauQCUq5I5SzyE7BlUdoWfd7 tofQ== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id op23si1356746ejb.354.2020.06.02.06.49.36; Tue, 02 Jun 2020 06:50:04 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727788AbgFBNoe (ORCPT + 99 others); Tue, 2 Jun 2020 09:44:34 -0400 Received: from mga11.intel.com ([192.55.52.93]:24956 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725940AbgFBNoe (ORCPT ); Tue, 2 Jun 2020 09:44:34 -0400 IronPort-SDR: W7vQptyI5pLIqXoMqjCflOS7OTXa0wSLH9Msvd91c+2uS8fEYscqW3LTEDmOvDIRHrKmccpskS L0urDQRnymZw== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Jun 2020 06:44:34 -0700 IronPort-SDR: 1hLlep6tcToeKjR8jx1vzpz2MQV4f9AqvBcce0HhaQb5ZJ77PNJgxxNEIep+8MOMP+XFnEb0xJ Ok8nJIQV+IcA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,464,1583222400"; d="scan'208";a="444697984" Received: from ahunter-desktop.fi.intel.com (HELO [10.237.72.157]) ([10.237.72.157]) by orsmga005.jf.intel.com with ESMTP; 02 Jun 2020 06:44:31 -0700 Subject: Re: [PATCH v5 13/13] perf record: introduce --ctl-fd[-ack] options To: Alexey Budankov , Andi Kleen Cc: Arnaldo Carvalho de Melo , Jiri Olsa , Namhyung Kim , Alexander Shishkin , Peter Zijlstra , Ingo Molnar , linux-kernel References: <8ffc9f9f-af58-deea-428b-f8a69004e3cb@linux.intel.com> <923c40c7-7c0b-9fad-314d-69e7acbee201@intel.com> <937c8cc1-b4c2-8531-3fa4-d0ad9df6a65f@linux.intel.com> <20200601233732.GA691017@tassilo.jf.intel.com> <1bc7c72b-9d78-5184-a27c-8025beadaaf0@linux.intel.com> From: Adrian Hunter Organization: Intel Finland Oy, Registered Address: PL 281, 00181 Helsinki, Business Identity Code: 0357606 - 4, Domiciled in Helsinki Message-ID: <935187e8-6fc8-5f47-b88d-6e8c92a27286@intel.com> Date: Tue, 2 Jun 2020 16:43:58 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 MIME-Version: 1.0 In-Reply-To: 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 2/06/20 12:12 pm, Alexey Budankov wrote: > > On 02.06.2020 11:32, Alexey Budankov wrote: >> >> On 02.06.2020 2:37, Andi Kleen wrote: >>>>> or a pathname, or including also the event default of "disabled". >>>> >>>> For my cases conversion of pathnames into open fds belongs to external >>>> controlling process e.g. like in the examples provided in the patch set. >>>> Not sure about "event default of 'disabled'" >>> >>> It would be nicer for manual use cases if perf supported the path names >>> directly like in Adrian's example, not needing a complex wrapper script. >> >> fds interface is required for VTune integration since VTune wants control >> over files creation aside of Perf tool process. The script demonstrates >> just one possible use case. >> >> Control files could easily be implemented on top of fds making open operations >> for paths and then initializing fds. Interface below is vague and with explicit >> options like below it could be more explicit: >> --ctl-file /tmp/my-perf.fifo --ctl-file-ack /tmp/my-perf-ack.fifo > > Or even clearer: > > --ctl-fifo /tmp/my-perf --ctl-fifo-ack /tmp/my-perf-ack If people are OK with having so many options, then that is fine by me. > >> >> Make either fds and or files provided on the command line. Implement file >> options handling callbacks that would open paths and setting fds. Close fds >> if they were opened by Perf tool process. >> >> Adrian, please share your mind and use case. >> >> ~Alexey >> >>> >>> -Andi >>>> >>>>> >>>>> e.g. add "--control" and support all of: >>>>> >>>>> --control >>>>> --control 11 >>>>> --control 11,15 >>>>> --control 11,15,disabled >>>>> --control 11,,disabled >>>>> --control /tmp/my-perf.fifo >>>>> --control /tmp/my-perf.fifo,/tmp/my-perf-ack.fifo >>>>> --control /tmp/my-perf.fifo,/tmp/my-perf-ack.fifo,disabled >>>>> --control /tmp/my-perf.fifo,,disabled >>>>> >>>>> Regards >>>>> Adrian >>>>> >>>> >>>> Regards, >>>> Alexey >>>>