# RE: Writing RDMA applications on Linux

- From: Hefty, Sean \<hidden\>
- Date: 2012-08-24 15:40:46 
- List: linux-rdma
- Page: https://ratatoskr.run/linux-rdma/2012/08/15419044
- Thread: https://ratatoskr.run/linux-rdma/2012/08/15419044/t.md

```text
> post a message receive
> rdma connection
> wait for rdma connection event
> <<at this point transfer tx flow starts>>
> start:
>    register memory containing bytes to transfer
>    wait remote memory region addr/key ( I wait for a ibv_wc)
>    send data with ibv_post_send (IBV_WR_RDMA_WRITE)
>    post a message receive
>    wait for ibv_post_send event ( I wait for a ibv_wc) (this lasts
> 13.3 ms transfering 8MB)

Try spinning for completions, rather than blocking, here...

>    send message "DONE"
>    unregister memory
> goto start
> 
> 
> Passive side:
> 
> post a message receive
> rdma accept
> wait for rdma connection event
> <<at this point transfer rx flow starts>>
> start:
>    register memory that has to receive the bytes
>    send addr/key of memory registered
>    wait "DONE" message

and here.

>    unregister memory

Remove all registration / unregistration calls outside of any performance loop.

- Sean
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
```
