@@ -52,15 +52,17 @@ class nixlAgent {
5252
5353 /* It is unsafe to move nixlAgent object */
5454 nixlAgent (nixlAgent &&) noexcept = delete ;
55- nixlAgent &operator =(nixlAgent &&) noexcept = delete ;
55+ nixlAgent &
56+ operator =(nixlAgent &&) noexcept = delete ;
5657
5758 /* *
5859 * @brief Discover the available supported plugins found in the plugin paths
5960 *
6061 * @param plugins [out] Vector of available backend plugins
6162 * @return nixl_status_t Error code if call was not successful
6263 */
63- nixl_status_t getAvailPlugins (std::vector<nixl_backend_t > &plugins);
64+ nixl_status_t
65+ getAvailPlugins (std::vector<nixl_backend_t > &plugins);
6466
6567 /* *
6668 * @brief Get the supported memory types, and init config parameters and their
@@ -71,9 +73,10 @@ class nixlAgent {
7173 * @param params [out] List of init parameters and their values for the plugin
7274 * @return nixl_status_t Error code if call was not successful
7375 */
74- nixl_status_t getPluginParams (const nixl_backend_t &type,
75- nixl_mem_list_t &mems,
76- nixl_b_params_t ¶ms) const ;
76+ nixl_status_t
77+ getPluginParams (const nixl_backend_t &type,
78+ nixl_mem_list_t &mems,
79+ nixl_b_params_t ¶ms) const ;
7780 /* *
7881 * @brief Get the backend parameters after instantiation. This will be a comprehensive
7982 * list, for instance the default values used for parameters that were not
@@ -84,9 +87,10 @@ class nixlAgent {
8487 * @param params [out] List of init parameters and their values for the backend
8588 * @return nixl_status_t Error code if call was not successful
8689 */
87- nixl_status_t getBackendParams (const nixlBackendH* backend,
88- nixl_mem_list_t &mems,
89- nixl_b_params_t ¶ms) const ;
90+ nixl_status_t
91+ getBackendParams (const nixlBackendH *backend,
92+ nixl_mem_list_t &mems,
93+ nixl_b_params_t ¶ms) const ;
9094
9195 /* *
9296 * @brief Instantiate a backend engine object based on the corresponding parameters
@@ -97,7 +101,9 @@ class nixlAgent {
97101 * @return nixl_status_t Error code if call was not successful
98102 */
99103 nixl_status_t
100- createBackend (const nixl_backend_t &type, const nixl_b_params_t ¶ms, nixlBackendH*&backend);
104+ createBackend (const nixl_backend_t &type,
105+ const nixl_b_params_t ¶ms,
106+ nixlBackendH *&backend);
101107 /* *
102108 * @brief Register a memory/storage with NIXL. If a list of backends hints is provided
103109 * (via extra_params), the registration is limited to the specified backends.
@@ -106,8 +112,8 @@ class nixlAgent {
106112 * @param extra_params Optional additional parameters used in registering memory
107113 * @return nixl_status_t Error code if call was not successful
108114 */
109- nixl_status_t registerMem ( const nixl_reg_dlist_t &descs,
110- const nixl_opt_args_t * extra_params = nullptr );
115+ nixl_status_t
116+ registerMem ( const nixl_reg_dlist_t &descs, const nixl_opt_args_t * extra_params = nullptr );
111117
112118 /* *
113119 * @brief Deregister a memory/storage from NIXL. If a list of backends hints is provided
@@ -118,8 +124,8 @@ class nixlAgent {
118124 * @param extra_params Optional additional parameters used in deregistering memory
119125 * @return nixl_status_t Error code if call was not successful
120126 */
121- nixl_status_t deregisterMem ( const nixl_reg_dlist_t &descs,
122- const nixl_opt_args_t * extra_params = nullptr );
127+ nixl_status_t
128+ deregisterMem ( const nixl_reg_dlist_t &descs, const nixl_opt_args_t * extra_params = nullptr );
123129
124130 /* *
125131 * @brief Make connection proactively, instead of at the time of the first transfer
@@ -129,8 +135,8 @@ class nixlAgent {
129135 * @param remote_agent Name of the remote agent
130136 * @return nixl_status_t Error code if call was not successful
131137 */
132- nixl_status_t makeConnection ( const std::string &remote_agent,
133- const nixl_opt_args_t * extra_params = nullptr );
138+ nixl_status_t
139+ makeConnection ( const std::string &remote_agent, const nixl_opt_args_t * extra_params = nullptr );
134140
135141 /* ** Transfer Request Preparation ***/
136142 /* *
@@ -154,10 +160,11 @@ class nixlAgent {
154160 * @param extra_params Optional additional parameters used in preparing dlist handle
155161 * @return nixl_status_t Error code if call was not successful
156162 */
157- nixl_status_t prepXferDlist (const std::string &agent_name,
158- const nixl_xfer_dlist_t &descs,
159- nixlDlistH*&dlist_hndl,
160- const nixl_opt_args_t * extra_params = nullptr ) const ;
163+ nixl_status_t
164+ prepXferDlist (const std::string &agent_name,
165+ const nixl_xfer_dlist_t &descs,
166+ nixlDlistH *&dlist_hndl,
167+ const nixl_opt_args_t *extra_params = nullptr ) const ;
161168 /* *
162169 * @brief Make a transfer request `req_handl` by selecting indices from already
163170 * prepared descriptor list handles. NIXL automatically determines the backend
@@ -174,13 +181,14 @@ class nixlAgent {
174181 * @param extra_params Optional additional parameters used in making a transfer request
175182 * @return nixl_status_t Error code if call was not successful
176183 */
177- nixl_status_t makeXferReq (const nixl_xfer_op_t &operation,
178- const nixlDlistH* local_side,
179- const std::vector<int > &local_indices,
180- const nixlDlistH* remote_side,
181- const std::vector<int > &remote_indices,
182- nixlXferReqH*&req_hndl,
183- const nixl_opt_args_t * extra_params = nullptr ) const ;
184+ nixl_status_t
185+ makeXferReq (const nixl_xfer_op_t &operation,
186+ const nixlDlistH *local_side,
187+ const std::vector<int > &local_indices,
188+ const nixlDlistH *remote_side,
189+ const std::vector<int > &remote_indices,
190+ nixlXferReqH *&req_hndl,
191+ const nixl_opt_args_t *extra_params = nullptr ) const ;
184192 /* *
185193 * @brief A combined API, to create a transfer request from two descriptor lists.
186194 * NIXL will prepare each side and create a transfer handle `req_hndl`.
@@ -210,12 +218,13 @@ class nixlAgent {
210218 * @param extra_params Optional extra parameters used in creating a transfer request
211219 * @return nixl_status_t Error code if call was not successful
212220 */
213- nixl_status_t createXferReq (const nixl_xfer_op_t &operation,
214- const nixl_xfer_dlist_t &local_descs,
215- const nixl_xfer_dlist_t &remote_descs,
216- const std::string &remote_agent,
217- nixlXferReqH*&req_hndl,
218- const nixl_opt_args_t * extra_params = nullptr ) const ;
221+ nixl_status_t
222+ createXferReq (const nixl_xfer_op_t &operation,
223+ const nixl_xfer_dlist_t &local_descs,
224+ const nixl_xfer_dlist_t &remote_descs,
225+ const std::string &remote_agent,
226+ nixlXferReqH *&req_hndl,
227+ const nixl_opt_args_t *extra_params = nullptr ) const ;
219228
220229 /* ** Operations on prepared Transfer Request ***/
221230
@@ -231,16 +240,17 @@ class nixlAgent {
231240 * @param extra_params Optional extra parameters used in posting a transfer request
232241 * @return nixl_status_t NIXL_IN_PROG or error code if call was not successful
233242 */
234- nixl_status_t postXferReq (nixlXferReqH* req_hndl,
235- const nixl_opt_args_t * extra_params = nullptr ) const ;
243+ nixl_status_t
244+ postXferReq (nixlXferReqH *req_hndl, const nixl_opt_args_t * extra_params = nullptr ) const ;
236245
237246 /* *
238247 * @brief Check the status of transfer request `req_hndl`
239248 *
240249 * @param req_hndl Transfer request handle after postXferReq
241250 * @return nixl_status_t NIXL_IN_PROG or error code if call was not successful
242251 */
243- nixl_status_t getXferStatus (nixlXferReqH* req_hndl) const ;
252+ nixl_status_t
253+ getXferStatus (nixlXferReqH *req_hndl) const ;
244254
245255 /* *
246256 * @brief Query the backend associated with `req_hndl`. E.g., if for genNotif
@@ -250,7 +260,8 @@ class nixlAgent {
250260 * @param backend [out] Output backend handle chosen for the transfer request
251261 * @return nixl_status_t Error code if call was not successful
252262 */
253- nixl_status_t queryXferBackend (const nixlXferReqH* req_hndl, nixlBackendH*&backend) const ;
263+ nixl_status_t
264+ queryXferBackend (const nixlXferReqH *req_hndl, nixlBackendH *&backend) const ;
254265
255266 /* *
256267 * @brief Release the transfer request `req_hndl`. If the transfer is active,
@@ -259,15 +270,17 @@ class nixlAgent {
259270 * @param req_hndl Transfer request handle to be released
260271 * @return nixl_status_t Error code if call was not successful
261272 */
262- nixl_status_t releaseXferReq (nixlXferReqH* req_hndl) const ;
273+ nixl_status_t
274+ releaseXferReq (nixlXferReqH *req_hndl) const ;
263275
264276 /* *
265277 * @brief Release the prepared descriptor list handle `dlist_hndl`
266278 *
267279 * @param dlist_hndl Prepared descriptor list handle to be released
268280 * @return nixl_status_t Error code if call was not successful
269281 */
270- nixl_status_t releasedDlistH (nixlDlistH* dlist_hndl) const ;
282+ nixl_status_t
283+ releasedDlistH (nixlDlistH *dlist_hndl) const ;
271284
272285
273286 /* ** Notification Handling ***/
@@ -282,8 +295,8 @@ class nixlAgent {
282295 * @param extra_params Optional extra parameters used in getting notifications
283296 * @return nixl_status_t Error code if call was not successful
284297 */
285- nixl_status_t getNotifs ( nixl_notifs_t ¬if_map,
286- const nixl_opt_args_t * extra_params = nullptr );
298+ nixl_status_t
299+ getNotifs ( nixl_notifs_t ¬if_map, const nixl_opt_args_t * extra_params = nullptr );
287300
288301 /* *
289302 * @brief Generate a notification, not bound to a transfer, e.g., for control.
@@ -297,9 +310,10 @@ class nixlAgent {
297310 * @param extra_params Optional extra parameters used in generating a standalone notif
298311 * @return nixl_status_t Error code if call was not successful
299312 */
300- nixl_status_t genNotif (const std::string &remote_agent,
301- const nixl_blob_t &msg,
302- const nixl_opt_args_t * extra_params = nullptr ) const ;
313+ nixl_status_t
314+ genNotif (const std::string &remote_agent,
315+ const nixl_blob_t &msg,
316+ const nixl_opt_args_t *extra_params = nullptr ) const ;
303317
304318 /* ** Metadata handling through side channel ***/
305319 /* *
@@ -308,7 +322,8 @@ class nixlAgent {
308322 * @param str [out] The serialized metadata blob
309323 * @return nixl_status_t Error code if call was not successful
310324 */
311- nixl_status_t getLocalMD (nixl_blob_t &str) const ;
325+ nixl_status_t
326+ getLocalMD (nixl_blob_t &str) const ;
312327
313328 /* *
314329 * @brief Get partial metadata blob for this agent, to be given to other agents.
@@ -325,9 +340,10 @@ class nixlAgent {
325340 * @param extra_params [in] Optional extra parameters used in getting partial metadata
326341 * @return nixl_status_t Error code if call was not successful
327342 */
328- nixl_status_t getLocalPartialMD (const nixl_reg_dlist_t &descs,
329- nixl_blob_t &str,
330- const nixl_opt_args_t * extra_params = nullptr ) const ;
343+ nixl_status_t
344+ getLocalPartialMD (const nixl_reg_dlist_t &descs,
345+ nixl_blob_t &str,
346+ const nixl_opt_args_t *extra_params = nullptr ) const ;
331347
332348 /* *
333349 * @brief Load other agent's metadata and unpack it internally. Now the local
@@ -337,7 +353,8 @@ class nixlAgent {
337353 * @param agent_name [out] Agent name extracted from the loaded metadata blob
338354 * @return nixl_status_t Error code if call was not successful
339355 */
340- nixl_status_t loadRemoteMD (const nixl_blob_t &remote_metadata, std::string &agent_name);
356+ nixl_status_t
357+ loadRemoteMD (const nixl_blob_t &remote_metadata, std::string &agent_name);
341358
342359 /* *
343360 * @brief Invalidate the remote agent metadata cached locally. This will
@@ -347,7 +364,8 @@ class nixlAgent {
347364 * @param remote_agent Remote agent name to invalidate its metadata blob
348365 * @return nixl_status_t Error code if call was not successful
349366 */
350- nixl_status_t invalidateRemoteMD (const std::string &remote_agent);
367+ nixl_status_t
368+ invalidateRemoteMD (const std::string &remote_agent);
351369
352370 /* ** Metadata handling through direct channels (p2p socket and ETCD) ***/
353371 /* *
@@ -360,7 +378,8 @@ class nixlAgent {
360378 *
361379 * @return nixl_status_t Error code if call was not successful
362380 */
363- nixl_status_t sendLocalMD (const nixl_opt_args_t * extra_params = nullptr ) const ;
381+ nixl_status_t
382+ sendLocalMD (const nixl_opt_args_t *extra_params = nullptr ) const ;
364383
365384 /* *
366385 * @brief Send partial metadata blob for this agent to peer or central metadata server
@@ -382,8 +401,9 @@ class nixlAgent {
382401 * @param extra_params [in] Optional extra parameters used in getting partial metadata
383402 * @return nixl_status_t Error code if call was not successful
384403 */
385- nixl_status_t sendLocalPartialMD (const nixl_reg_dlist_t &descs,
386- const nixl_opt_args_t * extra_params = nullptr ) const ;
404+ nixl_status_t
405+ sendLocalPartialMD (const nixl_reg_dlist_t &descs,
406+ const nixl_opt_args_t *extra_params = nullptr ) const ;
387407
388408 /* *
389409 * @brief Fetch other agent's metadata and unpack it internally.
@@ -399,8 +419,8 @@ class nixlAgent {
399419 *
400420 * @return nixl_status_t Error code if call was not successful
401421 */
402- nixl_status_t fetchRemoteMD ( const std::string remote_name,
403- const nixl_opt_args_t * extra_params = nullptr );
422+ nixl_status_t
423+ fetchRemoteMD ( const std::string remote_name, const nixl_opt_args_t * extra_params = nullptr );
404424
405425 /* *
406426 * @brief Invalidate your own memory in one/all remote agent(s).
@@ -412,7 +432,8 @@ class nixlAgent {
412432 *
413433 * @return nixl_status_t Error code if call was not successful
414434 */
415- nixl_status_t invalidateLocalMD (const nixl_opt_args_t * extra_params = nullptr ) const ;
435+ nixl_status_t
436+ invalidateLocalMD (const nixl_opt_args_t *extra_params = nullptr ) const ;
416437
417438 /* *
418439 * @brief Check if metadata is available for a remote agent.
@@ -422,8 +443,8 @@ class nixlAgent {
422443 * @param str Remote agent to check for
423444 * @return nixl_status_t Error code, NOT_FOUND if metadata not found
424445 */
425- nixl_status_t checkRemoteMD ( const std::string remote_name,
426- const nixl_xfer_dlist_t &descs) const ;
446+ nixl_status_t
447+ checkRemoteMD ( const std::string remote_name, const nixl_xfer_dlist_t &descs) const ;
427448};
428449
429450#endif
0 commit comments