Coder Social home page Coder Social logo

ipc_benchmark's Introduction

ipc_benchmark

IPC benchmark on Linux which is inspired by APUE

Test

Just Make style as the following :D

make && make test

Type

These are kinds of IPC in Linux as the following:

type feature
pipe unnamed pipe
fifo named pipe
socketpair unnamed unix domain socket
unix domain socket named unix domain socket
TCP remote domain socket
UDP loopback interface

Benchmark

In my personal MacBook Pro (Retina, 13-inch, Late 2013) Intel(R) Core(TM) i5-4258U CPU @ 2.40GHz, the benchmark is as the following:

pipe
128             512           1024          4096
1319Mb/s        5110Mb/s      8932Mb/s      20297Mb/s
1288233msg/s    1247449msg/s  1090370msg/s  619407msg/s

fifo
128             512           1024          4096
1358Mb/s        5491Mb/s      8440Mb/s      22018Mb/s
1326016msg/s    1340502msg/s  1030215msg/s  671929msg/s

socketpair
128             512           1024          4096
1117Mb/s        4401Mb/s      8869Mb/s      17207Mb/s
1090370msg/s    1074548msg/s  1082674msg/s  525121msg/s

uds
128             512           1024          4096
100Mb/s         102Mb/s       109Mb/s       97Mb/s
97600msg/s      24986msg/s    13289msg/s    2968msg/s

tcp
128             512           1024          4096
106Mb/s         143Mb/s       135Mb/s       128Mb/s
103508msg/s     34852msg/s    16529msg/s    3897msg/s

Also we make the benchmark on travis-ci Build Status

Contributing


To contribute to ipc_benchmark, clone this repo locally and commit your code on a separate branch.

Author


GitHub @detailyang

License


ipc_benchmark is licensed under the MIT license.

ipc_benchmark's People

Contributors

detailyang avatar mastr avatar tuxillo avatar warmonkey avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

ipc_benchmark's Issues

代码中有错误

tcp.c中connect的返回值不是fd,是表示成功的0或-1,其他文件也有类似问题

Shared Memory is slow.

Here is my result, it seems that shm is very slow, but why?
TPS
+------------+---------------+---------------+---------------+----------------+----------------+----------------+
| test/size | 128 x 100000 | 256 x 100000 | 512 x 100000 | 1024 x 100000 | 2048 x 100000 | 4096 x 100000 |
+------------+---------------+---------------+---------------+----------------+----------------+----------------+
| pipe | 115MB/s | 293MB/s | 536MB/s | 855MB/s | 1770MB/s | 2743MB/s |
| fifo | 123MB/s | 215MB/s | 418MB/s | 829MB/s | 1803MB/s | 2680MB/s |
| socketpair | 125MB/s | 237MB/s | 479MB/s | 936MB/s | 1597MB/s | 2477MB/s |
| uds | 115MB/s | 234MB/s | 508MB/s | 953MB/s | 1683MB/s | 2440MB/s |
| tcp | 189MB/s | 353MB/s | 664MB/s | 1141MB/s | 1863MB/s | 2494MB/s |
| shm | 16.609151MB/s | 32.209878MB/s | 62.803072MB/s | 123.633646MB/s | 242.465213MB/s | 479.693540MB/s |
+------------+---------------+---------------+---------------+----------------+----------------+----------------+

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.