Git Product home page Git Product logo

ipc-bench's People

Contributors

colelawrence avatar desbma avatar gnatty7 avatar martinsk avatar rigtorp avatar sergeyklay avatar totalgee 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  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  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

ipc-bench's Issues

32-bit platforms

On 32 bit ARM delta calculation shall be as this:

    delta = ((stop.tv_sec - start.tv_sec) * 1000000000LL +
             (stop.tv_nsec - start.tv_nsec));

and

    delta = (stop.tv_sec - start.tv_sec) * 1000000000LL +
            (stop.tv_usec - start.tv_usec) * 1000LL;

Otherwise the expression overflows, because long is 4 byte in size and by default literals are int.
It was like a time travel, negative latency 😃

Any results to share?

Please do you have any benchmark result to share?
And why not use shared memory as IPC? It should have the lowest latency.

shm.c linker error

The linker causes an error when it is called for shm.c

Error message:
cc -g -lrt shm.c -o shm
shm.c: In function ‘main’:
shm.c:96:9: warning: format ‘%lli’ expects argument of type ‘long long int’, but argument 2 has type ‘int64_t’ [-Wformat]
shm.c:96:9: warning: format ‘%lli’ expects argument of type ‘long long int’, but argument 3 has type ‘int64_t’ [-Wformat]
shm.c:96:9: warning: format ‘%lli’ expects argument of type ‘long long int’, but argument 4 has type ‘int64_t’ [-Wformat]
/tmp/ccsPjw4i.o: In function main': /home/ncoretti/ipc-bench/shm.c:56: undefined reference toclock_gettime'
/home/ncoretti/ipc-bench/shm.c:82: undefined reference to `clock_gettime'
collect2: ld returned 1 exit status
make: *** [shm] Error 1

Tested on:
Linux VIGEMDT11 3.0.0-16-generic #28-Ubuntu SMP Fri Jan 27 17:44:39 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux

Steps to reproduce the error:

  1. Clone the git repository
    git clone git://github.com/rigtorp/ipc-bench.git
  2. Enter the ipc-bench folder
    cd ipc-bench
  3. Call make all
    make all

Update README.md to show examples.

I know that in issue #13 you stated that you have no results to share but please consider adding a section to the README showing some example results the next time you test this code. From my understanding these are tests run on Linux. This repository is starred more than 500 times so clearly there is some interest in this.

Higher precision for unix_lat

I always get 1us latency for small packets.

I've made a local hack to cast delta as double, and actual value is 1.6us on my machine.

Perhaps it's something to consider?

Does not compile

Target shm does not compile

% make
cc -g -Wall -O3    pipe_lat.c   -o pipe_lat
cc -g -Wall -O3    pipe_thr.c   -o pipe_thr
cc -g -Wall -O3    unix_lat.c   -o unix_lat
cc -g -Wall -O3    unix_thr.c   -o unix_thr
cc -g -Wall -O3    tcp_lat.c   -o tcp_lat
cc -g -Wall -O3    tcp_thr.c   -o tcp_thr
cc -g -Wall -O3    tcp_local_lat.c   -o tcp_local_lat
cc -g -Wall -O3    tcp_remote_lat.c   -o tcp_remote_lat
make: *** No rule to make target 'shm', needed by 'all'.  Stop.

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.