Zoltan_LoadBalance.cpp

Go to the documentation of this file.
00001 //-------------------------------------------------------------------------
00002 // Copyright Notice
00003 //
00004 // Copyright (c) 2000, Sandia Corporation, Albuquerque, NM.
00005 //-------------------------------------------------------------------------
00006 
00007 //-------------------------------------------------------------------------
00008 // Filename       : $Zoltan_LoadBalance.C$
00009 //
00010 // Purpose        : C++ wrapper object for Zoltan Load Balance Routines.
00011 //
00012 // Special Notes  :
00013 //
00014 // Creator        : Robert J. Hoekstra, Parallel Computational Sciences
00015 //
00016 // Creation Date  : 08/04/2000
00017 //
00018 // Revision Information:
00019 // ---------------------
00020 //
00021 // Revision Number: $$
00022 //
00023 // Revision Date  : $$
00024 //
00025 // Current Owner  : $$
00026 //-------------------------------------------------------------------------
00027 
00028 #include <Zoltan_LoadBalance.h>
00029 #include <Zoltan_QueryContainer.h>
00030 #include <Zoltan_QueryFunctions.h>
00031 #include <Zoltan_MigrationContainer.h>
00032 #include <Zoltan_MigrationFunctions.h>
00033 
00034 int Zoltan::LoadBalance::ObjectCount = 0;
00035 
00036 Zoltan::LoadBalance::LoadBalance( int argc,
00037                                   char ** argv,
00038                                   float * ver )
00039   : ObjectID( 0 ),
00040     LoadBalance_Ptr_( 0 ),
00041     QueryObject_Ptr_( 0 ),
00042     MigrationObject_Ptr_( 0 )
00043 {
00044   ObjectID = ObjectCount++;
00045 
00046   int tmpReturn = Zoltan_Initialize( argc, argv, ver );
00047 }
00048 
00049 Zoltan::LoadBalance::~LoadBalance()
00050 {
00051   Zoltan_Destroy( &LoadBalance_Ptr_ );
00052 }
00053 
00054  //Load Balance Calls
00055 int Zoltan::LoadBalance::Create( MPI_Comm communicator )
00056 {
00057   LoadBalance_Ptr_ = Zoltan_Create( communicator );
00058 
00059   if( !LoadBalance_Ptr_ )
00060     return ZOLTAN_FATAL;
00061   else
00062     return ZOLTAN_OK;
00063 }
00064 
00065 #ifdef ZOLTAN_OLD_CALLBACK
00066 
00067 //Old callback support
00068 //--------------------------------
00069 
00070 int Zoltan::LoadBalance::Set_CallBack_Fn       ( ZOLTAN_FN_TYPE fn_type,
00071              void * fn_ptr,
00072              void * data )
00073 {
00074   return Zoltan_Set_Fn( LoadBalance_Ptr_, fn_type, fn_ptr, data );
00075 }
00076 
00077 #else /* ZOLTAN_OLD_CALLBACK */
00078 
00079 //Individual callback registration
00080 //--------------------------------
00081 
00082 int Zoltan::LoadBalance::Set_Num_Edges_Fn      ( ZOLTAN_NUM_EDGES_FN * fn_ptr,
00083              void * data )
00084 {
00085   return Zoltan_Set_Num_Edges_Fn( LoadBalance_Ptr_, fn_ptr, data );
00086 }
00087 
00088 int Zoltan::LoadBalance::Set_Edge_List_Fn      (  ZOLTAN_EDGE_LIST_FN * fn_ptr,
00089             void * data )
00090 {
00091   return Zoltan_Set_Edge_List_Fn( LoadBalance_Ptr_, fn_ptr, data );
00092 }
00093 
00094 int Zoltan::LoadBalance::Set_Num_Geom_Fn      ( ZOLTAN_NUM_GEOM_FN * fn_ptr,
00095             void * data )
00096 {
00097   return Zoltan_Set_Num_Geom_Fn( LoadBalance_Ptr_, fn_ptr, data );
00098 }
00099 
00100 int Zoltan::LoadBalance::Set_Geom_Fn      ( ZOLTAN_GEOM_FN * fn_ptr,
00101             void * data )
00102 {
00103   return Zoltan_Set_Geom_Fn( LoadBalance_Ptr_, fn_ptr, data );
00104 }
00105 
00106 int Zoltan::LoadBalance::Set_Num_Obj_Fn      (  ZOLTAN_NUM_OBJ_FN * fn_ptr,
00107             void * data )
00108 {
00109   return Zoltan_Set_Num_Obj_Fn( LoadBalance_Ptr_, fn_ptr, data );
00110 }
00111 
00112 int Zoltan::LoadBalance::Set_Obj_List_Fn      ( ZOLTAN_OBJ_LIST_FN * fn_ptr,
00113             void * data )
00114 {
00115   return Zoltan_Set_Obj_List_Fn( LoadBalance_Ptr_, fn_ptr, data );
00116 }
00117 
00118 int Zoltan::LoadBalance::Set_First_Obj_Fn      (  ZOLTAN_FIRST_OBJ_FN * fn_ptr,
00119             void * data )
00120 {
00121   return Zoltan_Set_First_Obj_Fn( LoadBalance_Ptr_, fn_ptr, data );
00122 }
00123 
00124 int Zoltan::LoadBalance::Set_Next_Obj_Fn      ( ZOLTAN_NEXT_OBJ_FN * fn_ptr,
00125             void * data )
00126 {
00127   return Zoltan_Set_Next_Obj_Fn( LoadBalance_Ptr_, fn_ptr, data );
00128 }
00129 
00130 int Zoltan::LoadBalance::Set_Num_Border_Obj_Fn (  ZOLTAN_NUM_BORDER_OBJ_FN * fn_ptr,
00131             void * data )
00132 {
00133   return Zoltan_Set_Num_Border_Obj_Fn( LoadBalance_Ptr_, fn_ptr, data );
00134 }
00135 
00136 int Zoltan::LoadBalance::Set_Border_Obj_List_Fn ( ZOLTAN_BORDER_OBJ_LIST_FN * fn_ptr,
00137             void * data )
00138 {
00139   return Zoltan_Set_Border_Obj_List_Fn( LoadBalance_Ptr_, fn_ptr, data );
00140 }
00141 
00142 int Zoltan::LoadBalance::Set_First_Border_Obj_Fn ( ZOLTAN_FIRST_BORDER_OBJ_FN * fn_ptr,
00143             void * data )
00144 {
00145   return Zoltan_Set_First_Border_Obj_Fn( LoadBalance_Ptr_, fn_ptr, data );
00146 }
00147 
00148 int Zoltan::LoadBalance::Set_Next_Border_Obj_Fn ( ZOLTAN_NEXT_BORDER_OBJ_FN * fn_ptr,
00149             void * data )
00150 {
00151   return Zoltan_Set_Next_Border_Obj_Fn( LoadBalance_Ptr_, fn_ptr, data );
00152 }
00153 
00154 int Zoltan::LoadBalance::Set_Num_Coarse_Obj_Fn (  ZOLTAN_NUM_COARSE_OBJ_FN * fn_ptr,
00155             void * data )
00156 {
00157   return Zoltan_Set_Num_Coarse_Obj_Fn( LoadBalance_Ptr_, fn_ptr, data );
00158 }
00159 
00160 int Zoltan::LoadBalance::Set_Coarse_Obj_List_Fn ( ZOLTAN_COARSE_OBJ_LIST_FN * fn_ptr,
00161             void * data )
00162 {
00163   return Zoltan_Set_Coarse_Obj_List_Fn( LoadBalance_Ptr_, fn_ptr, data );
00164 }
00165 
00166 int Zoltan::LoadBalance::Set_First_Coarse_Obj_Fn ( ZOLTAN_FIRST_COARSE_OBJ_FN * fn_ptr,
00167             void * data )
00168 {
00169   return Zoltan_Set_First_Coarse_Obj_Fn( LoadBalance_Ptr_, fn_ptr, data );
00170 }
00171 
00172 int Zoltan::LoadBalance::Set_Next_Coarse_Obj_Fn ( ZOLTAN_NEXT_COARSE_OBJ_FN * fn_ptr,
00173             void * data )
00174 {
00175   return Zoltan_Set_Next_Coarse_Obj_Fn( LoadBalance_Ptr_, fn_ptr, data );
00176 }
00177 
00178 int Zoltan::LoadBalance::Set_Num_Child_Fn      (  ZOLTAN_NUM_CHILD_FN * fn_ptr,
00179             void * data )
00180 {
00181   return Zoltan_Set_Num_Child_Fn( LoadBalance_Ptr_, fn_ptr, data );
00182 }
00183 
00184 int Zoltan::LoadBalance::Set_Child_List_Fn ( ZOLTAN_CHILD_LIST_FN * fn_ptr,
00185             void * data )
00186 {
00187   return Zoltan_Set_Child_List_Fn( LoadBalance_Ptr_, fn_ptr, data );
00188 }
00189 
00190 int Zoltan::LoadBalance::Set_Child_Weight_Fn ( ZOLTAN_CHILD_WEIGHT_FN * fn_ptr,
00191             void * data )
00192 {
00193   return Zoltan_Set_Child_Weight_Fn( LoadBalance_Ptr_, fn_ptr, data );
00194 }
00195 
00196 int Zoltan::LoadBalance::Set_Pre_Migrate_Fn    (  ZOLTAN_PRE_MIGRATE_FN * fn_ptr,
00197             void * data )
00198 {
00199   return Zoltan_Set_Pre_Migrate_Fn( LoadBalance_Ptr_, fn_ptr, data );
00200 }
00201 
00202 int Zoltan::LoadBalance::Set_Mid_Migrate_Fn    (  ZOLTAN_MID_MIGRATE_FN * fn_ptr,
00203             void * data )
00204 {
00205   return Zoltan_Set_Mid_Migrate_Fn( LoadBalance_Ptr_, fn_ptr, data );
00206 }
00207 
00208 int Zoltan::LoadBalance::Set_Post_Migrate_Fn   (  ZOLTAN_POST_MIGRATE_FN * fn_ptr,
00209             void * data )
00210 {
00211   return Zoltan_Set_Post_Migrate_Fn( LoadBalance_Ptr_, fn_ptr, data );
00212 }
00213 
00214 int Zoltan::LoadBalance::Set_Obj_Size_Fn       (  ZOLTAN_OBJ_SIZE_FN * fn_ptr,
00215             void * data )
00216 {
00217   return Zoltan_Set_Obj_Size_Fn( LoadBalance_Ptr_, fn_ptr, data );
00218 }
00219 
00220 int Zoltan::LoadBalance::Set_Pack_Obj_Fn       (  ZOLTAN_PACK_OBJ_FN * fn_ptr,
00221             void * data )
00222 {
00223   return Zoltan_Set_Pack_Obj_Fn( LoadBalance_Ptr_, fn_ptr, data );
00224 }
00225 
00226 int Zoltan::LoadBalance::Set_Unpack_Obj_Fn     (  ZOLTAN_UNPACK_OBJ_FN * fn_ptr,
00227             void * data )
00228 {
00229   return Zoltan_Set_Unpack_Obj_Fn( LoadBalance_Ptr_, fn_ptr, data );
00230 }
00231 
00232 #endif /* ZOLTAN_OLD_CALLBACK */
00233 
00234 int Zoltan::LoadBalance::Set_QueryObject( Zoltan::QueryObject * query_obj_ptr )
00235 {
00236   Zoltan::QueryContainer::registerQueryObject( ObjectID, query_obj_ptr );
00237 
00238 #ifdef ZOLTAN_OLD_CALLBACK
00239 
00240   //LB_Set_Fn all Cstyle Functions
00241   Set_CallBack_Fn( ZOLTAN_NUM_EDGES_FN_TYPE,
00242   reinterpret_cast<void *> (Zoltan::QueryFunctions::Number_Edges),
00243   0 );
00244   Set_CallBack_Fn( ZOLTAN_EDGE_LIST_FN_TYPE,
00245   reinterpret_cast<void *> (Zoltan::QueryFunctions::Edge_List),
00246   0 );
00247   Set_CallBack_Fn( ZOLTAN_NUM_GEOM_FN_TYPE,
00248     reinterpret_cast<void *> (Zoltan::QueryFunctions::Number_Geometry_Objects),
00249   0 );
00250   Set_CallBack_Fn( ZOLTAN_GEOM_FN_TYPE,
00251   reinterpret_cast<void *> (Zoltan::QueryFunctions::Geometry_Values),
00252   0 );
00253   Set_CallBack_Fn( ZOLTAN_NUM_OBJ_FN_TYPE, 
00254   reinterpret_cast<void *> (Zoltan::QueryFunctions::Number_Objects),
00255   0 );
00256   Set_CallBack_Fn( ZOLTAN_OBJ_LIST_FN_TYPE,
00257   reinterpret_cast<void *> (Zoltan::QueryFunctions::Object_List),
00258   0 );
00259   Set_CallBack_Fn( ZOLTAN_FIRST_OBJ_FN_TYPE,
00260   reinterpret_cast<void *> (Zoltan::QueryFunctions::First_Object),
00261   0 );
00262   Set_CallBack_Fn( ZOLTAN_NEXT_OBJ_FN_TYPE,
00263   reinterpret_cast<void *> (Zoltan::QueryFunctions::Next_Object),
00264   0 );
00265   Set_CallBack_Fn( ZOLTAN_NUM_BORDER_OBJ_FN_TYPE,
00266   reinterpret_cast<void *> (Zoltan::QueryFunctions::Number_Border_Objects),
00267   0 );
00268   Set_CallBack_Fn( ZOLTAN_BORDER_OBJ_LIST_FN_TYPE,
00269   reinterpret_cast<void *> (Zoltan::QueryFunctions::Border_Object_List),
00270   0 );
00271   Set_CallBack_Fn( ZOLTAN_FIRST_BORDER_OBJ_FN_TYPE,
00272   reinterpret_cast<void *> (Zoltan::QueryFunctions::First_Border_Object),
00273   0 );
00274   Set_CallBack_Fn( ZOLTAN_NEXT_BORDER_OBJ_FN_TYPE,
00275   reinterpret_cast<void *> (Zoltan::QueryFunctions::Next_Border_Object),
00276   0 );
00277   Set_CallBack_Fn( ZOLTAN_NUM_COARSE_OBJ_FN_TYPE,
00278   reinterpret_cast<void *> (Zoltan::QueryFunctions::Number_Coarse_Objects),
00279   0 );
00280   Set_CallBack_Fn( ZOLTAN_COARSE_OBJ_LIST_FN_TYPE,
00281   reinterpret_cast<void *> (Zoltan::QueryFunctions::Coarse_Object_List),
00282   0 );
00283   Set_CallBack_Fn( ZOLTAN_FIRST_COARSE_OBJ_FN_TYPE,
00284   reinterpret_cast<void *> (Zoltan::QueryFunctions::First_Coarse_Object),
00285   0 );
00286   Set_CallBack_Fn( ZOLTAN_NEXT_COARSE_OBJ_FN_TYPE,
00287   reinterpret_cast<void *> (Zoltan::QueryFunctions::Next_Coarse_Object),
00288   0 );
00289   Set_CallBack_Fn( ZOLTAN_NUM_CHILD_FN_TYPE,
00290   reinterpret_cast<void *> (Zoltan::QueryFunctions::Number_Children),
00291   0 );
00292   Set_CallBack_Fn( ZOLTAN_CHILD_LIST_FN_TYPE,
00293   reinterpret_cast<void *> (Zoltan::QueryFunctions::Child_List),
00294   0 );
00295   Set_CallBack_Fn( ZOLTAN_CHILD_WEIGHT_FN_TYPE,
00296   reinterpret_cast<void *> (Zoltan::QueryFunctions::Child_Weight),
00297   0 );
00298 
00299 #else /* ZOLTAN_OLD_CALLBACK */
00300 
00301   Set_Num_Edges_Fn        ( Zoltan::QueryFunctions::Number_Edges,
00302                             0 );
00303   Set_Edge_List_Fn        ( Zoltan::QueryFunctions::Edge_List,
00304                             0 );
00305   Set_Num_Geom_Fn         ( Zoltan::QueryFunctions::Number_Geometry_Objects,
00306                             0 );
00307   Set_Geom_Fn             ( Zoltan::QueryFunctions::Geometry_Values,
00308                             0 );
00309   Set_Num_Obj_Fn          ( Zoltan::QueryFunctions::Number_Objects,
00310                             0 );
00311   Set_Obj_List_Fn         ( Zoltan::QueryFunctions::Object_List,
00312                             0 );
00313   Set_First_Obj_Fn        ( Zoltan::QueryFunctions::First_Object,
00314                             0 );
00315   Set_Next_Obj_Fn         ( Zoltan::QueryFunctions::Next_Object,
00316                             0 );
00317   Set_Num_Border_Obj_Fn   ( Zoltan::QueryFunctions::Number_Border_Objects,
00318                             0 );
00319   Set_Border_Obj_List_Fn  ( Zoltan::QueryFunctions::Border_Object_List,
00320                             0 );
00321   Set_First_Border_Obj_Fn ( Zoltan::QueryFunctions::First_Border_Object,
00322                             0 );
00323   Set_Next_Border_Obj_Fn  ( Zoltan::QueryFunctions::Next_Border_Object,
00324                             0 );
00325   Set_Num_Coarse_Obj_Fn   ( Zoltan::QueryFunctions::Number_Coarse_Objects,
00326                             0 );
00327   Set_Coarse_Obj_List_Fn  ( Zoltan::QueryFunctions::Coarse_Object_List,
00328                             0 );
00329   Set_First_Coarse_Obj_Fn ( Zoltan::QueryFunctions::First_Coarse_Object,
00330                             0 );
00331   Set_Next_Coarse_Obj_Fn  ( Zoltan::QueryFunctions::Next_Coarse_Object,
00332                             0 );
00333   Set_Num_Child_Fn        ( Zoltan::QueryFunctions::Number_Children,
00334                             0 );
00335   Set_Child_List_Fn       ( Zoltan::QueryFunctions::Child_List,
00336                             0 );
00337   Set_Child_Weight_Fn     ( Zoltan::QueryFunctions::Child_Weight,
00338                             0 );
00339 
00340 #endif /* ZOLTAN_OLD_CALLBACK */
00341 
00342   return ZOLTAN_OK;
00343 }
00344 
00345 int Zoltan::LoadBalance::Set_MigrationObject( 
00346       Zoltan::MigrationObject * migration_obj_ptr )
00347 {
00348   Zoltan::MigrationContainer::registerMigrationObject( ObjectID,
00349   migration_obj_ptr );
00350 
00351 #ifdef ZOLTAN_OLD_CALLBACK
00352 
00353   //LB_Set_Fn all Cstyle Functions
00354   Set_CallBack_Fn( ZOLTAN_OBJ_SIZE_FN_TYPE,
00355   reinterpret_cast<void *> (Zoltan::MigrationFunctions::Object_Size),
00356         0 );
00357   Set_CallBack_Fn( ZOLTAN_PRE_MIGRATE_FN_TYPE,
00358   reinterpret_cast<void *> (Zoltan::MigrationFunctions::Pre_Migrate),
00359         0 );
00360   Set_CallBack_Fn( ZOLTAN_MID_MIGRATE_FN_TYPE,
00361   reinterpret_cast<void *> (Zoltan::MigrationFunctions::Mid_Migrate),
00362         0 );
00363   Set_CallBack_Fn( ZOLTAN_POST_MIGRATE_FN_TYPE,
00364   reinterpret_cast<void *> (Zoltan::MigrationFunctions::Post_Migrate),
00365         0 );
00366   Set_CallBack_Fn( ZOLTAN_PACK_OBJ_FN_TYPE,
00367   reinterpret_cast<void *> (Zoltan::MigrationFunctions::Pack_Object),
00368         0 );
00369   Set_CallBack_Fn( ZOLTAN_UNPACK_OBJ_FN_TYPE,
00370   reinterpret_cast<void *> (Zoltan::MigrationFunctions::Unpack_Object),
00371         0 );
00372 
00373 #else /* ZOLTAN_OLD_CALLBACK */
00374 
00375   Set_Obj_Size_Fn        ( Zoltan::MigrationFunctions::Object_Size, 0 );
00376   Set_Pre_Migrate_Fn     ( Zoltan::MigrationFunctions::Pre_Migrate, 0 );
00377   Set_Mid_Migrate_Fn     ( Zoltan::MigrationFunctions::Mid_Migrate, 0 );
00378   Set_Post_Migrate_Fn    ( Zoltan::MigrationFunctions::Post_Migrate, 0 );
00379   Set_Pack_Obj_Fn        ( Zoltan::MigrationFunctions::Pack_Object, 0 );
00380   Set_Unpack_Obj_Fn      ( Zoltan::MigrationFunctions::Unpack_Object, 0 );
00381 
00382 #endif /* ZOLTAN_OLD_CALLBACK */
00383 
00384   return ZOLTAN_OK;
00385 }
00386 
00387 int Zoltan::LoadBalance::Set_Param( const std::string & param, const std::string & value )
00388 {
00389   return Zoltan_Set_Param( LoadBalance_Ptr_,
00390                            const_cast<char*>(param.c_str()),
00391                            const_cast<char*>(value.c_str()) );
00392 }
00393 
00394 int Zoltan::LoadBalance::Balance(        int * changes,
00395           int * num_gid_entries,
00396           int * num_lid_entries,
00397           int * num_import,
00398           ZOLTAN_ID_PTR * import_global_ids,
00399           ZOLTAN_ID_PTR * import_local_ids,
00400           int ** import_procs,
00401           int * num_export,
00402           ZOLTAN_ID_PTR * export_global_ids,
00403           ZOLTAN_ID_PTR * export_local_ids,
00404           int ** export_procs )
00405 {
00406   Zoltan::QueryContainer::setQueryID( ObjectID );
00407   Zoltan::MigrationContainer::setMigrationID( ObjectID );
00408 
00409   return Zoltan_LB_Balance( LoadBalance_Ptr_, changes, num_gid_entries,
00410   num_lid_entries, num_import, import_global_ids,
00411   import_local_ids, import_procs, num_export, export_global_ids,
00412   export_local_ids, export_procs );
00413 }
00414 
00415 #ifdef ZOLTAN_ORDER
00416 int Zoltan::LoadBalance::Order(   int * num_gid_entries,
00417           int * num_lid_entries,
00418                                         int num_objs,
00419           ZOLTAN_ID_PTR global_ids,
00420           ZOLTAN_ID_PTR local_ids,
00421                                         int * rank,
00422                                         int * iperm )
00423 {
00424   Zoltan::QueryContainer::setQueryID( ObjectID );
00425 
00426   return Zoltan_Order( LoadBalance_Ptr_, num_gid_entries,
00427   num_lid_entries, num_objs, global_ids, local_ids,
00428         rank, iperm, NULL );
00429 }
00430 #endif
00431 
00432 void Zoltan::LoadBalance::Evaluate     ( int print_stats,
00433           int * num_objects,
00434           float * object_weights,
00435                                         int * num_cuts,
00436           float * cut_weights,
00437           int * num_boundary_objects,
00438           int * num_adj_procs )
00439 {
00440   Zoltan::QueryContainer::setQueryID( ObjectID );
00441 
00442 //  HKT 6/24/2009 Commented out call to Zoltan because interface under construction.
00443 //  Zoltan_LB_Eval( LoadBalance_Ptr_, print_stats, num_objects, object_weights,
00444 //  num_cuts, cut_weights, num_boundary_objects, num_adj_procs );
00445 }
00446 
00447 int Zoltan::LoadBalance::Free_Data     ( ZOLTAN_ID_PTR * import_global_ids,
00448           ZOLTAN_ID_PTR * import_local_ids,
00449           int ** import_procs,
00450           ZOLTAN_ID_PTR * export_global_ids,
00451           ZOLTAN_ID_PTR * export_local_ids,
00452           int ** export_procs )
00453 {
00454   return Zoltan_LB_Free_Data( import_global_ids, import_local_ids, import_procs,
00455   export_global_ids, export_local_ids, export_procs );
00456 }
00457 
00458  //Decomposition Augmentation
00459 int Zoltan::LoadBalance::Point_Assign  ( double * coords,
00460           int * proc )
00461 {
00462   return Zoltan_LB_Point_Assign( LoadBalance_Ptr_, coords, proc );
00463 }
00464 
00465 int Zoltan::LoadBalance::Box_Assign    ( double xmin,
00466           double ymin,
00467           double zmin,
00468           double xmax,
00469           double ymax,
00470           double zmax,
00471           int * procs,
00472           int * numprocs )
00473 {
00474   return Zoltan_LB_Box_Assign( LoadBalance_Ptr_, xmin, ymin, zmin, xmax, ymax, zmax,
00475   procs, numprocs );
00476 }
00477 
00478  //Migration Functions
00479 int Zoltan::LoadBalance::Compute_Destinations  ( int num_import,
00480             ZOLTAN_ID_PTR import_global_ids,
00481             ZOLTAN_ID_PTR import_local_ids,
00482             int * import_procs,
00483             int * num_export,
00484             ZOLTAN_ID_PTR * export_global_ids,
00485             ZOLTAN_ID_PTR * export_local_ids,
00486             int ** export_procs )
00487 {
00488   return Zoltan_Compute_Destinations( LoadBalance_Ptr_, num_import,
00489   import_global_ids, import_local_ids, import_procs, num_export,
00490   export_global_ids, export_local_ids, export_procs );
00491 }
00492 
00493 int Zoltan::LoadBalance::Help_Migrate  ( int num_import,
00494           ZOLTAN_ID_PTR import_global_ids,
00495           ZOLTAN_ID_PTR import_local_ids,
00496           int * import_procs,
00497           int num_export,
00498           ZOLTAN_ID_PTR export_global_ids,
00499           ZOLTAN_ID_PTR export_local_ids,
00500           int * export_procs )
00501 {
00502   Zoltan::MigrationContainer::setMigrationID( ObjectID );
00503 
00504   return Zoltan_Help_Migrate( LoadBalance_Ptr_, num_import,
00505   import_global_ids, import_local_ids, import_procs,
00506   num_export, export_global_ids, export_local_ids, export_procs );
00507 }
00508 

Generated on Wed May 12 21:24:46 2010 for EpetraExt by  doxygen 1.4.7