lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Fri, 15 Jan 2021 17:34:59 +0300
From:   Alexander Antonov <alexander.antonov@...ux.intel.com>
To:     Namhyung Kim <namhyung@...nel.org>
Cc:     Arnaldo Carvalho de Melo <acme@...nel.org>,
        linux-kernel <linux-kernel@...r.kernel.org>,
        Jiri Olsa <jolsa@...hat.com>, Andi Kleen <ak@...ux.intel.com>,
        Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
        Mark Rutland <mark.rutland@....com>,
        Ian Rogers <irogers@...gle.com>,
        Ingo Molnar <mingo@...hat.com>,
        Peter Zijlstra <peterz@...radead.org>
Subject: Re: [PATCH v2 5/6] perf stat: Enable iiostat mode for x86 platforms


On 1/15/2021 10:33 AM, Namhyung Kim wrote:
> On Fri, Jan 15, 2021 at 1:41 AM Alexander Antonov
> <alexander.antonov@...ux.intel.com> wrote:
>> On 1/14/2021 6:39 AM, Namhyung Kim wrote:
>>> On Wed, Jan 13, 2021 at 9:08 PM Alexander Antonov
>>> <alexander.antonov@...ux.intel.com> wrote:
>>>> On 1/6/2021 12:02 PM, Namhyung Kim wrote:
>>>>> On Wed, Dec 23, 2020 at 10:03 PM Alexander Antonov
>>>>>> diff --git a/tools/perf/perf-iiostat.sh b/tools/perf/perf-iiostat.sh
>>>>>> new file mode 100644
>>>>>> index 000000000000..2c5168d2550b
>>>>>> --- /dev/null
>>>>>> +++ b/tools/perf/perf-iiostat.sh
>>>>>> @@ -0,0 +1,12 @@
>>>>>> +#!/bin/bash
>>>>>> +# SPDX-License-Identifier: GPL-2.0
>>>>>> +# perf iiostat
>>>>>> +# Alexander Antonov <alexander.antonov@...ux.intel.com>
>>>>>> +
>>>>>> +if [[ "$1" == "show" ]] || [[ "$1" =~ ([a-f0-9A-F]{1,}):([a-f0-9A-F]{1,2})(,)? ]]; then
>>>>>> +        DELIMITER="="
>>>>>> +else
>>>>>> +        DELIMITER=" "
>>>>>> +fi
>>>>>> +
>>>>>> +perf stat --iiostat$DELIMITER$*
>>>>> Why is this needed?
>>>>>
>>>>> Thanks,
>>>>> Namhyung
>>>> Arnaldo raised question relates to format of 'perf stat --iiostat'
>>>> subcommand
>>>> and explained how it can be changed to 'perf iiostat' through the aliases
>>>> mechanism in perf.
>>> Yeah, I know that.  What I'm asking is the DELIMITER part.
>>>
>>> Thanks,
>>> Namhyung
>> I'm using DELIMITER to resolve two different cases for format of iiostat
>> command:
>> The first one is the command with an option for iiostat mode, for example:
>> 'perf iiostat show' which should be converted to 'perf stat
>> --iiostat=show' or
>> 'perf iiostat 0000:ae,0000:5d' to 'perf stat --iiostat=0000:ae,0000:5d'.
>> The second is the command without any option for iiostat: 'perf iiostat
>> -I 1000'
>> should be converted to 'perf stat --iiostat -I 1000'.
> Can't we simply use a whitespace ?
We need to use the equal sign to pass arguments to iiostat mode.

Thanks,
Alexander

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ