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] [thread-next>] [day] [month] [year] [list]
Message-ID: <aQI_6vZUbjhnl4ZJ@x1>
Date: Wed, 29 Oct 2025 13:25:14 -0300
From: Arnaldo Carvalho de Melo <acme@...nel.org>
To: Ian Rogers <irogers@...gle.com>
Cc: Suzuki K Poulose <suzuki.poulose@....com>,
	Mike Leach <mike.leach@...aro.org>,
	James Clark <james.clark@...aro.org>,
	John Garry <john.g.garry@...cle.com>, Will Deacon <will@...nel.org>,
	Leo Yan <leo.yan@...ux.dev>, Peter Zijlstra <peterz@...radead.org>,
	Ingo Molnar <mingo@...hat.com>, Namhyung Kim <namhyung@...nel.org>,
	Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
	Jiri Olsa <jolsa@...nel.org>,
	Adrian Hunter <adrian.hunter@...el.com>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Charlie Jenkins <charlie@...osinc.com>,
	Thomas Falcon <thomas.falcon@...el.com>,
	Yicong Yang <yangyicong@...ilicon.com>,
	Thomas Richter <tmricht@...ux.ibm.com>,
	Athira Rajeev <atrajeev@...ux.ibm.com>,
	Howard Chu <howardchu95@...il.com>, Song Liu <song@...nel.org>,
	Dapeng Mi <dapeng1.mi@...ux.intel.com>,
	Levi Yun <yeoreum.yun@....com>,
	Zhongqiu Han <quic_zhonhan@...cinc.com>,
	Blake Jones <blakejones@...gle.com>,
	Anubhav Shelat <ashelat@...hat.com>,
	Chun-Tse Shao <ctshao@...gle.com>,
	Christophe Leroy <christophe.leroy@...roup.eu>,
	Jean-Philippe Romain <jean-philippe.romain@...s.st.com>,
	Gautam Menghani <gautam@...ux.ibm.com>,
	Dmitry Vyukov <dvyukov@...gle.com>,
	Yang Li <yang.lee@...ux.alibaba.com>, linux-kernel@...r.kernel.org,
	linux-perf-users@...r.kernel.org, Andi Kleen <ak@...ux.intel.com>,
	Weilin Wang <weilin.wang@...el.com>
Subject: Re: [RFC PATCH v1 12/15] perf evlist: Add reference count

On Wed, Oct 29, 2025 at 01:22:21PM -0300, Arnaldo Carvalho de Melo wrote:
> On Tue, Oct 28, 2025 at 10:34:10PM -0700, Ian Rogers wrote:
> > This a no-op for most of the perf tool. The reference count is set to
> > 1 at allocation, the put will see the 1, decrement it and perform the
> > delete. The purpose for adding the reference count is for the python
> > code. Prior to this change the python code would clone evlists, but
> > this has issues if events are opened, etc. This change adds a
> > reference count for the evlists and a later change will add it to
> > evsels. The combination is needed for the python code to operate
> > correctly (not hit asserts in the evsel clone), but the changes are
> > broken apart for the sake of smaller patches.
 
> Looks ok, noisy for all the s/delete/put/ but that is ok, but then you
> are not using the RC_CHK_ACCESS stuff from the get go, why not?
 
> All the prep patches looks ok, assuming they build in succession.

Also I tried to run the test case before the patches on a 9950x3d, AMD,
with ibs and couldn't, some perf.data format error, then on Intel I had
to hit control+c and got a deprecation warning, both, of course
completely unrelated to your work, so just FYI:

root@...e:~# perf mem record -a sleep 1
[ perf record: Woken up 1 times to write data ]
[ perf record: Captured and wrote 2.247 MB perf.data (12814 samples) ]
root@...e:~# time perf script mem-phys-addr
/home/acme/libexec/perf-core/scripts/python/mem-phys-addr.py:49: DeprecationWarning: 'maxsplit' is passed as positional argument
  m = re.split('-|:', line, 2)
^CWarning:
929 out of order events recorded.
Event: cpu_core/mem_inst_retired.all_loads/P
Memory type                                    count  percentage
----------------------------------------  ----------  ----------
100000000-8bfbfffff : System RAM              149050        87.4
  2ac600000-2ad75cfff : Kernel rodata           1567         0.9
  2ad800000-2adc6a47f : Kernel data              517         0.3
  2ae7e8000-2aedfffff : Kernel bss               282         0.2
  2ab000000-2ac54d27e : Kernel code               21         0.0
0-fff : Reserved                               18990        11.1
100000-30093fff : System RAM                    2566         1.5

real	11m46.282s
user	0m1.317s
sys	0m0.344s
root@...e:~# grep -m1 'model name' /proc/cpuinfo
model name	: Intel(R) Core(TM) i7-14700K
root@...e:~# cat /etc/redhat-release
Fedora release 42 (Adams)
root@...e:~# uname -a
Linux five 6.16.9-200.fc42.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Sep 25 18:05:50 UTC 2025 x86_64 GNU/Linux
root@...e:~#

- Arnaldo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ