> John, > > Thanks for the quick reply ! > > I was just reading about MPI File Read functions > (http://www-unix.mcs.anl.gov/mpi/www/) and I'm thinking that this is > possible without too much of a hassle. If we can make the mesh readers > take the stringstream as input instead of IFstream, there is > absolutely nothing that needs to change. Based on the attributes, the > partition can be ascertained and each processor needs to read only > those elements and nodes. But, I guess it is easier said than done ! > > I will look into the MeshCommunication class and see if that will > provide a quick fix for my problems. I'll keep you updated if I get > enough time to try out the previous option. > how exactly are you trying to read the file? If it is done through the generic MeshBase::read() member then, as John says, the parallel part should be handled for you. Processor 0 will read the entire mesh and then broadcast it. When MeshBase::read() exits all processors will be ready to go.
As for using MPI's IO functionality, it really depends on the mesh format if this will be easy to do or not. If the format is such that the partitioning is easily specified or inferred, and each processor can compute its offset easily, then it really is easy. Each processor just opens the file and seeks to the proper location. You gotta be careful, though, that you don't exceed the capability of the filesystem... If you do this with say 128 processors to an NFS filesystem you will almost certainly kill your machine. The NemesisIO work is in development, and the reworked XDA/XDR format is intended to be easily handled in parallel as well. Once it is all completed it should be possible to serially convert an arbitrary file format to one of the 'preferred' parallel formats, then use that as input to the parallel job. -Ben ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Libmesh-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/libmesh-users
