<meta http-equiv="Content-Type" content="text/html; charset=utf-8"><div dir="ltr">Thanks, Ken. When I set *flag=1 in the copyfn, the output becomes:<br><br>$ ./a.out<br><br>In ibcast_copy: keyval = -1539309568<br>In ibcast_delete: keyval = -1539309568<br>In ibcast_delete: keyval = -1539309568<br><br>Jeff<br><br>On Tue, Apr 5, 2016 at 11:08 AM, Kenneth Raffenetti <<a href="mailto:raffenet@mcs.anl.gov">raffenet@mcs.anl.gov</a>> wrote:<br>><br>> I think in the example, it's undefined if the attribute will be set on the duped communicator. See pg. 269 in MPI-3.1. If the callback does not set the output flag to true/false, how will the implementation know what to do?<br>><br>> Ken<br>><br>> On 04/05/2016 11:05 AM, Jeff Hammond wrote:<br>>><br>>> I guess I don't know what the right answer is for MPI_COMM_WORLD. I'll<br>>> try that test again with attributes set only on subcomms to see how it<br>>> behaves.<br>>><br>>> Jeff<br>>><br>>> On Tue, Apr 5, 2016 at 10:24 AM, Balaji, Pavan <<a href="mailto:balaji@anl.gov">balaji@anl.gov</a><br>>> <mailto:<a href="mailto:balaji@anl.gov">balaji@anl.gov</a>>> wrote:<br>>><br>>><br>>> Hmm. I would think the mpich output is correct: the attributed<br>>> should only be deleted once. But I could be wrong.<br>>><br>>> -- Pavan<br>>><br>>> > On Apr 5, 2016, at 8:10 AM, Jeff Hammond <<a href="mailto:jeff.science@gmail.com">jeff.science@gmail.com</a><br>>> <mailto:<a href="mailto:jeff.science@gmail.com">jeff.science@gmail.com</a>>> wrote:<br>>> ><br>>> > My concern is the number of times the string "ibcast_delete"<br>>> appears in the output (2 vs 1)...<br>>> ><br>>> > Jeff<br>>> ><br>>> > On Mon, Apr 4, 2016 at 10:02 PM, Balaji, Pavan <<a href="mailto:balaji@anl.gov">balaji@anl.gov</a><br>>> <mailto:<a href="mailto:balaji@anl.gov">balaji@anl.gov</a>>> wrote:<br>>> ><br>>> > You are printing a number that's generated by the MPI<br>>> implementation. It's value will be different for different MPI<br>>> implementations.<br>>> ><br>>> > -- Pavan<br>>> ><br>>> >> On Apr 4, 2016, at 11:56 PM, Jeff Hammond<br>>> <<a href="mailto:jeff.science@gmail.com">jeff.science@gmail.com</a> <mailto:<a href="mailto:jeff.science@gmail.com">jeff.science@gmail.com</a>>> wrote:<br>>> >><br>>> >> I am trying to understand how communicator attributes work, so I<br>>> found<br>>> <a href="http://stackoverflow.com/questions/25198353/callbacks-provided-in-mpi-comm-create-keyval-are-not-called">http://stackoverflow.com/questions/25198353/callbacks-provided-in-mpi-comm-create-keyval-are-not-called</a>,<br>>> which contains a nice example (the code in<br>>> <a href="http://stackoverflow.com/a/25205611/2189128">http://stackoverflow.com/a/25205611/2189128</a>).<br>>> >><br>>> >> However, the posted output of this code is:<br>>> >><br>>> >> $ mpirun -np 1 ./comm-attr<br>>> >> In ibcast_copy: keyval = 10<br>>> >> In ibcast_delete: keyval = 10<br>>> >> In ibcast_delete: keyval = 10<br>>> >><br>>> >> Whereas I observe:<br>>> >><br>>> >> $ mpirun -np 1 ./a.out<br>>> >> In ibcast_copy: keyval = -1539309568<br>>> >> In ibcast_delete: keyval = -1539309568<br>>> >><br>>> >> Can anyone help me understand what the correct output of this<br>>> program is? If it is not what I am seeing, is this a bug in MPICH<br>>> or am I doing something wrong?<br>>> >><br>>> >> I am using MPICH git from November 2015, so I will git pull &&<br>>> ./autogen.sh && $CONFIGUREMAKEINSTALL and try again just to be sure.<br>>> >><br>>> >> Thanks,<br>>> >><br>>> >> Jeff<br>>> >><br>>> >> $ mpirun --version<br>>> >> HYDRA build details:<br>>> >> Version: 3.2<br>>> >> Release Date: unreleased<br>>> development copy<br>>> >> CC: icc<br>>> >> CXX: icpc<br>>> >> F77: ifort<br>>> >> F90: ifort<br>>> >> Configure options:<br>>> '--disable-option-checking'<br>>> '--prefix=/opt/mpich/dev/intel/default' 'CC=icc' 'CXX=icpc'<br>>> 'FC=ifort' 'F77=ifort' '--enable-cxx' '--enable-fortran'<br>>> '--enable-threads=runtime' '--enable-g=dbg' '--with-pm=hydra'<br>>> '--enable-wrapper-rpath' '--enable-static' '--enable-shared'<br>>> '--cache-file=/dev/null' '--srcdir=../../../../src/pm/hydra'<br>>> 'CFLAGS= -g -O2' 'LDFLAGS=' 'LIBS=-lpthread ' 'CPPFLAGS=<br>>> -I/Users/jrhammon/Work/MPI/MPICH/git/build/src/mpl/include<br>>> -I/Users/jrhammon/Work/MPI/MPICH/git/src/mpl/include<br>>> -I/Users/jrhammon/Work/MPI/MPICH/git/src/openpa/src<br>>> -I/Users/jrhammon/Work/MPI/MPICH/git/build/src/openpa/src<br>>> -D_REENTRANT<br>>> -I/Users/jrhammon/Work/MPI/MPICH/git/build/src/mpi/romio/include'<br>>> >> Process Manager: pmi<br>>> >> Launchers available: ssh rsh fork slurm<br>>> ll lsf sge manual persist<br>>> >> Topology libraries available: hwloc<br>>> >> Resource management kernels available: user slurm ll lsf<br>>> sge pbs cobalt<br>>> >> Checkpointing libraries available:<br>>> >> Demux engines available: poll select<br>>> >><br>>> >><br>>> >> --<br>>> >> Jeff Hammond<br>>> >> <a href="mailto:jeff.science@gmail.com">jeff.science@gmail.com</a> <mailto:<a href="mailto:jeff.science@gmail.com">jeff.science@gmail.com</a>><br>>> >> <a href="http://jeffhammond.github.io/">http://jeffhammond.github.io/</a><br>>> >> _______________________________________________<br>>> >> discuss mailing list <a href="mailto:discuss@mpich.org">discuss@mpich.org</a> <mailto:<a href="mailto:discuss@mpich.org">discuss@mpich.org</a>><br>>> >> To manage subscription options or unsubscribe:<br>>> >> <a href="https://lists.mpich.org/mailman/listinfo/discuss">https://lists.mpich.org/mailman/listinfo/discuss</a><br>>> ><br>>> > _______________________________________________<br>>> > discuss mailing list <a href="mailto:discuss@mpich.org">discuss@mpich.org</a> <mailto:<a href="mailto:discuss@mpich.org">discuss@mpich.org</a>><br>>> > To manage subscription options or unsubscribe:<br>>> > <a href="https://lists.mpich.org/mailman/listinfo/discuss">https://lists.mpich.org/mailman/listinfo/discuss</a><br>>> ><br>>> ><br>>> ><br>>> > --<br>>> > Jeff Hammond<br>>> > <a href="mailto:jeff.science@gmail.com">jeff.science@gmail.com</a> <mailto:<a href="mailto:jeff.science@gmail.com">jeff.science@gmail.com</a>><br>>> > <a href="http://jeffhammond.github.io/">http://jeffhammond.github.io/</a><br>>> > _______________________________________________<br>>> > discuss mailing list <a href="mailto:discuss@mpich.org">discuss@mpich.org</a> <mailto:<a href="mailto:discuss@mpich.org">discuss@mpich.org</a>><br>>> > To manage subscription options or unsubscribe:<br>>> > <a href="https://lists.mpich.org/mailman/listinfo/discuss">https://lists.mpich.org/mailman/listinfo/discuss</a><br>>><br>>> _______________________________________________<br>>> discuss mailing list <a href="mailto:discuss@mpich.org">discuss@mpich.org</a> <mailto:<a href="mailto:discuss@mpich.org">discuss@mpich.org</a>><br>>> To manage subscription options or unsubscribe:<br>>> <a href="https://lists.mpich.org/mailman/listinfo/discuss">https://lists.mpich.org/mailman/listinfo/discuss</a><br>>><br>>><br>>><br>>><br>>> --<br>>> Jeff Hammond<br>>> <a href="mailto:jeff.science@gmail.com">jeff.science@gmail.com</a> <mailto:<a href="mailto:jeff.science@gmail.com">jeff.science@gmail.com</a>><br>>> <a href="http://jeffhammond.github.io/">http://jeffhammond.github.io/</a><br>>><br>>><br>>> _______________________________________________<br>>> discuss mailing list <a href="mailto:discuss@mpich.org">discuss@mpich.org</a><br>>> To manage subscription options or unsubscribe:<br>>> <a href="https://lists.mpich.org/mailman/listinfo/discuss">https://lists.mpich.org/mailman/listinfo/discuss</a><br>>><br>> _______________________________________________<br>> discuss mailing list <a href="mailto:discuss@mpich.org">discuss@mpich.org</a><br>> To manage subscription options or unsubscribe:<br>> <a href="https://lists.mpich.org/mailman/listinfo/discuss">https://lists.mpich.org/mailman/listinfo/discuss</a><br><br><br><br><br>--<br>Jeff Hammond<br><a href="mailto:jeff.science@gmail.com">jeff.science@gmail.com</a><br><a href="http://jeffhammond.github.io/">http://jeffhammond.github.io/</a><br><div class="gmail_extra">
</div></div>