Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 29 Jan 2019 19:34:32 -0500
From:      Mark Johnston <markj@freebsd.org>
To:        Marko Zec <zec@fer.hr>
Cc:        src-committers@freebsd.org, svn-src-all@freebsd.org
Subject:   Re: svn commit: r343527 - in stable/12/sys/riscv: include riscv
Message-ID:  <20190130003432.GA2617@spy>
In-Reply-To: <20190129192627.51acc721@x23>
References:  <201901281614.x0SGErMq078921@repo.freebsd.org> <20190129192627.51acc721@x23>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Jan 29, 2019 at 07:26:27PM +0100, Marko Zec wrote:
> On Mon, 28 Jan 2019 16:14:53 +0000
> Mark Johnston <markj@freebsd.org> wrote:
> 
> > Author: markj
> > Date: Mon Jan 28 16:14:53 2019
> > New Revision: 343527
> > URL: https://svnweb.freebsd.org/changeset/base/343527
> > 
> > Log:
> >   MFC r343274, r343275:
> >   Optimize RISC-V copyin(9)/copyout(9) routines.
> 
> Was this subjected to any benchmarks?  I'd bet that placing

I only did some ad-hoc testing under QEMU with a few copyout()-intensive
programs (a few procstat(1) invocations).  In general I saw a roughly 5%
decrease in runtimes.  I don't yet have any hardware to test on, and I
don't believe Mitchell (the submitter of the patch) does either.

> addi	a2, a2, -XLEN_BYTES
> 
> before
> 
> sd	a4, 0(a1)
> 
> instead of being scheduled after (the same goes for the byte copy loop)
> would make the loops run faster on most in-order RV cores out there...

That makes sense.  I doubt it would make a difference under QEMU though.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20190130003432.GA2617>