Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1709822

Re: perf: multiple mmap of fd behavior on x86/ARM

From Mark Rutland <mark.rutland@arm.com>
Newsgroups linux.kernel
Subject Re: perf: multiple mmap of fd behavior on x86/ARM
Date 2017-08-11 18:30 +0200
Message-ID <udkYX-5NJ-41@gated-at.bofh.it> (permalink)
References <ud0GS-17N-15@gated-at.bofh.it> <udf3c-2bo-9@gated-at.bofh.it> <udk2S-5cA-21@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, Aug 11, 2017 at 11:25:37AM -0400, Vince Weaver wrote:
> On Fri, 11 Aug 2017, Mark Rutland wrote:
> 
> > IIUC by 'rdpmc' you mean direct userspace counter access?
> > 
> > Patches for that never made it upstream. Last I saw, there were no
> > patches in a suitable state for review.
> 
> yes, someone from Linaro sent me some code a while back that implemented 
> the userspace side and claimed the kernel patches would appear at some 
> point.  I should try to dig up that e-mail.

IIRC, patches were sent back in 2014, but as I mentioned above, those
were far from suitable for upstream, even ignoring cases like
big.LITTLE. Said patches were never reworked and reposted.

> > > On ARM/ARM64 you can only mmap() it once, any other attempts fail.
> > 
> > Interesting. Which platform(s) are you testing on, with which kernel
> > version(s)?
> 
> This is on a Dragonbaord 401c running a vendor 64-bit 4.4 kernel,
> a Nvidia Jetson TX-1 board running a 64-bit 3.10 vendor kernel,

Just to check, how does x86 behave on each of those kernel releases?

Many things have changed since v4.4.

> as well as a Raspberry Pi 3B running a 32-bit 4.9 pi foundation kernel.

Hmm. On 32-bit this might be down to some arch/arm/mm cache aliasing
code, or it might be down to something that's changed since v4.9.

> It's a pain getting a recent-git kernel on these boards but I'm most of 
> the way to getting one booting on the Pi 3B.  (got distracted by the fact 
> that Linpack still reliably crashes the Pi-3b even with a heatsink).

IIUC, were you to modify this test to use SW events, you could test it
on an aarch64 kernel running under QEMU. To the best of my knowledge,
the code paths for HW and SW PMU are identical for mmap.

Otherwise, you might have more luck using a foundation model, which has
a PMU. 

Thanks,
Mark.

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

perf: multiple mmap of fd behavior on x86/ARM Vince Weaver <vincent.weaver@maine.edu> - 2017-08-10 20:50 +0200
  Re: perf: multiple mmap of fd behavior on x86/ARM Mark Rutland <mark.rutland@arm.com> - 2017-08-11 12:10 +0200
    Re: perf: multiple mmap of fd behavior on x86/ARM Peter Zijlstra <peterz@infradead.org> - 2017-08-11 13:00 +0200
      Re: perf: multiple mmap of fd behavior on x86/ARM Mark Rutland <mark.rutland@arm.com> - 2017-08-11 13:10 +0200
        Re: perf: multiple mmap of fd behavior on x86/ARM Peter Zijlstra <peterz@infradead.org> - 2017-08-11 17:00 +0200
          Re: perf: multiple mmap of fd behavior on x86/ARM Will Deacon <will.deacon@arm.com> - 2017-08-14 13:00 +0200
    Re: perf: multiple mmap of fd behavior on x86/ARM Vince Weaver <vincent.weaver@maine.edu> - 2017-08-11 17:30 +0200
      Re: perf: multiple mmap of fd behavior on x86/ARM Mark Rutland <mark.rutland@arm.com> - 2017-08-11 18:30 +0200
        Re: perf: multiple mmap of fd behavior on x86/ARM Vince Weaver <vincent.weaver@maine.edu> - 2017-08-11 19:00 +0200
          Re: perf: multiple mmap of fd behavior on x86/ARM Mark Rutland <mark.rutland@arm.com> - 2017-08-11 19:20 +0200
            Re: perf: multiple mmap of fd behavior on x86/ARM Vince Weaver <vincent.weaver@maine.edu> - 2017-08-11 21:10 +0200

csiph-web