From d3f3d08b5954e2cab538064bfd63622de2265a7d Mon Sep 17 00:00:00 2001 From: Brian Barrett Date: Wed, 4 May 2005 16:59:37 +0000 Subject: [PATCH] * dumb, minor changes - need to switch machines This commit was SVN r5592. --- src/mca/ptl/portals/ptl_portals.c | 39 +++++++++++++++++++-- src/mca/ptl/portals/ptl_portals.h | 23 ------------ src/mca/ptl/portals/ptl_portals_component.c | 6 ++-- src/mca/ptl/portals/ptl_portals_stubs.c | 16 --------- 4 files changed, 39 insertions(+), 45 deletions(-) diff --git a/src/mca/ptl/portals/ptl_portals.c b/src/mca/ptl/portals/ptl_portals.c index 629b2b9acd..9a896b158a 100644 --- a/src/mca/ptl/portals/ptl_portals.c +++ b/src/mca/ptl/portals/ptl_portals.c @@ -40,13 +40,13 @@ mca_ptl_portals_module_t mca_ptl_portals_module = { 0, /* exclusivity */ 0, /* latency */ 0, /* bandwidth */ - 0, /* ptl flags */ + MCA_PTL_PUT, /* ptl flags */ mca_ptl_portals_add_procs, mca_ptl_portals_del_procs, mca_ptl_portals_finalize, mca_ptl_portals_send, - NULL, + mca_ptl_portals_send, NULL, mca_ptl_portals_matched, mca_ptl_portals_request_init, @@ -112,6 +112,19 @@ mca_ptl_portals_add_procs(struct mca_ptl_base_module_t* ptl, } +int +mca_ptl_portals_del_procs(struct mca_ptl_base_module_t *ptl, + size_t nprocs, + struct ompi_proc_t **procs, + struct mca_ptl_base_peer_t **peers) +{ + /* yeah, I have no idea what to do here */ + + return OMPI_SUCCESS; +} + + + int mca_ptl_portals_module_enable(struct mca_ptl_portals_module_t *ptl, int enable) @@ -138,7 +151,6 @@ mca_ptl_portals_module_enable(struct mca_ptl_portals_module_t *ptl, ptl->frag_queues_created = true; } } - return OMPI_SUCCESS; } @@ -191,5 +203,26 @@ ptl_portals_new_frag_entry(struct mca_ptl_portals_module_t *ptl) return OMPI_ERROR; } + ompi_output_verbose(50, mca_ptl_portals_component.portals_output, + "new fragment added"); + + return OMPI_SUCCESS; +} + + +int +mca_ptl_portals_finalize(struct mca_ptl_base_module_t *ptl_base) +{ + struct mca_ptl_portals_module_t *ptl = + (struct mca_ptl_portals_module_t *) ptl_base; + int ret; + + ret = PtlNIFini(ptl->ni_handle); + if (PTL_OK != ret) { + ompi_output_verbose(50, mca_ptl_portals_component.portals_output, + "PtlNIFini returned %d\n", ret); + return OMPI_ERROR; + } + return OMPI_SUCCESS; } diff --git a/src/mca/ptl/portals/ptl_portals.h b/src/mca/ptl/portals/ptl_portals.h index 20dd4c4339..6d579db284 100644 --- a/src/mca/ptl/portals/ptl_portals.h +++ b/src/mca/ptl/portals/ptl_portals.h @@ -351,29 +351,6 @@ extern int mca_ptl_portals_send( ); -/** - * PML->PTL Continue sending fragments of a large message. - * - * @param ptl (IN) PTL instance - * @param ptl_base_peer (IN) PTL peer addressing - * @param request (IN) Send request - * @param offset Current offset into packed/contiguous buffer. - * @param size (IN) Number of bytes PML is requesting PTL to deliver, - * @param flags (IN) Flags that should be passed to the peer via the message header. - * @param request (OUT) OMPI_SUCCESS if the PTL was able to queue one or more fragments - * - */ - -extern int mca_ptl_portals_send_continue( - struct mca_ptl_base_module_t* ptl, - struct mca_ptl_base_peer_t* ptl_peer, - struct mca_pml_base_send_request_t*, - size_t offset, - size_t size, - int flags -); - - extern int mca_ptl_portals_module_enable(struct mca_ptl_portals_module_t *ptl, int value); extern int ptl_portals_new_frag_entry(struct mca_ptl_portals_module_t *ptl); diff --git a/src/mca/ptl/portals/ptl_portals_component.c b/src/mca/ptl/portals/ptl_portals_component.c index 31a062ee39..ac02bad3a9 100644 --- a/src/mca/ptl/portals/ptl_portals_component.c +++ b/src/mca/ptl/portals/ptl_portals_component.c @@ -192,12 +192,12 @@ mca_ptl_portals_component_init(int *num_ptls, mca_ptl_base_module_t** ptls; *num_ptls = 0; - /* BWB - no support for progress threads */ - if (enable_progress_threads || enable_mpi_threads) return NULL; - ompi_output_verbose(100, mca_ptl_portals_component.portals_output, "mca_ptl_portals_component_init()"); + /* BWB - no support for progress threads */ + if (enable_progress_threads) return NULL; + /* initialize portals ptl. note that this is in the compat code because it's fairly non-portable between implementations */ if (OMPI_SUCCESS != mca_ptl_portals_init(&mca_ptl_portals_component)) { diff --git a/src/mca/ptl/portals/ptl_portals_stubs.c b/src/mca/ptl/portals/ptl_portals_stubs.c index 400839620c..48a62557de 100644 --- a/src/mca/ptl/portals/ptl_portals_stubs.c +++ b/src/mca/ptl/portals/ptl_portals_stubs.c @@ -30,22 +30,6 @@ * BWB - README - BWB - README - BWB - README - BWB - README - BWB */ -int -mca_ptl_portals_finalize(struct mca_ptl_base_module_t *ptl) -{ - return OMPI_ERROR; -} - - -int -mca_ptl_portals_del_procs(struct mca_ptl_base_module_t *ptl, - size_t nprocs, - struct ompi_proc_t **procs, - struct mca_ptl_base_peer_t **peers) -{ - return OMPI_ERROR; -} - int mca_ptl_portals_request_init(struct mca_ptl_base_module_t *ptl,