On 2025-06-06 12:42, Jan Hubicka wrote:
Hi,
also after fixing this issue my bootstrap failes with:
Permission error mapping pages.
Consider increasing /proc/sys/kernel/perf_event_mlock_kb,
or try again with a smaller value of -m/--mmap_pages.
(current value: 4294967295,0)
Permission error mapping pages.
Consider increasing /proc/sys/kernel/perf_event_mlock_kb,
or try again with a smaller value of -m/--mmap_pages.
(current value: 4294967295,0)
Permission error mapping pages.
Consider increasing /proc/sys/kernel/perf_event_mlock_kb,
or try again with a smaller value of -m/--mmap_pages.
(current value: 4294967295,0)
this happens on my setup when perf is run multiple times in parallel
and bootstrapping without -j256 indeed continues (but slowly).
Since perf record overwrites the previous perf data, I wonder if this
also implies that we lose the profile info due to race conditions?
There should be only one per obj directory?
One extra nit I noticed. We use
AUTO_PROFILE = gcc-auto-profile --all -c 10000000
I do not see a reason to also profile kernel (i.e. --all flag).
I thought it was to work around some issue but can't recall details. We
should try I suppose. Also really need to enable all languages. Autofdo
bootstrap has various strange workarounds that are likely obsolete.
Also the count should probably be a prime so we reduce chance getting
an interference with a loop?
On Intel with PEBS it's +1 anyways, so more prime like.
I wonder if we can rely on perf having resonable defaults these days.
We already do. What's missing is that the latest Intel cores have an
architectural lbr inserts events that is especially for this and real
hybrid CPU support.
For some CPUs we measure cycles in other cases taken branches.
Cycles is always a bad idea, you really want branches.
taken branches 10000000 may be bit high?
It's rather low. Otherwise the files get really big. Really should use a
pipe to avoid the temporary files but the standard autofdo toolkit
insists on loading everything into memory.
Andi
Honza
Honza