-
|
I could need some clarification when it comes to RDMA CAS and CPU CAS operations. The scenario:
Correct me if I'm wrong but because of the different data paths taken to perform the CAS operation the locking mechanism between Node A and B will not work properly. I was thinking about letting Node B create an endpoint which is connected to itself to also perform the RDMA CAS operation so Node A and B use the same data path, but this seems unnecessarily complicated to me. What is the best practice here? Maybe |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
|
@youtive10 Can you elaborate a bit more on what you're trying to do and when the atomic variable and CAS variables are being accessed and why your case would not work properly? |
Beta Was this translation helpful? Give feedback.
-
|
@youtive10 Thanks for the context! |
Beta Was this translation helpful? Give feedback.
@youtive10 Thanks for the context!
Yes you're absolutely right. All your accesses to the atomic need to use the same mechanism
If you want to target the RDMA CAS directly, then I think you're going to have to open a separate connection for the local access to the variable, unfortunately.
If it's an option for you, you could use an RDM endpoint instead and use RxM to manage your atomics. RxM uses CPU atomics to simulate the CAS with the underlying provider so the remote and local access mechanisms would be aligned in that case.
https://github.com/ofiwg/libfabric/blob/main/prov/rxm/src/rxm_cq.c#L1154