1
1

merge in scheduling changes from release branch

This commit was SVN r7699.
Этот коммит содержится в:
Tim Woodall 2005-10-11 20:41:51 +00:00
родитель c8adc2e65e
Коммит 4a71621410
3 изменённых файлов: 9 добавлений и 9 удалений

Просмотреть файл

@ -48,8 +48,8 @@ struct mca_mpool_base_resources_t;
struct mca_bml_base_btl_t {
int btl_index; /**< index in endpoint array */
int btl_weight; /**< BTL weight for scheduling */
int btl_flags; /**< support for put/get? */
double btl_weight; /**< BTL weight for scheduling */
size_t btl_eager_limit; /**< BTL eager limit */
size_t btl_min_send_size; /**< BTL min send size */
size_t btl_max_send_size; /**< BTL max send size */

Просмотреть файл

@ -347,15 +347,13 @@ int mca_bml_r2_add_procs(
mca_bml_base_btl_t* bml_btl =
mca_bml_base_btl_array_get_index(&bml_endpoint->btl_send, n_index);
mca_btl_base_module_t *btl = bml_btl->btl;
double weight;
/* compute weighting factor for this r2 */
if(btl->btl_bandwidth > 0) {
weight = btl->btl_bandwidth / total_bandwidth;
bml_btl->btl_weight = btl->btl_bandwidth / total_bandwidth;
} else {
weight = 1.0 / n_size;
bml_btl->btl_weight = 1.0 / n_size;
}
bml_btl->btl_weight = (int)(weight * 100);
/* check to see if this r2 is already in the array of r2s
* used for first fragments - if not add it.

Просмотреть файл

@ -606,7 +606,7 @@ void mca_pml_ob1_recv_request_schedule(mca_pml_ob1_recv_request_t* recvreq)
mca_btl_base_descriptor_t* dst;
mca_btl_base_descriptor_t* ctl;
mca_mpool_base_registration_t * reg = NULL;
size_t num_btl_avail = recvreq->req_rdma_cnt;
size_t num_btl_avail;
int rc;
if(recvreq->req_rdma_cnt) {
@ -616,11 +616,12 @@ void mca_pml_ob1_recv_request_schedule(mca_pml_ob1_recv_request_t* recvreq)
* memory.
*/
bml_btl = recvreq->req_rdma[recvreq->req_rdma_idx].bml_btl;
num_btl_avail = recvreq->req_rdma_cnt;
reg = recvreq->req_rdma[recvreq->req_rdma_idx].btl_reg;
if(++recvreq->req_rdma_idx >= recvreq->req_rdma_cnt)
recvreq->req_rdma_idx = 0;
if(recvreq->req_rdma_cnt == 1 || bytes_remaining < bml_btl->btl_min_rdma_size) {
if(num_btl_avail == 1 || bytes_remaining < bml_btl->btl_min_rdma_size) {
size = bytes_remaining;
/* otherwise attempt to give the BTL a percentage of the message
@ -629,7 +630,7 @@ void mca_pml_ob1_recv_request_schedule(mca_pml_ob1_recv_request_t* recvreq)
* previously assigned)
*/
} else {
size = (bml_btl->btl_weight * bytes_remaining) / 100;
size = (size_t)(bml_btl->btl_weight * bytes_remaining);
}
} else {
@ -639,6 +640,7 @@ void mca_pml_ob1_recv_request_schedule(mca_pml_ob1_recv_request_t* recvreq)
* available RDMA nics dynamically registering/deregister
* as required.
*/
num_btl_avail = mca_bml_base_btl_array_get_size(&bml_endpoint->btl_rdma);
bml_btl = mca_bml_base_btl_array_get_next(&bml_endpoint->btl_rdma);
/* if there is only one btl available or the size is less than
@ -653,7 +655,7 @@ void mca_pml_ob1_recv_request_schedule(mca_pml_ob1_recv_request_t* recvreq)
* previously assigned)
*/
} else {
size = (bml_btl->btl_weight * bytes_remaining) / 100;
size = (size_t)(bml_btl->btl_weight * bytes_remaining);
}
/* makes sure that we don't exceed BTL max rdma size */