Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 6 Sep 2013 00:37:33 +0200
From:      Zbigniew Bodek <zbb@semihalf.com>
To:        Jia-Shiun Li <jiashiun@gmail.com>
Cc:        "freebsd-arm@freebsd.org" <freebsd-arm@freebsd.org>
Subject:   Re: stream benchmarking on RPi
Message-ID:  <CAG7dG%2Bxn9yCCPn30SXWnC6ppYkoWCjTKhBtgwcH-s46wHAdCJA@mail.gmail.com>
In-Reply-To: <CAHNYxxNtBcjD_Khq1_pYCMdPwZJmQ0M_GTmcaGWtoLOJkz_86g@mail.gmail.com>
References:  <CAHNYxxNtBcjD_Khq1_pYCMdPwZJmQ0M_GTmcaGWtoLOJkz_86g@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
2013/9/5 Jia-Shiun Li <jiashiun@gmail.com>

> Hi all,
>
> just did a brief test using stream, the memory bandwidth benchmark, on
> RPi with Raspbian and FreeBSD. Share these info to see if someone
> might think of it useful.
>
> FreeBSD is faster at copying. I guess that must be attributed to
> recent VM and/or superpage commits. I remembered it to be under
> 300MB/s months before. On the other hand, scale, add, and triad are
> significantly slower. Anyone have clues or any wild guesses?
>
>
> Below the only compiler option given for cc/gcc is -O3.
>
> Raspbian 2013-07-26 (lk 3.6, gcc 4.6):
> -------------------------------------------------------------
> Function    Best Rate MB/s  Avg time     Min time     Max time
> Copy:             257.3     0.062703     0.062189     0.063824
> Scale:            205.1     0.079135     0.077993     0.082000
> Add:              284.1     0.085253     0.084480     0.088597
> Triad:            274.3     0.087799     0.087501     0.087940
> -------------------------------------------------------------
>
> FreeBSD 10.0-CURRENT r255120 w/ cc(clang):
> -------------------------------------------------------------
> Function    Best Rate MB/s  Avg time     Min time     Max time
> Copy:             365.5     0.045321     0.043779     0.052929
> Scale:             31.2     0.531028     0.513082     0.550906
> Add:               68.5     0.367295     0.350467     0.391310
> Triad:             26.9     0.902672     0.893316     0.908908
> -------------------------------------------------------------
>
> FreeBSD 10.0-CURRENT r255120 w/ gcc (4.2.1):
> -------------------------------------------------------------
> Function    Best Rate MB/s  Avg time     Min time     Max time
> Copy:             264.6     0.063977     0.060470     0.081000
> Scale:             31.0     0.535830     0.516093     0.551035
> Add:               46.7     0.534768     0.514323     0.553834
> Triad:             23.1     1.047644     1.038968     1.066887
> -------------------------------------------------------------
>
>
Hello  Jia-Shiun.

Thanks for your effort in testing.
I am actually in the middle of superpages tests and another benchmark and
set of
results will be very helpful especially for comparison.

Just for the record: did you enable superpages for your kernel?
SP are not yet enabled by default, therefore one needs to set
vm.pmap.sp_enabled to non-zero value in loader.conf (if you are using
loader)
or set this value in src by editing sys/arm/arm/pmap-v6.c -> sp_enabled.

Nevertheless I've made short tests on Armada XP (clang).
I used two array sizes (default and 2 x default). I also made few runs to
ensure
that the results are steady.
Please check below (improvement in copy can be seen but from what one can
observe via sysctl vm.pmap.section not so many superpages are "requested"
during the test):

Array size = 10000000 (elements)
================================
sp disabled
-------------------------------------------------------------
Function    Best Rate MB/s  Avg time     Min time     Max time
Copy:            1311.9     0.124910     0.121956     0.126486
Scale:             64.2     2.546568     2.493977     2.570808
Add:              112.1     2.163666     2.140962     2.205463
Triad:             51.3     4.683770     4.675176     4.689565

sp enabled
-------------------------------------------------------------
Function    Best Rate MB/s  Avg time     Min time     Max time
Copy:            1368.9     0.119831     0.116878     0.121894
Scale:             64.6     2.527607     2.476270     2.551667
Add:              112.9     2.147966     2.125261     2.189840
Triad:             51.6     4.654865     4.647609     4.662289


Array size = 20000000 (elements)
================================
sp disabled
-------------------------------------------------------------
Function    Best Rate MB/s  Avg time     Min time     Max time
Copy:            1271.2     0.257928     0.251738     0.260991
Scale:             64.2     5.092455     4.987830     5.139630
Add:              112.0     4.331419     4.287459     4.416701
Triad:             51.3     9.366274     9.349165     9.379344

sp enabled
-------------------------------------------------------------
Function    Best Rate MB/s  Avg time     Min time     Max time
Copy:            1333.3     0.250755     0.240014     0.253216
Scale:             64.5     5.065569     4.963166     5.114160
Add:              112.4     4.312079     4.268610     4.395812
Triad:             51.6     9.325673     9.309094     9.338787

Best regards
Zbigniew Bodek



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAG7dG%2Bxn9yCCPn30SXWnC6ppYkoWCjTKhBtgwcH-s46wHAdCJA>