-
Notifications
You must be signed in to change notification settings - Fork 50
transport: Deprecate enforce_cst #14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: devel
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -148,7 +148,6 @@ struct nvshmem_transport_host_ops { | |
| fence_handle fence; | ||
| quiet_handle quiet; | ||
| put_signal_handle put_signal; | ||
| int (*enforce_cst)(struct nvshmem_transport *transport); | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The more I look at this, the more I feel like enforce_cst_at_target should be removed from the function table and turned into a flag (somewhere in the nvshmem_transport struct starting on line 187). We are breaking the host-lib to transport API this release anyway, so it would be nice to just rip the band-aid off all at once.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I do agree that the flag makes more sense than the function table. It will be a little bit of time before I can go back and make this change. |
||
| int (*enforce_cst_at_target)(struct nvshmem_transport *transport); | ||
| int (*add_device_remote_mem_handles)(struct nvshmem_transport *transport, int transport_stride, | ||
| nvshmem_mem_handle_t *mem_handles, uint64_t heap_offset, | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1440,46 +1440,6 @@ int nvshmemt_ibdevx_amo(struct nvshmem_transport *tcurr, int pe, void *curetptr, | |
| return status; | ||
| } | ||
|
|
||
| int nvshmemt_ibdevx_enforce_cst_at_target(struct nvshmem_transport *tcurr) { | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This one we need to keep. It never goes through the proxy and the other code path.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Do we really need to keep this? It was only called at:
|
||
| nvshmemt_ib_common_state_t ibdevx_state = (nvshmemt_ib_common_state_t)tcurr->state; | ||
| struct ibdevx_ep *ep = (struct ibdevx_ep *)ibdevx_state->cst_ep; | ||
| struct ibdevx_rw_wqe *wqe; | ||
|
|
||
| int status = 0; | ||
|
|
||
| uintptr_t wqe_bb_idx_64 = ep->wqe_bb_idx; | ||
| uint32_t wqe_bb_idx_32 = ep->wqe_bb_idx; | ||
| size_t wqe_size; | ||
|
|
||
| wqe = (struct ibdevx_rw_wqe *)((char *)ep->wq_buf + | ||
| ((wqe_bb_idx_64 % get_ibdevx_qp_depth(ibdevx_state)) | ||
| << NVSHMEMT_IBDEVX_WQE_BB_SHIFT)); | ||
| wqe_size = sizeof(struct ibdevx_rw_wqe); | ||
| memset(wqe, 0, sizeof(struct ibdevx_rw_wqe)); | ||
|
|
||
| wqe->ctrl.fm_ce_se = MLX5_WQE_CTRL_CQ_UPDATE; | ||
| wqe->ctrl.qpn_ds = | ||
| htobe32((uint32_t)(wqe_size / NVSHMEMT_IBDEVX_MLX5_SEND_WQE_DS) | ep->qpid << 8); | ||
| wqe->ctrl.opmod_idx_opcode = htobe32(MLX5_OPCODE_RDMA_READ | (wqe_bb_idx_32 << 8)); | ||
|
|
||
| wqe->raddr.raddr = htobe64((uintptr_t)local_dummy_mr.mr->addr); | ||
| wqe->raddr.rkey = htobe32(local_dummy_mr.rkey); | ||
|
|
||
| wqe->data.data_seg.byte_count = htobe32((uint32_t)4); | ||
| wqe->data.data_seg.lkey = htobe32(local_dummy_mr.lkey); | ||
| wqe->data.data_seg.addr = htobe64((uintptr_t)local_dummy_mr.mr->addr); | ||
|
|
||
| assert(wqe_size <= MLX5_SEND_WQE_BB); | ||
| ep->wqe_bb_idx++; | ||
| nvshmemt_ibdevx_post_send(ep, (void *)wqe, 1); | ||
|
|
||
| status = nvshmemt_ib_common_check_poll_avail(tcurr, ep, NVSHMEMT_IB_COMMON_WAIT_ALL); | ||
| NVSHMEMI_NZ_ERROR_JMP(status, NVSHMEMX_ERROR_INTERNAL, out, "check_poll failed \n"); | ||
|
|
||
| out: | ||
| return status; | ||
| } | ||
|
|
||
| // Using common fence and quiet functions from transport_ib_common | ||
|
|
||
| int nvshmemt_ibdevx_ep_create(struct ibdevx_ep **ep, int devid, nvshmem_transport_t t, | ||
|
|
@@ -1932,7 +1892,6 @@ int nvshmemt_init(nvshmem_transport_t *t, struct nvshmemi_cuda_fn_table *table, | |
| transport->host_ops.finalize = nvshmemt_ibdevx_finalize; | ||
| transport->host_ops.show_info = nvshmemt_ibdevx_show_info; | ||
| transport->host_ops.progress = nvshmemt_ibdevx_progress; | ||
| transport->host_ops.enforce_cst = nvshmemt_ibdevx_enforce_cst_at_target; | ||
| transport->host_ops.put_signal = nvshmemt_put_signal; | ||
|
|
||
| transport->attr = NVSHMEM_TRANSPORT_ATTR_CONNECTED; | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is fine to remove since Power support is deprecated/removed.