ユーザランドからのUARTの高速化について

 メモ書きです。


 ユーザランドから/proc/ttySxなどのシリアル(UART等)通信においてread/writeを早める方法について


 デバイスは200Hz程度での動作保証なのに、linuxユーザランドから/dev/ttyS0で高頻度でreadするベンチを作ってみたら、
毎秒50Hz程度しか呼べなかったので高速化してみた。

P.S
ドライバで割り込みなど用いればスマートに解決するかもしれませんがw−。

スループットを上げる

 UARTで通信のデータ量が欲しくて、デバイス間で対応しているbundrateを挙げれるならbundrateを上げれる


 ただbundrateを上げると通信経路(接続しているワイヤー)などがシビアになって通信できなくなる可能性もあります。
ご利用は計画的にw−

今回は通信データ量が少ないので、bundrateを変更しても変化しなかったです。

レスポンス応答を早める

 こちはらデータ量は少ないが、毎秒の呼び出し回数を多くしたい(100Hz-1000Hz)場合に有用です*1


方法としてはカーネルの再ビルドが必要ですが、CONFIG_HZが100/250Hzなどだった場合に、1000Hzに上げてカーネルを置き換える

CONFIG_HZ=1000に変更して、毎秒200Hz以上に改善しました。よかったよかったw<

P.S.
 kernelのタイマ割り込み頻度を上げるので、もちろんいろいろ影響する可能性はあります。
すぐさま影響しそうなのは消費電力とか上がりそう。

UARTのみでなく、他の通信(I2C/SPI等)も改善する可能性があります。

  1. 参考
    1. "RasberryPi / Fourms / Change kernel frequency CONFIG_HZ"
    2. http://d.hatena.ne.jp/embedded/20151024/p2

*1:今回のケースですねw−

ltpにcveテストが追加されてた

 rasberry pi2/rasbian(nano pi neo 2/armbianは完走しなかったw−。)の負荷テスト代わりに、
linux test projectのtag20170929を流してたらなんかcveテストっぽいログ発見w−

$ dmesg
...
[35069.867684] input: virtual-device-ltp as /devices/virtual/input/input4
[35070.007192] LTP: starting input06
[35070.037723] input: virtual-device-ltp as /devices/virtual/input/input5
[35070.788106] LTP: starting cve-2011-0999 (thp01 -I 120)
[35190.847369] LTP: starting cve-2011-2183 (ksm05 -I 10)
[35190.879863] LTP: starting cve-2011-2496 (vma03)
[35190.910846] LTP: starting cve-2012-0957
[35190.941755] LTP: starting cve-2014-0196
[35389.414391] LTP: starting cve-2015-0235 (gethostbyname_r01)
[35389.444495] LTP: starting cve-2015-7550 (keyctl02)
[35393.831873] LTP: starting cve-2016-4470 (keyctl01.sh)
[35394.306935] LTP: starting cve-2016-4997
[35394.339884] LTP: starting cve-2016-5195 (dirtyc0w)
[35395.416041] LTP: starting cve-2016-7042
[35395.446908] LTP: starting cve-2016-7117
[35508.867774] LTP: starting cve-2016-9604 (keyctl08)
[35508.900499] LTP: starting cve-2016-10044
[35509.044379] LTP: starting cve-2017-2618
[35509.074631] LTP: starting cve-2017-2671
[35514.212736] LTP: starting cve-2017-5669
[35514.246465] LTP: starting cve-2017-6951
[35514.279565] LTP: starting cve-2017-7308 (setsockopt02)
[35514.468334] LTP: starting cve-2017-7472 (keyctl04)
[35514.499488] LTP: starting cve-2017-12192 (keyctl07)
[35514.536481] LTP: starting cve-2017-12193 (add_key04)
[35514.568432] LTP: starting cve-2017-15274 (add_key02)
[35514.599299] LTP: starting cve-2017-15299 (request_key03 -b cve-2017-15299)
[35523.796596] LTP: starting cve-2017-15537 (ptrace07)
[35523.825007] LTP: starting cve-2017-15951 (request_key03 -b cve-2017-15951)
[35533.478648] LTP: starting cve-2017-1000364 (stack_clash)

対応version

コミットログ確認するとcveテストコード追加は、今年の六月からの追加っぽいねw−

$ cd ltp/runtest/
$ tig cve
2017-11-13 14:01 Eric Biggers       o syscalls/add_key04: new test for associative array bug
2017-11-06 21:26 Eric Biggers       o syscalls/request_key03: new test for key instantiation races
2017-11-02 15:34 Richard Palethorpe o Add test for CVE-2017-7308 on a raw socket's ring buffer
2017-11-01 15:59 Richard Palethorpe o Add test keyctl08 for cve-2016-9604 on keyctl_join_session_keyring
2017-10-19 11:07 Eric Biggers       o syscalls/ptrace07: new test for ptrace FPU state corruption
2017-10-19 10:28 Eric Biggers       o syscalls/keyctl07: new test for oops when reading negative key
2017-10-12 15:37 Richard Palethorpe o Assign CVE number to add_key02
2017-09-11 13:50 Richard Palethorpe o Test for CVE-2016-10044 mark AIO pseudo-fs noexec
2017-08-31 15:44 Guangwen Feng      o Test for CVE-2017-2618 in setprocattr
2017-08-29 11:37 Guangwen Feng      o CVE: Add some existing tests to runtest/cve
2017-08-03 13:29 Guangwen Feng      o Test for CVE-2016-7042 in /proc/keys show function
2017-07-31 17:46 Eric Biggers       o syscalls/keyctl04: new test for thread keyring memory leak
2017-08-08 17:11 Richard Palethorpe o CVE: Add some existing tests to runtest file
2017-07-28 16:01 Pavel Boldin       o security/stack_clash: Add new test
2017-07-24 10:53 Richard Palethorpe o Test for CVE-2017-2671 on ping sockets
2017-07-20 12:09 Richard Palethorpe o Test for CVE-2017-5669 in shmat
2017-06-23 14:22 Richard Palethorpe o Test for CVE-2017-6951 in request_key
2017-06-23 14:22 Richard Palethorpe o Test for CVE-2014-0196 PTY echo race
2017-06-23 14:22 Richard Palethorpe I Add CVE .gitignore, Makefile and runtest files

やっぱりOSSは最新に限るよなぁ〜w<b

Pine A64+のxrdpサーバへwin10から接続してみた


arm64のubuntuのSBC*1リモートデスクトップするお話ですーwー

 この記事を、Debian/Ubuntu Advent Calendar 2017の18日目の記事にします^^;

P.S.

別にarm系のSBCでなくても、同件不具合?で家のx86/ubuntu16.04だとxrdp_v0.6は接続失敗しました

P.P.S.

Pine A64+なのはメモリが2GBと少し多め*2なので普通にxrdpサーバとしてrasberry pi2のメモリ1GBより使えそうだから^^


 Xenial Mate [20161215] *3のxrdpサーバがver0.6系*4と古いのは仕方ないとしても、そもそもaptでインストールしたxrdpにはwin10から接続が途中で失敗で動かなかったw−
なんか私の使うパッケージがマイナーなのかこんな感じの不具合をよく踏みますw−。


Pine64のQ&A見るとaptのxrdpでも繋がりそうですけど


なので、xrdp0.9系を自前ビルド*5してインストールしました。

下記のQiita記事によると、v0.6は日本語入力設定必要とTLS接続未対応らしいです

X11RDP-o-Maticについて


 最初は上記をX11RDP-o-Maticを試したのですが、ビルド?できませんでした。
X11RDP-o-Maticの本家サイトにもxrdpの最新でビルド壊れた的なことが書かれていましたので利用を諦めましたw<b

ビルド及び、インストール

Ubuntu16.04LTSにxrdpでリモートデスクトップ接続さんの手順より以下だけ実行しました(まる

  • 1.Desctop環境のインストール
  • 3.xrdpの導入
    • 「(3)Build準備/(4)Build&インストール」を実施*6
      • パッケージビルドエラーで、足りないものをその都度インストール
      • ビルドはARMでも1時間以内で終わった*7
  • 5.デスクトップセッションの設定
    • 「(1)デスクトップにMateを導入している場合」を実施
  • 6.ログローテーション設定
arm64でのdebパッケージ
murase@pine64:~/build$ ll
total 7368
drwxrwxr-x  4 murase murase    4096 Dec 29 07:45 ./
drwxr-xr-x 28 murase murase    4096 Dec 29 09:16 ../
-rw-r--r--  1 root   root     69710 Dec 29 07:45 xorgxrdp_0.9.1-7build1_arm64.deb★これと
drwxr-xr-x 30 root   root      4096 Dec 29 07:33 xrdp-0.9.1/
-rw-r--r--  1 root   root      1084 Dec 29 07:45 xrdp_0.9.1-7build1_arm64.changes
-rw-r--r--  1 root   root    385472 Dec 29 07:45 xrdp_0.9.1-7build1_arm64.deb★これをインストールしました
-rw-r--r--  1 root   root     27304 Dec 29 07:05 xrdp_0.9.1-7build1.debian.tar.xz
-rw-r--r--  1 root   root      2580 Dec 29 07:05 xrdp_0.9.1-7build1.dsc
-rw-r--r--  1 root   root   3025809 Dec 29 07:05 xrdp_0.9.1.orig.tar.gz
-rw-r--r--  1 root   root    423366 Dec 29 07:05 xrdp_0.9.1.orig-xorgxrdp.tar.gz
drwxr-xr-x 28 root   root      4096 Dec 18 14:58 xrdp-0.9.4/
-rw-r--r--  1 root   root     24692 Dec 18 14:58 xrdp_0.9.4-2.debian.tar.xz
-rw-r--r--  1 root   root      2668 Dec 18 14:58 xrdp_0.9.4-2.dsc
-rw-r--r--  1 root   root   3069778 Dec 18 14:58 xrdp_0.9.4.orig.tar.gz
-rw-r--r--  1 root   root    467342 Dec 18 14:58 xrdp_0.9.4.orig-xorgxrdp.tar.gz

サービスの起動


で、インストールしてもそのままではwindows10からリモートデスクトップで繋がらなかったので、xrdpサービス起動させます。

  • 「6. 端末上に以下のコマンドを入力 / 実行し、xrdpのサービスを起動し、自動起動を有効にします。」のみ。
    • (他のした方がいいかな?


何回もパスワード求められるので頑張って入力してください(sudoしたら一回で済む?

systemctl start xrdp.service
systemctl enable xrdp.service

ポート設定の変更


CentOS 7 上で xrdp を用いた RDP 接続するポート番号を変更するを参考に接続先のポート番号だけ、変えておきます。


$ sudo vim /etc/xrdp/xrdp.ini

  ; tcp port to listen
+ ;port=3389
+ port=13456

windows10からremoteデスクトップ接続

「<ローカルIP>:<ポート番号>」でwin10の「リモートデスクトップ接続」が繋がれば成功ですw−

*1:シングルボードコンピュータ

*2:なのとubuntuなのとMaliのGPUドライバに多少最適化してるとのこと

*3:ってかubuntu16.04

*4:結構古くセキュリティが貧弱

*5:2018のLTSには流石に0.9系が入っているでしょうから賞味期限残り4カ月くらいの情報ですがwww

*6:2017Dec30現在だと、v0.9.4やv0.9.5も出ていますが、詰まるのも嫌なので上記記事と同じver入れましたv>w<v

*7:測ってないが30分も掛かってない気がするw−

日本語入力をfcitx-mozcへ変更

 なんも考えずにdebian buster/sid のxfce4デスクトップを使っていました。
windowsみたいに普通に日本語入力が使えてたので「日本語入力システムなんて、何ですか?それ??」って状態で気にしなかったのですがが、
久しぶりにEmacsで日本語入力しようとするとローマ字変換がおかしい。upgradeのときでもどっか壊れたか?


(どうおかしいって、kaがローマ字変換で「か」にならず、全然関係ない「非」とか*1になって明らかにMozcのローマ字変換辺り?が可笑しいですよ)

 で、昔のdebian勉強会でこのあたりの日本語入力について発表された方がいた覚えがあったのでググってみた*2


 今回は、上記資料の長期的な修正?のfcitx-mozcの組み合わせにした。
以下のArchの方も2016/02でibus-mozcかfcitx-mozcで迷われて、fcitxにされたっぽいしそろそろ2018年だし大丈夫でしょ。


以下をインストールしたら、ローマ字変換不具合が解決した*3よw−

apt-get install fcitx-mozc mozc-server mozc-utils-gui


おしまい^^

P.S. その他ググった参考

*1:非ってのは適当です。なんか変な漢字やカタカナ、ひらがなになりましたw;

*2:デビアンの薄い本に乗ってるか思ったが今年のには乗ってなかったw=。

*3:原因の調べ方がよくわからなかったのでfcitxのインストールで治ってよかった

ARMv8での「Rustの3種のべき乗演算の速度差について」

P.S. 12/14

この記事は、多分Rustその2 Advent Calendar 2017の11日目*1の記事ですw−

以下記事の引用追記です。

参照記事にARMv8のベンチが抜けていて、ちょうど手元にRustが入ったARMv8*2が有ったので補足で実行してみた。

注意。なんかミスしてるのかテストが実行出来ていない*3

$ cargo test --release
   Compiling leibniz_formula v0.1.0 (file:///home/ubuntu/rustProject/leibniz_formula)
    Finished release [optimized] target(s) in 3.7 secs
     Running target/release/deps/leibniz_formula-8a2c0c0eabb03fbe

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out

64ビット ARM 4x Cortex-A53 @ 1.30GHz

os : ubuntu 16.04
board : PINE A64+

  • f64powf : 318,065,715 ns
  • f64powi : 216,401,904 ns
  • i64pow : 151,364,829 ns
$ RUSTFLAGS='-C opt-level=3 -C target-cpu=native' \
>   cargo +nightly bench --features benches
   Compiling leibniz_formula v0.1.0 (file:///home/ubuntu/rustProject/leibniz_formula)
    Finished release [optimized] target(s) in 8.22 secs
     Running target/release/deps/leibniz_formula-bac0637812b2becb

running 3 tests
test benches::bench_leibniz_f64powf ... bench: 318,065,715 ns/iter (+/- 396,371)
test benches::bench_leibniz_f64powi ... bench: 216,401,904 ns/iter (+/- 50,139)
test benches::bench_leibniz_i64pow  ... bench: 151,364,829 ns/iter (+/- 67,599)

test result: ok. 0 passed; 0 failed; 0 ignored; 3 measured; 0 filtered out
$ rustup run nightly rustc --version --verbose
rustc 1.24.0-nightly (6a3601944 2017-12-12)
binary: rustc
commit-hash: 6a360194404c07e09b548626efa4b7c7777510e9
commit-date: 2017-12-12
host: aarch64-unknown-linux-gnu
release: 1.24.0-nightly
LLVM version: 4.0

$ uname -srm
Linux 3.10.105-0-pine64-longsleep aarch64

$ cat /proc/cpuinfo
Processor       : AArch64 Processor rev 4 (aarch64)
processor       : 0
processor       : 1
processor       : 2
processor       : 3
Features        : fp asimd aes pmull sha1 sha2 crc32
CPU implementer : 0x41
CPU architecture: AArch64
CPU variant     : 0x0
CPU part        : 0xd03
CPU revision    : 4

Hardware        : sun50iw1p1

*1:いや数日過ぎてたけど空白だったので。きっと参加することに意義があるw<b

*2:nightlyは入ってなかったけどなw−

*3:なんもRustわからん

UE4 Style Guideを翻訳してみた

 この記事は、Unreal Engine 4 (UE4) その2 Advent Calendar 2017の7日目の記事です。

P.S. 20180101 21:51

 素のGoogle翻訳コミットの再コミットの完了です。ので2017年マイルストーン達成です:ー)
2018年はぼちぼちゆっくり翻訳していくので、急がれる方はPullReqをお待ちしてますw<b

 本記事は「UE4 Style Guideについて」「翻訳の進捗状況」と「日本語訳の注意点」との三本セットでお送りします。


 最初に本記事は、ゆるふわポエムな内容ですので、新しいパーティクルシステムなど技術的な内容を期待されているかたはブラウザバックを推奨します。
それでもかまわないという方は、お読み頂きありがとうございましす。

UE4 Style Guide について

 まず最初に、UE4 Style Guide is 何?って方のために、まずは軽くご紹介。


 UE4 Style Guideとは、Allarさんが書かれている以下のUE4開発での注意点をまとめたgithubドキュメントのことです。


プログラミングのコーディング規約みたいなもので、一人開発で守れはちょっと幸せ、チーム開発で守ればみんな幸せになれる
文字通りのUE4の開発スタイルのガイド(案内)となっています。、



 で、そんなスタイルガイドなんですけど見ての通り英語*1で、確りと読まれている方はあまりいらっしゃらないと思います。
私も去年まで存在自体を知りませんでしたが、お正月くらいに以下のツイートで存在を知りました。



 で、急いで訳さないとケアされてしまうため、一晩ででっち上げた*2のがスタイルガイド日本語訳になります。


最初のコミットはGoogleTranslateで英語to日本語に置き換えただけのヒドい日本語訳でしたが、今は私が全て見直してますので改善の余地のある日本語訳となっています。



Todo:集団心理について limit 2017/12/25


 と頑張って訳したものの特に反応が無い*3ので誰も読んでいないんだなぁ〜と思っていましたが
ググってみるとUE4StyleGuideについて詳しい記事を書かれている方がいらっしゃいました。のでお役に立っているようで何よりです。




UE4StyleGuideの有用性に関しては、その方が丁寧に纏めていただいているので、そちらのブログを参照してください。


UE4 Style GuideとLinterPlugin | 電子工作部

進捗状況報告

 まずupstreamに対する進捗状況としては、2017/12/07で100%日本語訳済みです。

翻訳の品質について

 以下の日本語としての翻訳の品質*4です。個人的には日本語訳としては一旦80%超えればOKとしています。
ですので、80%以下は英語版と併用なさると吉です^^;

各章の完成度
  • ch.-1 初め: 90%
  • ch. 0 原則: 90%
  • ch. 1 命名: 90%
  • ch. 2 構成: 60%
  • ch. 3 BP: 70%
  • ch. 4 SM: 70%
  • ch. 5 PS: 80%
  • ch. 6 LM: 80%
  • ch. 2 TX: 80%
UE4ドキュメントとしての品質について


 UE4の技術的な内容を確りと訳せているについては、すみません。不備が残ってます。
調べてはいますが、自身がよくわからず無理くり訳しているだけの個所もありますので
誤りやあいまいな箇所に関しては(普通に良く解らないと)ご指摘していただけると助かります。

日本語訳の注意点


 こちらはスタイルガイドを読者(読むだけの方)には本当に関係のない話です。
けど、まあ触れておかないわけにはいかない事も含みますのでご了承ください。

ライセンスについて

 上記でも触れていますが、日本語版のfork初期は、GoogleTranslate訳で置き換えただけでした。
UE4 Style Guideの英語版がMITライセンスですので日本語版もそれを継承しています。


 で、今年の前半に上記が問題になったのでご存じの方もいらっしゃるとは思いますが。
GoogleTranslate等のWebServiceの生成物(要日本語訳テキスト)のライセンスはMITライセンスに変更できないです。
ので現状、厳密に法的な解釈をするのであれば日本語訳はまあグレーである*5ことは間違いないです。


で、どうするかというとGoogleTranslateの生成物は、一旦私が全て精査した*6という体裁にするため
年内には以下のgit blameレベルでGoogleTranslateの痕跡を消す予定です。


UE4 Style Guide 日本語訳 git blame


ですので、日本語版をforkして、オレオレStyleGuideを作ろうと思われている方*7は、年内はちょっと待っていただけると幸いです><。

翻訳方針について

 こちらは翻訳の質が悪くて我慢できないなどでPullReqなどをしていただけるかもしれない方へ。

 各章、節などの部分で、基本問題なく日本語として翻訳出来ていれば全体の整合性は問題ありません。
のでお気楽にPullReq下さい(切実w=。


専門分野の個所などはこちら一人ではちょっとピンと来ないことが多くそれらの個所のご指摘などして頂けるだけでも助かります。


 あと日本語訳は英語と1対1で対応するよう直訳に出来るだけしていますが、以下のようにカッコで翻訳版のみの参考情報などを追加している箇所があります。
もし有用な補足を同様に入れられる場合は、下記に従っていただけると助かります。

  • 一重カッコ (hogehoge)
    • 日本語に訳したが、英単語やカタカナ表記など併記したい場合
      • 例えばPropertiesを属性と訳するか
  • 二重カッコ ( (hogehoge) )
    • ??や???など
      • 翻訳者が良く解っていないけど無理やり訳した部分
    • 日本語版でのみ追加した参考情報、説明や関連リンクなど
      • 自分用の参考情報へのリンクなど

最後に


 上記でも述べてますが、UE4独自の専門用語などに関しては翻訳に誤りなどがあると思います。
それでなくても現状日本語としての不備もありますので、PullReqでなくても構いませんので
IsuueやTwitterなどのでご指摘いただければ幸いです。


 そのような稚拙な翻訳ですが、皆様のUE4での開発にお役に立っていれば幸いですm(_ _)m

*1:翻訳は大変ですからねw−

*2:嘘ですw0.関ゲ部はアットホームはゲ部なので。あとPullReqが1/7なので三晩くらいです

*3:いやあのクソ翻訳で構わないのなら良いのですが^^;

*4:綺麗に訳せているか

*5:かといってGoogleが個人に一々法的措置をとるかと言えば、ほぼほぼ皆無ですが

*6:と言えば現状ほぼほぼ精査しています。読んで日本語として可笑しくなければ大体私が修正してますから

*7:本家の英語版は結構いらっしゃいますね^^

UnixBenchまとめメモ

相対知りたいので、手持ちのARMv7/v8やx86*1なんかつらつら纏めるw−

  • ARMv7
    • Rasberry Pi 2 *2 (Broadcom BCM2836 CA7x4 0.9GHz)
      • raspberrypi 4.9.70-v7+
        • 1 CPUs : 171.6
        • 4 CPUs : 434.8
  • ARMv8
    • PINE A64 (Allwiner A64 CA53x4 1.3GHz)
      • Ubuntu 16.04.3 LTS (GNU/Linux 3.10.105-0-pine64-longsleep aarch64)
        • 1 CPUs : 323.8
        • 4 CPUs : 923.4
    • NanoPi2Neo (Allwiner H5 CA53x4 1.0GHz)
      • ARMBIAN 5.34.171121 nightly Debian GNU/Linux 9 (stretch) 4.13.14-sunxi64
        • 1 CPUs : 291.4
        • 4 CPUs : 724.3
  • x86
    • AMD PhenomII X6 1065T 2.9GHz
      • Ubuntu 16.04 (x86)
        • 1 CPUs : 1210.5
        • 6 CPUs : 3951.5

Rasberry Pi 2

$ cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
600000 900000
========================================================================
   BYTE UNIX Benchmarks (Version 5.1.3)

   System: raspberrypi: GNU/Linux
   OS: GNU/Linux -- 4.9.70-v7+ -- #1068 SMP Mon Dec 18 22:12:55 GMT 2017
   Machine: armv7l (unknown)
   Language: en_US.utf8 (charmap="ANSI_X3.4-1968", collate="ANSI_X3.4-1968")
   CPU 0: ARMv7 Processor rev 5 (v7l) (0.0 bogomips)

   CPU 1: ARMv7 Processor rev 5 (v7l) (0.0 bogomips)

   CPU 2: ARMv7 Processor rev 5 (v7l) (0.0 bogomips)

   CPU 3: ARMv7 Processor rev 5 (v7l) (0.0 bogomips)

   12:22:17 up 7 min,  1 user,  load average: 0.16, 0.21, 0.10; runlevel Dec

------------------------------------------------------------------------
Benchmark Run: Sat Dec 23 2017 12:22:17 - 12:50:40
4 CPUs in system; running 1 parallel copy of tests

Dhrystone 2 using register variables        3063963.9 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                      593.0 MWIPS (10.0 s, 7 samples)
Execl Throughput                                325.8 lps   (29.9 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks         70162.0 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks           20404.4 KBps  (30.0 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks        185755.4 KBps  (30.0 s, 2 samples)
Pipe Throughput                              188247.8 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                  32958.1 lps   (10.0 s, 7 samples)
Process Creation                               1101.9 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                   1150.8 lpm   (60.0 s, 2 samples)
Shell Scripts (8 concurrent)                    326.2 lpm   (60.1 s, 2 samples)
System Call Overhead                         404356.1 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0    3063963.9    262.6
Double-Precision Whetstone                       55.0        593.0    107.8
Execl Throughput                                 43.0        325.8     75.8
File Copy 1024 bufsize 2000 maxblocks          3960.0      70162.0    177.2
File Copy 256 bufsize 500 maxblocks            1655.0      20404.4    123.3
File Copy 4096 bufsize 8000 maxblocks          5800.0     185755.4    320.3
Pipe Throughput                               12440.0     188247.8    151.3
Pipe-based Context Switching                   4000.0      32958.1     82.4
Process Creation                                126.0       1101.9     87.5
Shell Scripts (1 concurrent)                     42.4       1150.8    271.4
Shell Scripts (8 concurrent)                      6.0        326.2    543.7
System Call Overhead                          15000.0     404356.1    269.6
                                                                   ========
System Benchmarks Index Score                                         171.6

------------------------------------------------------------------------
Benchmark Run: Sat Dec 23 2017 12:50:40 - 13:19:08
4 CPUs in system; running 4 parallel copies of tests

Dhrystone 2 using register variables       12225368.4 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                     2366.8 MWIPS (10.0 s, 7 samples)
Execl Throughput                               1183.4 lps   (29.9 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        107750.0 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks           30013.6 KBps  (30.0 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks        286692.2 KBps  (30.0 s, 2 samples)
Pipe Throughput                              749997.1 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                 127497.2 lps   (10.0 s, 7 samples)
Process Creation                               2641.6 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                   2644.0 lpm   (60.1 s, 2 samples)
Shell Scripts (8 concurrent)                    346.7 lpm   (60.5 s, 2 samples)
System Call Overhead                        1557986.9 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0   12225368.4   1047.6
Double-Precision Whetstone                       55.0       2366.8    430.3
Execl Throughput                                 43.0       1183.4    275.2
File Copy 1024 bufsize 2000 maxblocks          3960.0     107750.0    272.1
File Copy 256 bufsize 500 maxblocks            1655.0      30013.6    181.4
File Copy 4096 bufsize 8000 maxblocks          5800.0     286692.2    494.3
Pipe Throughput                               12440.0     749997.1    602.9
Pipe-based Context Switching                   4000.0     127497.2    318.7
Process Creation                                126.0       2641.6    209.7
Shell Scripts (1 concurrent)                     42.4       2644.0    623.6
Shell Scripts (8 concurrent)                      6.0        346.7    577.8
System Call Overhead                          15000.0    1557986.9   1038.7
                                                                   ========
System Benchmarks Index Score                                         434.8

PINE A64

u$ cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
480000 600000 720000 816000 912000 960000 1008000 1056000 1104000 1152000 1200000 1344000
========================================================================
   BYTE UNIX Benchmarks (Version 5.1.3)

   System: pine64: GNU/Linux
   OS: GNU/Linux -- 3.10.105-0-pine64-longsleep -- #3 SMP PREEMPT Sat Mar 11 16:05:53 CET 2017
   Machine: aarch64 (aarch64)
   Language: en_US.utf8 (charmap="UTF-8", collate="UTF-8")
   12:27:07 up  1:12,  2 users,  load average: 0.15, 0.13, 0.14; runlevel 2016-02-11

------------------------------------------------------------------------
Benchmark Run: Tue Dec 05 2017 12:27:07 - 12:55:20
4 CPUs in system; running 1 parallel copy of tests

Dhrystone 2 using register variables        6101367.2 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                     1067.0 MWIPS (10.0 s, 7 samples)
Execl Throughput                                599.0 lps   (29.5 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        134949.0 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks           40665.9 KBps  (30.0 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks        327947.0 KBps  (30.0 s, 2 samples)
Pipe Throughput                              337914.3 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                  61160.5 lps   (10.0 s, 7 samples)
Process Creation                               1891.4 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                   2232.1 lpm   (60.0 s, 2 samples)
Shell Scripts (8 concurrent)                    726.4 lpm   (60.0 s, 2 samples)
System Call Overhead                         750743.9 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0    6101367.2    522.8
Double-Precision Whetstone                       55.0       1067.0    194.0
Execl Throughput                                 43.0        599.0    139.3
File Copy 1024 bufsize 2000 maxblocks          3960.0     134949.0    340.8
File Copy 256 bufsize 500 maxblocks            1655.0      40665.9    245.7
File Copy 4096 bufsize 8000 maxblocks          5800.0     327947.0    565.4
Pipe Throughput                               12440.0     337914.3    271.6
Pipe-based Context Switching                   4000.0      61160.5    152.9
Process Creation                                126.0       1891.4    150.1
Shell Scripts (1 concurrent)                     42.4       2232.1    526.4
Shell Scripts (8 concurrent)                      6.0        726.4   1210.7
System Call Overhead                          15000.0     750743.9    500.5
                                                                   ========
System Benchmarks Index Score                                         323.8

------------------------------------------------------------------------
Benchmark Run: Tue Dec 05 2017 12:55:20 - 13:23:42
4 CPUs in system; running 4 parallel copies of tests

Dhrystone 2 using register variables       24001748.5 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                     4195.3 MWIPS (10.0 s, 7 samples)
Execl Throughput                               3011.3 lps   (29.9 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        225629.9 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks           60952.8 KBps  (30.0 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks        640900.0 KBps  (30.0 s, 2 samples)
Pipe Throughput                             1323913.1 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                 236998.5 lps   (10.0 s, 7 samples)
Process Creation                               9100.6 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                   5850.2 lpm   (60.0 s, 2 samples)
Shell Scripts (8 concurrent)                    775.6 lpm   (60.2 s, 2 samples)
System Call Overhead                        2783983.1 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0   24001748.5   2056.7
Double-Precision Whetstone                       55.0       4195.3    762.8
Execl Throughput                                 43.0       3011.3    700.3
File Copy 1024 bufsize 2000 maxblocks          3960.0     225629.9    569.8
File Copy 256 bufsize 500 maxblocks            1655.0      60952.8    368.3
File Copy 4096 bufsize 8000 maxblocks          5800.0     640900.0   1105.0
Pipe Throughput                               12440.0    1323913.1   1064.2
Pipe-based Context Switching                   4000.0     236998.5    592.5
Process Creation                                126.0       9100.6    722.3
Shell Scripts (1 concurrent)                     42.4       5850.2   1379.8
Shell Scripts (8 concurrent)                      6.0        775.6   1292.7
System Call Overhead                          15000.0    2783983.1   1856.0
                                                                   ========
System Benchmarks Index Score                                         923.4

NanoPi2Neo

$ cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
408000 648000 816000 912000 960000 1008000
$ cpufreq-info
cpufrequtils 008: cpufreq-info (C) Dominik Brodowski 2004-2009
Report errors and bugs to cpufreq@vger.kernel.org, please.
analyzing CPU 0:
  driver: cpufreq-dt
  CPUs which run at the same hardware frequency: 0 1 2 3
  CPUs which need to have their frequency coordinated by software: 0 1 2 3
  maximum transition latency: 244 us.
  hardware limits: 408 MHz - 1.01 GHz
  available frequency steps: 408 MHz, 648 MHz, 816 MHz, 912 MHz, 960 MHz, 1.01 GHz
  available cpufreq governors: conservative, userspace, powersave, ondemand, performance, schedutil
  current policy: frequency should be within 408 MHz and 816 MHz.
                  The governor "ondemand" may decide which speed to use
                  within this range.
  current CPU frequency is 408 MHz.
  cpufreq stats: 408 MHz:59.28%, 648 MHz:3.22%, 816 MHz:37.49%, 912 MHz:0.01%, 960 MHz:0.00%, 1.01 GHz:0.01%  (3738)
analyzing CPU 1:
  driver: cpufreq-dt
  CPUs which run at the same hardware frequency: 0 1 2 3
  CPUs which need to have their frequency coordinated by software: 0 1 2 3
  maximum transition latency: 244 us.
  hardware limits: 408 MHz - 1.01 GHz
  available frequency steps: 408 MHz, 648 MHz, 816 MHz, 912 MHz, 960 MHz, 1.01 GHz
  available cpufreq governors: conservative, userspace, powersave, ondemand, performance, schedutil
  current policy: frequency should be within 408 MHz and 816 MHz.
                  The governor "ondemand" may decide which speed to use
                  within this range.
  current CPU frequency is 408 MHz.
  cpufreq stats: 408 MHz:59.28%, 648 MHz:3.22%, 816 MHz:37.49%, 912 MHz:0.01%, 960 MHz:0.00%, 1.01 GHz:0.01%  (3738)
analyzing CPU 2:
  driver: cpufreq-dt
  CPUs which run at the same hardware frequency: 0 1 2 3
  CPUs which need to have their frequency coordinated by software: 0 1 2 3
  maximum transition latency: 244 us.
  hardware limits: 408 MHz - 1.01 GHz
  available frequency steps: 408 MHz, 648 MHz, 816 MHz, 912 MHz, 960 MHz, 1.01 GHz
  available cpufreq governors: conservative, userspace, powersave, ondemand, performance, schedutil
  current policy: frequency should be within 408 MHz and 816 MHz.
                  The governor "ondemand" may decide which speed to use
                  within this range.
  current CPU frequency is 408 MHz.
  cpufreq stats: 408 MHz:59.28%, 648 MHz:3.22%, 816 MHz:37.49%, 912 MHz:0.01%, 960 MHz:0.00%, 1.01 GHz:0.01%  (3738)
analyzing CPU 3:
  driver: cpufreq-dt
  CPUs which run at the same hardware frequency: 0 1 2 3
  CPUs which need to have their frequency coordinated by software: 0 1 2 3
  maximum transition latency: 244 us.
  hardware limits: 408 MHz - 1.01 GHz
  available frequency steps: 408 MHz, 648 MHz, 816 MHz, 912 MHz, 960 MHz, 1.01 GHz
  available cpufreq governors: conservative, userspace, powersave, ondemand, performance, schedutil
  current policy: frequency should be within 408 MHz and 816 MHz.
                  The governor "ondemand" may decide which speed to use
                  within this range.
  current CPU frequency is 408 MHz.
  cpufreq stats: 408 MHz:59.28%, 648 MHz:3.22%, 816 MHz:37.49%, 912 MHz:0.01%, 960 MHz:0.00%, 1.01 GHz:0.01%  (3738)
========================================================================
   BYTE UNIX Benchmarks (Version 5.1.3)

   System: nanopineo2: GNU/Linux
   OS: GNU/Linux -- 4.13.14-sunxi64 -- #246 SMP Mon Nov 20 01:58:09 CET 2017
   Machine: aarch64 (unknown)
   Language: en_US.utf8 (charmap="UTF-8", collate="UTF-8")
   12:27:56 up  1:13,  2 users,  load average: 0.14, 0.03, 0.01; runlevel 2017-12-04

------------------------------------------------------------------------
Benchmark Run: Tue Dec 05 2017 12:27:56 - 12:56:10
4 CPUs in system; running 1 parallel copy of tests

Dhrystone 2 using register variables        4116361.6 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                      768.7 MWIPS (10.0 s, 7 samples)
Execl Throughput                                980.3 lps   (29.9 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        128350.9 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks           39726.7 KBps  (30.0 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks        293192.0 KBps  (30.0 s, 2 samples)
Pipe Throughput                              324428.4 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                  50672.8 lps   (10.0 s, 7 samples)
Process Creation                               2334.1 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                   1785.2 lpm   (60.0 s, 2 samples)
Shell Scripts (8 concurrent)                    534.5 lpm   (60.1 s, 2 samples)
System Call Overhead                         554251.9 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0    4116361.6    352.7
Double-Precision Whetstone                       55.0        768.7    139.8
Execl Throughput                                 43.0        980.3    228.0
File Copy 1024 bufsize 2000 maxblocks          3960.0     128350.9    324.1
File Copy 256 bufsize 500 maxblocks            1655.0      39726.7    240.0
File Copy 4096 bufsize 8000 maxblocks          5800.0     293192.0    505.5
Pipe Throughput                               12440.0     324428.4    260.8
Pipe-based Context Switching                   4000.0      50672.8    126.7
Process Creation                                126.0       2334.1    185.2
Shell Scripts (1 concurrent)                     42.4       1785.2    421.0
Shell Scripts (8 concurrent)                      6.0        534.5    890.8
System Call Overhead                          15000.0     554251.9    369.5
                                                                   ========
System Benchmarks Index Score                                         291.4

------------------------------------------------------------------------
Benchmark Run: Tue Dec 05 2017 12:56:10 - 13:24:36
4 CPUs in system; running 4 parallel copies of tests

Dhrystone 2 using register variables       15974166.9 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                     3002.7 MWIPS (10.0 s, 7 samples)
Execl Throughput                               2336.7 lps   (29.9 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        213439.6 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks           63877.0 KBps  (30.0 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks        573999.4 KBps  (30.0 s, 2 samples)
Pipe Throughput                             1270102.5 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                 178175.6 lps   (10.0 s, 7 samples)
Process Creation                               5364.1 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                   4236.7 lpm   (60.0 s, 2 samples)
Shell Scripts (8 concurrent)                    556.6 lpm   (60.3 s, 2 samples)
System Call Overhead                        2083784.0 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0   15974166.9   1368.8
Double-Precision Whetstone                       55.0       3002.7    545.9
Execl Throughput                                 43.0       2336.7    543.4
File Copy 1024 bufsize 2000 maxblocks          3960.0     213439.6    539.0
File Copy 256 bufsize 500 maxblocks            1655.0      63877.0    386.0
File Copy 4096 bufsize 8000 maxblocks          5800.0     573999.4    989.7
Pipe Throughput                               12440.0    1270102.5   1021.0
Pipe-based Context Switching                   4000.0     178175.6    445.4
Process Creation                                126.0       5364.1    425.7
Shell Scripts (1 concurrent)                     42.4       4236.7    999.2
Shell Scripts (8 concurrent)                      6.0        556.6    927.6
System Call Overhead                          15000.0    2083784.0   1389.2
                                                                   ========
System Benchmarks Index Score                                         724.3

Phenome X6

$ cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies
2900000 2200000 1500000 800000
========================================================================
   BYTE UNIX Benchmarks (Version 5.1.3)

   System: amdx6: GNU/Linux
   OS: GNU/Linux -- 4.4.0-101-generic -- #124-Ubuntu SMP Fri Nov 10 18:29:59 UTC 2017
   Machine: x86_64 (x86_64)
   Language: en_US.utf8 (charmap="UTF-8", collate="UTF-8")
   CPU 0: AMD Phenom(tm) II X6 1065T Processor (5819.1 bogomips)
          Hyper-Threading, x86-64, MMX, AMD MMX, Physical Address Ext, SYSENTER/SYSEXIT, AMD virtualization, SYSCALL/SYSRET
   CPU 1: AMD Phenom(tm) II X6 1065T Processor (5819.1 bogomips)
          Hyper-Threading, x86-64, MMX, AMD MMX, Physical Address Ext, SYSENTER/SYSEXIT, AMD virtualization, SYSCALL/SYSRET
   CPU 2: AMD Phenom(tm) II X6 1065T Processor (5819.1 bogomips)
          Hyper-Threading, x86-64, MMX, AMD MMX, Physical Address Ext, SYSENTER/SYSEXIT, AMD virtualization, SYSCALL/SYSRET
   CPU 3: AMD Phenom(tm) II X6 1065T Processor (5819.1 bogomips)
          Hyper-Threading, x86-64, MMX, AMD MMX, Physical Address Ext, SYSENTER/SYSEXIT, AMD virtualization, SYSCALL/SYSRET
   CPU 4: AMD Phenom(tm) II X6 1065T Processor (5819.1 bogomips)
          Hyper-Threading, x86-64, MMX, AMD MMX, Physical Address Ext, SYSENTER/SYSEXIT, AMD virtualization, SYSCALL/SYSRET
   CPU 5: AMD Phenom(tm) II X6 1065T Processor (5819.1 bogomips)
          Hyper-Threading, x86-64, MMX, AMD MMX, Physical Address Ext, SYSENTER/SYSEXIT, AMD virtualization, SYSCALL/SYSRET
   22:58:39 up  2:00,  2 users,  load average: 0.01, 0.09, 1.66; runlevel 2017-12-05

------------------------------------------------------------------------
Benchmark Run: 火 1205 2017 22:58:39 - 23:26:48
6 CPUs in system; running 1 parallel copy of tests

Dhrystone 2 using register variables       29814481.6 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                     3889.4 MWIPS (9.9 s, 7 samples)
Execl Throughput                               1397.9 lps   (29.9 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        910211.1 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks          280225.6 KBps  (30.0 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks       1501667.6 KBps  (30.0 s, 2 samples)
Pipe Throughput                             1973837.6 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                  84639.2 lps   (10.0 s, 7 samples)
Process Creation                               5500.1 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                   4175.8 lpm   (60.0 s, 2 samples)
Shell Scripts (8 concurrent)                   2793.1 lpm   (60.0 s, 2 samples)
System Call Overhead                        3735909.6 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0   29814481.6   2554.8
Double-Precision Whetstone                       55.0       3889.4    707.2
Execl Throughput                                 43.0       1397.9    325.1
File Copy 1024 bufsize 2000 maxblocks          3960.0     910211.1   2298.5
File Copy 256 bufsize 500 maxblocks            1655.0     280225.6   1693.2
File Copy 4096 bufsize 8000 maxblocks          5800.0    1501667.6   2589.1
Pipe Throughput                               12440.0    1973837.6   1586.7
Pipe-based Context Switching                   4000.0      84639.2    211.6
Process Creation                                126.0       5500.1    436.5
Shell Scripts (1 concurrent)                     42.4       4175.8    984.9
Shell Scripts (8 concurrent)                      6.0       2793.1   4655.1
System Call Overhead                          15000.0    3735909.6   2490.6
                                                                   ========
System Benchmarks Index Score                                        1210.5

------------------------------------------------------------------------
Benchmark Run: 火 1205 2017 23:26:48 - 23:55:03
6 CPUs in system; running 6 parallel copies of tests

Dhrystone 2 using register variables      152577861.5 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                    19921.3 MWIPS (10.0 s, 7 samples)
Execl Throughput                              16447.4 lps   (29.9 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        762764.9 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks          208524.4 KBps  (30.0 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks       1783895.6 KBps  (30.0 s, 2 samples)
Pipe Throughput                            10053642.1 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                1410660.8 lps   (10.0 s, 7 samples)
Process Creation                              46991.5 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                  35909.1 lpm   (60.0 s, 2 samples)
Shell Scripts (8 concurrent)                   4426.1 lpm   (60.0 s, 2 samples)
System Call Overhead                        2420965.0 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0  152577861.5  13074.4
Double-Precision Whetstone                       55.0      19921.3   3622.0
Execl Throughput                                 43.0      16447.4   3825.0
File Copy 1024 bufsize 2000 maxblocks          3960.0     762764.9   1926.2
File Copy 256 bufsize 500 maxblocks            1655.0     208524.4   1260.0
File Copy 4096 bufsize 8000 maxblocks          5800.0    1783895.6   3075.7
Pipe Throughput                               12440.0   10053642.1   8081.7
Pipe-based Context Switching                   4000.0    1410660.8   3526.7
Process Creation                                126.0      46991.5   3729.5
Shell Scripts (1 concurrent)                     42.4      35909.1   8469.1
Shell Scripts (8 concurrent)                      6.0       4426.1   7376.8
System Call Overhead                          15000.0    2420965.0   1614.0
                                                                   ========
System Benchmarks Index Score                                        3951.5

*1:盛り上がってるRISC-Vとか計りたいねw=

*2:P.S. 2017Dec23