10 #include "Teuchos_CommHelpers.hpp"
11 #ifdef HAVE_TEUCHOS_MPI
12 # include "Teuchos_Details_MpiCommRequest.hpp"
14 #endif // HAVE_TEUCHOS_MPI
15 #ifdef HAVE_TEUCHOSCORE_CXX11
21 #ifdef HAVE_TEUCHOS_MPI
24 std::string getMpiErrorString (
const int errCode) {
27 char errString [MPI_MAX_ERROR_STRING+1];
28 int errStringLen = MPI_MAX_ERROR_STRING;
29 (void) MPI_Error_string (errCode, errString, &errStringLen);
34 if (errString[errStringLen-1] !=
'\0') {
35 errString[errStringLen] =
'\0';
37 return std::string (errString);
41 #endif // HAVE_TEUCHOS_MPI
54 reduceAllImpl (
const Comm<int>& comm,
55 const EReductionType reductType,
60 #ifdef HAVE_TEUCHOS_MPI
61 using Teuchos::Details::MpiTypeTraits;
66 const MpiComm<int>* mpiComm =
dynamic_cast<const MpiComm<int>*
> (&comm);
67 if (mpiComm == NULL) {
69 const SerialComm<int>* serialComm =
dynamic_cast<const SerialComm<int>*
> (&comm);
70 if (serialComm == NULL) {
73 #ifdef HAVE_TEUCHOSCORE_CXX11
74 std::unique_ptr<ValueTypeReductionOp<int, T> >
76 std::auto_ptr<ValueTypeReductionOp<int, T> >
78 reductOp (createOp<int, T> (reductType));
79 reduceAll (comm, *reductOp, count, sendBuffer, globalReducts);
82 std::copy (sendBuffer, sendBuffer + count, globalReducts);
85 MPI_Op rawMpiOp = ::Teuchos::Details::getMpiOpForEReductionType (reductType);
86 MPI_Comm rawMpiComm = * (mpiComm->getRawMpiComm ());
88 MPI_Datatype rawMpiType = MpiTypeTraits<T>::getType (t);
90 int err = MPI_SUCCESS;
91 if (sendBuffer == globalReducts) {
95 err = MPI_Allreduce (MPI_IN_PLACE, globalReducts,
96 count, rawMpiType, rawMpiOp, rawMpiComm);
99 err = MPI_Allreduce (const_cast<T*> (sendBuffer), globalReducts,
100 count, rawMpiType, rawMpiOp, rawMpiComm);
105 "MPI_Allreduce failed with the following error: "
106 << ::Teuchos::Details::getMpiErrorString (err));
110 std::copy (sendBuffer, sendBuffer + count, globalReducts);
111 #endif // HAVE_TEUCHOS_MPI
124 gatherImpl (
const T sendBuf[],
129 const Comm<int>& comm)
131 #ifdef HAVE_TEUCHOS_MPI
132 using Teuchos::Details::MpiTypeTraits;
137 const MpiComm<int>* mpiComm =
dynamic_cast<const MpiComm<int>*
> (&comm);
138 if (mpiComm == NULL) {
140 const SerialComm<int>* serialComm =
dynamic_cast<const SerialComm<int>*
> (&comm);
141 if (serialComm == NULL) {
144 gather<int, T> (sendBuf, sendCount, recvBuf, recvCount, root, comm);
147 std::copy (sendBuf, sendBuf + sendCount, recvBuf);
150 MPI_Comm rawMpiComm = * (mpiComm->getRawMpiComm ());
152 MPI_Datatype rawMpiType = MpiTypeTraits<T>::getType (t);
153 const int err = MPI_Gather (const_cast<T*> (sendBuf), sendCount, rawMpiType,
154 recvBuf, recvCount, rawMpiType,
159 "MPI_Gather failed with the following error: "
160 << ::Teuchos::Details::getMpiErrorString (err));
164 std::copy (sendBuf, sendBuf + sendCount, recvBuf);
165 #endif // HAVE_TEUCHOS_MPI
178 scatterImpl (
const T sendBuf[],
183 const Comm<int>& comm)
185 #ifdef HAVE_TEUCHOS_MPI
186 using Teuchos::Details::MpiTypeTraits;
191 const MpiComm<int>* mpiComm =
dynamic_cast<const MpiComm<int>*
> (&comm);
192 if (mpiComm == NULL) {
194 const SerialComm<int>* serialComm =
dynamic_cast<const SerialComm<int>*
> (&comm);
195 if (serialComm == NULL) {
198 scatter<int, T> (sendBuf, sendCount, recvBuf, recvCount, root, comm);
201 std::copy (sendBuf, sendBuf + sendCount, recvBuf);
204 MPI_Comm rawMpiComm = * (mpiComm->getRawMpiComm ());
206 MPI_Datatype rawMpiType = MpiTypeTraits<T>::getType (t);
208 MPI_Scatter (const_cast<T*> (sendBuf), sendCount, rawMpiType,
209 recvBuf, recvCount, rawMpiType,
212 (err != MPI_SUCCESS, std::runtime_error,
213 "MPI_Scatter failed with the following error: "
214 << ::Teuchos::Details::getMpiErrorString (err));
219 std::copy (sendBuf, sendBuf + sendCount, recvBuf);
220 #endif // HAVE_TEUCHOS_MPI
225 scattervImpl (
const T sendBuf[],
226 const int sendCounts[],
231 const Comm<int>& comm)
233 #ifdef HAVE_TEUCHOS_MPI
234 using Teuchos::Details::MpiTypeTraits;
239 const MpiComm<int>* mpiComm =
dynamic_cast<const MpiComm<int>*
> (&comm);
240 if (mpiComm == NULL) {
242 const SerialComm<int>* serialComm =
dynamic_cast<const SerialComm<int>*
> (&comm);
243 if (serialComm == NULL) {
246 scatterv<int, T> (sendBuf, sendCounts, displs, recvBuf, recvCount, root, comm);
249 std::copy (sendBuf, sendBuf + sendCounts[0], recvBuf);
252 MPI_Comm rawMpiComm = * (mpiComm->getRawMpiComm ());
254 MPI_Datatype rawMpiType = MpiTypeTraits<T>::getType (t);
256 MPI_Scatterv (const_cast<T*> (sendBuf), sendCounts, displs, rawMpiType,
257 recvBuf, recvCount, rawMpiType,
260 (err != MPI_SUCCESS, std::runtime_error,
261 "MPI_Scatter failed with the following error: "
262 << ::Teuchos::Details::getMpiErrorString (err));
267 std::copy (sendBuf, sendBuf + sendCounts[0], recvBuf);
268 #endif // HAVE_TEUCHOS_MPI
281 reduceImpl (
const T sendBuf[],
284 const EReductionType reductType,
286 const Comm<int>& comm)
288 #ifdef HAVE_TEUCHOS_MPI
289 using Teuchos::Details::MpiTypeTraits;
294 const MpiComm<int>* mpiComm =
dynamic_cast<const MpiComm<int>*
> (&comm);
295 if (mpiComm == NULL) {
297 const SerialComm<int>* serialComm =
dynamic_cast<const SerialComm<int>*
> (&comm);
298 if (serialComm == NULL) {
301 reduce<int, T> (sendBuf, recvBuf, count, reductType, root, comm);
304 std::copy (sendBuf, sendBuf + count, recvBuf);
307 MPI_Op rawMpiOp = ::Teuchos::Details::getMpiOpForEReductionType (reductType);
308 MPI_Comm rawMpiComm = * (mpiComm->getRawMpiComm ());
310 MPI_Datatype rawMpiType = MpiTypeTraits<T>::getType (t);
311 const int err = MPI_Reduce (const_cast<T*> (sendBuf), recvBuf, count,
312 rawMpiType, rawMpiOp, root, rawMpiComm);
314 (err != MPI_SUCCESS, std::runtime_error,
"MPI_Reduce failed with the "
315 "following error: " << ::Teuchos::Details::getMpiErrorString (err));
319 std::copy (sendBuf, sendBuf + count, recvBuf);
320 #endif // HAVE_TEUCHOS_MPI
333 gathervImpl (
const T sendBuf[],
336 const int recvCounts[],
339 const Comm<int>& comm)
341 #ifdef HAVE_TEUCHOS_MPI
342 using Teuchos::Details::MpiTypeTraits;
347 const MpiComm<int>* mpiComm =
dynamic_cast<const MpiComm<int>*
> (&comm);
348 if (mpiComm == NULL) {
350 const SerialComm<int>* serialComm =
dynamic_cast<const SerialComm<int>*
> (&comm);
351 if (serialComm == NULL) {
354 gatherv<int, T> (sendBuf, sendCount, recvBuf, recvCounts, displs, root, comm);
358 recvCounts[0] > sendCount, std::invalid_argument,
359 "Teuchos::gatherv: If the input communicator contains only one "
360 "process, then you cannot receive more entries than you send. "
361 "You aim to receive " << recvCounts[0] <<
" entries, but to send "
362 << sendCount <<
" entries.");
366 std::copy (sendBuf, sendBuf + recvCounts[0], recvBuf + displs[0]);
369 MPI_Comm rawMpiComm = * (mpiComm->getRawMpiComm ());
371 MPI_Datatype rawMpiType = MpiTypeTraits<T>::getType (t);
372 const int err = MPI_Gatherv (const_cast<T*> (sendBuf),
376 const_cast<int*> (recvCounts),
377 const_cast<int*> (displs),
384 "MPI_Gatherv failed with the following error: "
385 << ::Teuchos::Details::getMpiErrorString (err));
390 recvCounts[0] > sendCount, std::invalid_argument,
391 "Teuchos::gatherv: If the input communicator contains only one "
392 "process, then you cannot receive more entries than you send. "
393 "You aim to receive " << recvCounts[0] <<
" entries, but to send "
394 << sendCount <<
" entries.");
398 std::copy (sendBuf, sendBuf + recvCounts[0], recvBuf + displs[0]);
399 #endif // HAVE_TEUCHOS_MPI
407 template<
typename Packet>
408 RCP<Teuchos::CommRequest<int> >
409 ireceiveGeneral(
const Comm<int>& comm,
410 const ArrayRCP<Packet> &recvBuffer,
411 const int sourceRank)
413 TEUCHOS_COMM_TIME_MONITOR(
414 "Teuchos::ireceive<int, " <<
"," << TypeNameTraits<Packet>::name ()
415 <<
"> ( value type )"
417 ValueTypeSerializationBuffer<int, Packet>
418 charRecvBuffer (recvBuffer.size (), recvBuffer.getRawPtr ());
419 RCP<CommRequest<int> > commRequest =
420 comm.ireceive (charRecvBuffer.getCharBufferView (), sourceRank);
421 set_extra_data (recvBuffer,
"buffer", inOutArg (commRequest));
427 template<
typename Packet>
428 RCP<Teuchos::CommRequest<int> >
429 ireceiveGeneral (
const ArrayRCP<Packet> &recvBuffer,
430 const int sourceRank,
432 const Comm<int>& comm)
434 TEUCHOS_COMM_TIME_MONITOR(
435 "Teuchos::ireceive<int, " <<
"," << TypeNameTraits<Packet>::name ()
436 <<
"> ( value type )"
438 ValueTypeSerializationBuffer<int, Packet>
439 charRecvBuffer (recvBuffer.size (), recvBuffer.getRawPtr ());
440 RCP<CommRequest<int> > commRequest =
441 comm.ireceive (charRecvBuffer.getCharBufferView (), sourceRank, tag);
442 set_extra_data (recvBuffer,
"buffer", inOutArg (commRequest));
459 RCP<CommRequest<int> >
460 ireceiveImpl (
const Comm<int>& comm,
461 const ArrayRCP<T>& recvBuffer,
462 const int sourceRank)
464 #ifdef HAVE_TEUCHOS_MPI
465 using Teuchos::Details::MpiTypeTraits;
470 const MpiComm<int>* mpiComm =
dynamic_cast<const MpiComm<int>*
> (&comm);
471 if (mpiComm == NULL) {
473 const SerialComm<int>* serialComm =
dynamic_cast<const SerialComm<int>*
> (&comm);
474 if (serialComm == NULL) {
477 return ireceiveGeneral<T> (comm, recvBuffer, sourceRank);
483 "ireceiveImpl: Not implemented for a serial communicator.");
487 MPI_Comm rawComm = * (mpiComm->getRawMpiComm ());
489 MPI_Datatype rawType = MpiTypeTraits<T>::getType (t);
490 T* rawRecvBuf = recvBuffer.getRawPtr ();
491 const int count = as<int> (recvBuffer.size ());
492 const int tag = mpiComm->getTag ();
493 MPI_Request rawRequest = MPI_REQUEST_NULL;
494 const int err = MPI_Irecv (rawRecvBuf, count, rawType, sourceRank, tag,
495 rawComm, &rawRequest);
497 err != MPI_SUCCESS, std::runtime_error,
498 "MPI_Irecv failed with the following error: "
499 << ::Teuchos::Details::getMpiErrorString (err));
501 ArrayRCP<const char> buf =
502 arcp_const_cast<
const char> (arcp_reinterpret_cast<
char> (recvBuffer));
503 RCP<Details::MpiCommRequest> req (
new Details::MpiCommRequest (rawRequest, buf));
504 return rcp_implicit_cast<CommRequest<int> > (req);
510 "ireceiveImpl: Not implemented for a serial communicator.");
521 #endif // HAVE_TEUCHOS_MPI
527 RCP<CommRequest<int> >
528 ireceiveImpl (
const ArrayRCP<T>& recvBuffer,
529 const int sourceRank,
531 const Comm<int>& comm)
533 #ifdef HAVE_TEUCHOS_MPI
534 using Teuchos::Details::MpiTypeTraits;
539 const MpiComm<int>* mpiComm =
dynamic_cast<const MpiComm<int>*
> (&comm);
540 if (mpiComm == NULL) {
542 const SerialComm<int>* serialComm =
dynamic_cast<const SerialComm<int>*
> (&comm);
543 if (serialComm == NULL) {
546 return ireceiveGeneral<T> (recvBuffer, sourceRank, tag, comm);
552 "ireceiveImpl: Not implemented for a serial communicator.");
556 MPI_Comm rawComm = * (mpiComm->getRawMpiComm ());
558 MPI_Datatype rawType = MpiTypeTraits<T>::getType (t);
559 T* rawRecvBuf = recvBuffer.getRawPtr ();
560 const int count = as<int> (recvBuffer.size ());
561 MPI_Request rawRequest = MPI_REQUEST_NULL;
562 const int err = MPI_Irecv (rawRecvBuf, count, rawType, sourceRank, tag,
563 rawComm, &rawRequest);
565 err != MPI_SUCCESS, std::runtime_error,
566 "MPI_Irecv failed with the following error: "
567 << ::Teuchos::Details::getMpiErrorString (err));
569 ArrayRCP<const char> buf =
570 arcp_const_cast<
const char> (arcp_reinterpret_cast<
char> (recvBuffer));
571 RCP<Details::MpiCommRequest> req (
new Details::MpiCommRequest (rawRequest, buf));
572 return rcp_implicit_cast<CommRequest<int> > (req);
578 "ireceiveImpl: Not implemented for a serial communicator.");
581 #endif // HAVE_TEUCHOS_MPI
591 sendGeneral (
const Comm<int>& comm,
593 const T sendBuffer[],
596 TEUCHOS_COMM_TIME_MONITOR(
597 "Teuchos::send<int, " << TypeNameTraits<T>::name () <<
">");
598 ConstValueTypeSerializationBuffer<int,T> charSendBuffer (count, sendBuffer);
599 comm.send (charSendBuffer.getBytes (),
600 charSendBuffer.getCharBuffer (),
608 sendGeneral (
const T sendBuffer[],
612 const Comm<int>& comm)
614 TEUCHOS_COMM_TIME_MONITOR(
615 "Teuchos::send<int, " << TypeNameTraits<T>::name () <<
">");
616 ConstValueTypeSerializationBuffer<int,T> charSendBuffer (count, sendBuffer);
617 comm.send (charSendBuffer.getBytes (),
618 charSendBuffer.getCharBuffer (),
636 sendImpl (
const Comm<int>& comm,
638 const T sendBuffer[],
641 #ifdef HAVE_TEUCHOS_MPI
642 using Teuchos::Details::MpiTypeTraits;
647 const MpiComm<int>* mpiComm =
dynamic_cast<const MpiComm<int>*
> (&comm);
648 if (mpiComm == NULL) {
650 const SerialComm<int>* serialComm =
dynamic_cast<const SerialComm<int>*
> (&comm);
651 if (serialComm == NULL) {
654 sendGeneral<T> (comm, count, sendBuffer, destRank);
660 "sendImpl: Not implemented for a serial communicator.");
664 TEUCHOS_COMM_TIME_MONITOR(
665 "Teuchos::sendImpl<" << TypeNameTraits<T>::name () <<
">");
666 MPI_Comm rawComm = * (mpiComm->getRawMpiComm ());
668 MPI_Datatype rawType = MpiTypeTraits<T>::getType (t);
669 T* rawBuf =
const_cast<T*
> (sendBuffer);
670 const int tag = mpiComm->getTag ();
671 const int err = MPI_Send (rawBuf, count, rawType, destRank, tag, rawComm);
675 "MPI_Send failed with the following error: "
676 << ::Teuchos::Details::getMpiErrorString (err));
682 "sendImpl: Not implemented for a serial communicator.");
683 #endif // HAVE_TEUCHOS_MPI
690 sendImpl (
const T sendBuffer[],
694 const Comm<int>& comm)
696 #ifdef HAVE_TEUCHOS_MPI
697 using Teuchos::Details::MpiTypeTraits;
702 const MpiComm<int>* mpiComm =
dynamic_cast<const MpiComm<int>*
> (&comm);
703 if (mpiComm == NULL) {
705 const SerialComm<int>* serialComm =
dynamic_cast<const SerialComm<int>*
> (&comm);
706 if (serialComm == NULL) {
709 sendGeneral<T> (sendBuffer, count, destRank, tag, comm);
715 "sendImpl: Not implemented for a serial communicator.");
719 TEUCHOS_COMM_TIME_MONITOR(
720 "Teuchos::sendImpl<" << TypeNameTraits<T>::name () <<
">");
721 MPI_Comm rawComm = * (mpiComm->getRawMpiComm ());
723 MPI_Datatype rawType = MpiTypeTraits<T>::getType (t);
724 T* rawBuf =
const_cast<T*
> (sendBuffer);
725 const int err = MPI_Send (rawBuf, count, rawType, destRank, tag, rawComm);
729 "MPI_Send failed with the following error: "
730 << ::Teuchos::Details::getMpiErrorString (err));
736 "sendImpl: Not implemented for a serial communicator.");
737 #endif // HAVE_TEUCHOS_MPI
746 RCP<CommRequest<int> >
747 isendGeneral (
const Comm<int>& comm,
748 const ArrayRCP<const T>& sendBuffer,
751 TEUCHOS_COMM_TIME_MONITOR(
752 "Teuchos::isend<int," << TypeNameTraits<T>::name () <<
">");
753 ConstValueTypeSerializationBuffer<int, T>
754 charSendBuffer (sendBuffer.size (), sendBuffer.getRawPtr ());
755 RCP<CommRequest<int> > commRequest =
756 comm.isend (charSendBuffer.getCharBufferView (), destRank);
757 set_extra_data (sendBuffer,
"buffer", inOutArg (commRequest));
768 RCP<CommRequest<int> >
769 isendGeneral (
const ArrayRCP<const T>& sendBuffer,
772 const Comm<int>& comm)
774 TEUCHOS_COMM_TIME_MONITOR(
775 "Teuchos::isend<int," << TypeNameTraits<T>::name () <<
">");
776 ConstValueTypeSerializationBuffer<int, T>
777 charSendBuffer (sendBuffer.size (), sendBuffer.getRawPtr ());
778 RCP<CommRequest<int> > commRequest =
779 comm.isend (charSendBuffer.getCharBufferView (), destRank, tag);
780 set_extra_data (sendBuffer,
"buffer", inOutArg (commRequest));
787 RCP<Teuchos::CommRequest<int> >
788 isendImpl (
const ArrayRCP<const T>& sendBuffer,
791 const Comm<int>& comm)
793 #ifdef HAVE_TEUCHOS_MPI
794 using Teuchos::Details::MpiTypeTraits;
799 const MpiComm<int>* mpiComm =
dynamic_cast<const MpiComm<int>*
> (&comm);
800 if (mpiComm == NULL) {
802 const SerialComm<int>* serialComm =
dynamic_cast<const SerialComm<int>*
> (&comm);
803 if (serialComm == NULL) {
806 return isendGeneral<T> (sendBuffer, destRank, tag, comm);
810 true, std::logic_error,
811 "isendImpl: Not implemented for a serial communicator.");
815 TEUCHOS_COMM_TIME_MONITOR(
816 "Teuchos::isendImpl<" << TypeNameTraits<T>::name () <<
">");
818 MPI_Comm rawComm = * (mpiComm->getRawMpiComm ());
820 MPI_Datatype rawType = MpiTypeTraits<T>::getType (t);
824 T* rawSendBuf =
const_cast<T*
> (sendBuffer.getRawPtr ());
825 const int count = as<int> (sendBuffer.size ());
826 MPI_Request rawRequest = MPI_REQUEST_NULL;
827 const int err = MPI_Isend (rawSendBuf, count, rawType, destRank, tag,
828 rawComm, &rawRequest);
832 "MPI_Isend failed with the following error: "
833 << ::Teuchos::Details::getMpiErrorString (err));
835 ArrayRCP<const char> buf = arcp_reinterpret_cast<
const char> (sendBuffer);
836 RCP<Details::MpiCommRequest> req (
new Details::MpiCommRequest (rawRequest, buf));
837 return rcp_implicit_cast<CommRequest<int> > (req);
843 "isendImpl: Not implemented for a serial communicator.");
844 #endif // HAVE_TEUCHOS_MPI
860 #ifdef HAVE_TEUCHOS_COMPLEX
864 reduceAll<int, std::complex<double> > (
const Comm<int>& comm,
865 const EReductionType reductType,
867 const std::complex<double> sendBuffer[],
868 std::complex<double> globalReducts[])
870 TEUCHOS_COMM_TIME_MONITOR(
871 "Teuchos::reduceAll<int, std::complex<double> > (" << count <<
", "
872 << toString (reductType) <<
")"
874 reduceAllImpl<std::complex<double> > (comm, reductType, count, sendBuffer, globalReducts);
878 RCP<Teuchos::CommRequest<int> >
879 ireceive<int, std::complex<double> > (
const Comm<int>& comm,
880 const ArrayRCP<std::complex<double> >& recvBuffer,
881 const int sourceRank)
883 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, std::complex<double> >");
884 return ireceiveImpl<std::complex<double> > (comm, recvBuffer, sourceRank);
888 RCP<Teuchos::CommRequest<int> >
889 ireceive<int, std::complex<double> > (
const ArrayRCP<std::complex<double> >& recvBuffer,
890 const int sourceRank,
892 const Comm<int>& comm)
894 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, std::complex<double> >");
895 return ireceiveImpl<std::complex<double> > (recvBuffer, sourceRank, tag, comm);
900 send<int, std::complex<double> > (
const Comm<int>& comm,
902 const std::complex<double> sendBuffer[],
905 sendImpl<std::complex<double> > (comm, count, sendBuffer, destRank);
910 send<int, std::complex<double> > (
const std::complex<double> sendBuffer[],
914 const Comm<int>& comm)
916 sendImpl<std::complex<double> > (sendBuffer, count, destRank, tag, comm);
920 RCP<Teuchos::CommRequest<int> >
921 isend (
const ArrayRCP<
const std::complex<double> >& sendBuffer,
924 const Comm<int>& comm)
926 return isendImpl<std::complex<double> > (sendBuffer, destRank, tag, comm);
932 reduceAll<int, std::complex<float> > (
const Comm<int>& comm,
933 const EReductionType reductType,
935 const std::complex<float> sendBuffer[],
936 std::complex<float> globalReducts[])
938 TEUCHOS_COMM_TIME_MONITOR(
939 "Teuchos::reduceAll<int, std::complex<float> > (" << count <<
", "
940 << toString (reductType) <<
")"
942 reduceAllImpl<std::complex<float> > (comm, reductType, count, sendBuffer, globalReducts);
946 RCP<Teuchos::CommRequest<int> >
947 ireceive<int, std::complex<float> > (
const Comm<int>& comm,
948 const ArrayRCP<std::complex<float> >& recvBuffer,
949 const int sourceRank)
951 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, std::complex<float> >");
952 return ireceiveImpl<std::complex<float> > (comm, recvBuffer, sourceRank);
956 RCP<Teuchos::CommRequest<int> >
957 ireceive<int, std::complex<float> > (
const ArrayRCP<std::complex<float> >& recvBuffer,
958 const int sourceRank,
960 const Comm<int>& comm)
962 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, std::complex<float> >");
963 return ireceiveImpl<std::complex<float> > (recvBuffer, sourceRank, tag, comm);
968 send<int, std::complex<float> > (
const Comm<int>& comm,
970 const std::complex<float> sendBuffer[],
973 return sendImpl<std::complex<float> > (comm, count, sendBuffer, destRank);
978 send<int, std::complex<float> > (
const std::complex<float> sendBuffer[],
982 const Comm<int>& comm)
984 return sendImpl<std::complex<float> > (sendBuffer, count, destRank, tag, comm);
988 RCP<Teuchos::CommRequest<int> >
989 isend (
const ArrayRCP<
const std::complex<float> >& sendBuffer,
992 const Comm<int>& comm)
994 return isendImpl<std::complex<float> > (sendBuffer, destRank, tag, comm);
996 #endif // HAVE_TEUCHOS_COMPLEX
1002 reduceAll<int, double> (
const Comm<int>& comm,
1003 const EReductionType reductType,
1005 const double sendBuffer[],
1006 double globalReducts[])
1008 TEUCHOS_COMM_TIME_MONITOR(
1009 "Teuchos::reduceAll<int, double> (" << count <<
", "
1010 << toString (reductType) <<
")"
1012 reduceAllImpl<double> (comm, reductType, count, sendBuffer, globalReducts);
1016 RCP<Teuchos::CommRequest<int> >
1017 ireceive<int, double> (
const Comm<int>& comm,
1018 const ArrayRCP<double>& recvBuffer,
1019 const int sourceRank)
1021 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, double>");
1022 return ireceiveImpl<double> (comm, recvBuffer, sourceRank);
1026 RCP<Teuchos::CommRequest<int> >
1027 ireceive<int, double> (
const ArrayRCP<double>& recvBuffer,
1028 const int sourceRank,
1030 const Comm<int>& comm)
1032 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, double>");
1033 return ireceiveImpl<double> (recvBuffer, sourceRank, tag, comm);
1038 send<int, double> (
const Comm<int>& comm,
1040 const double sendBuffer[],
1043 return sendImpl<double> (comm, count, sendBuffer, destRank);
1048 send<int, double> (
const double sendBuffer[],
1052 const Comm<int>& comm)
1054 return sendImpl<double> (sendBuffer, count, destRank, tag, comm);
1058 RCP<Teuchos::CommRequest<int> >
1059 isend (
const ArrayRCP<const double>& sendBuffer,
1062 const Comm<int>& comm)
1064 return isendImpl<double> (sendBuffer, destRank, tag, comm);
1069 gatherv<int, double> (
const double sendBuf[],
1070 const int sendCount,
1072 const int recvCounts[],
1075 const Comm<int>& comm)
1077 gathervImpl<double> (sendBuf, sendCount, recvBuf, recvCounts, displs, root, comm);
1084 reduceAll<int, float> (
const Comm<int>& comm,
1085 const EReductionType reductType,
1087 const float sendBuffer[],
1088 float globalReducts[])
1090 TEUCHOS_COMM_TIME_MONITOR(
1091 "Teuchos::reduceAll<int, float> (" << count <<
", "
1092 << toString (reductType) <<
")"
1094 reduceAllImpl<float> (comm, reductType, count, sendBuffer, globalReducts);
1098 RCP<Teuchos::CommRequest<int> >
1099 ireceive<int, float> (
const Comm<int>& comm,
1100 const ArrayRCP<float>& recvBuffer,
1101 const int sourceRank)
1103 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, float>");
1104 return ireceiveImpl<float> (comm, recvBuffer, sourceRank);
1108 RCP<Teuchos::CommRequest<int> >
1109 ireceive<int, float> (
const ArrayRCP<float>& recvBuffer,
1110 const int sourceRank,
1112 const Comm<int>& comm)
1114 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, float>");
1115 return ireceiveImpl<float> (recvBuffer, sourceRank, tag, comm);
1120 send<int, float> (
const Comm<int>& comm,
1122 const float sendBuffer[],
1125 return sendImpl<float> (comm, count, sendBuffer, destRank);
1130 send<int, float> (
const float sendBuffer[],
1134 const Comm<int>& comm)
1136 return sendImpl<float> (sendBuffer, count, destRank, tag, comm);
1140 RCP<Teuchos::CommRequest<int> >
1141 isend (
const ArrayRCP<const float>& sendBuffer,
1144 const Comm<int>& comm)
1146 return isendImpl<float> (sendBuffer, destRank, tag, comm);
1151 gatherv<int,float> (
const float sendBuf[],
1152 const int sendCount,
1154 const int recvCounts[],
1157 const Comm<int>& comm)
1159 gathervImpl<float> (sendBuf, sendCount, recvBuf, recvCounts, displs, root, comm);
1166 gather<int, long long> (
const long long sendBuf[],
1167 const int sendCount,
1168 long long recvBuf[],
1169 const int recvCount,
1171 const Comm<int>& comm)
1173 gatherImpl<long long> (sendBuf, sendCount, recvBuf, recvCount, root, comm);
1178 gatherv<int, long long> (
const long long sendBuf[],
1179 const int sendCount,
1180 long long recvBuf[],
1181 const int recvCounts[],
1184 const Comm<int>& comm)
1186 gathervImpl<long long> (sendBuf, sendCount, recvBuf, recvCounts, displs, root, comm);
1191 reduceAll<int, long long> (
const Comm<int>& comm,
1192 const EReductionType reductType,
1194 const long long sendBuffer[],
1195 long long globalReducts[])
1197 TEUCHOS_COMM_TIME_MONITOR(
1198 "Teuchos::reduceAll<int, long long> (" << count <<
", "
1199 << toString (reductType) <<
")"
1201 reduceAllImpl<long long> (comm, reductType, count, sendBuffer, globalReducts);
1205 RCP<Teuchos::CommRequest<int> >
1206 ireceive<int, long long> (
const Comm<int>& comm,
1207 const ArrayRCP<long long>& recvBuffer,
1208 const int sourceRank)
1210 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, long long>");
1211 return ireceiveImpl<long long> (comm, recvBuffer, sourceRank);
1215 RCP<Teuchos::CommRequest<int> >
1216 ireceive<int, long long> (
const ArrayRCP<long long>& recvBuffer,
1217 const int sourceRank,
1219 const Comm<int>& comm)
1221 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, long long>");
1222 return ireceiveImpl<long long> (recvBuffer, sourceRank, tag, comm);
1227 send<int, long long> (
const Comm<int>& comm,
1229 const long long sendBuffer[],
1232 return sendImpl<long long> (comm, count, sendBuffer, destRank);
1237 send<int, long long> (
const long long sendBuffer[],
1241 const Comm<int>& comm)
1243 return sendImpl<long long> (sendBuffer, count, destRank, tag, comm);
1247 RCP<Teuchos::CommRequest<int> >
1248 isend (
const ArrayRCP<const long long>& sendBuffer,
1251 const Comm<int>& comm)
1253 return isendImpl<long long> (sendBuffer, destRank, tag, comm);
1259 gather<int, unsigned long long> (
const unsigned long long sendBuf[],
1260 const int sendCount,
1261 unsigned long long recvBuf[],
1262 const int recvCount,
1264 const Comm<int>& comm)
1266 gatherImpl<unsigned long long> (sendBuf, sendCount, recvBuf, recvCount, root, comm);
1271 gatherv<int, unsigned long long> (
const unsigned long long sendBuf[],
1272 const int sendCount,
1273 unsigned long long recvBuf[],
1274 const int recvCounts[],
1277 const Comm<int>& comm)
1279 gathervImpl<unsigned long long> (sendBuf, sendCount, recvBuf, recvCounts, displs, root, comm);
1284 reduceAll<int, unsigned long long> (
const Comm<int>& comm,
1285 const EReductionType reductType,
1287 const unsigned long long sendBuffer[],
1288 unsigned long long globalReducts[])
1290 TEUCHOS_COMM_TIME_MONITOR(
1291 "Teuchos::reduceAll<int, unsigned long long> (" << count <<
", "
1292 << toString (reductType) <<
")"
1294 reduceAllImpl<unsigned long long> (comm, reductType, count, sendBuffer, globalReducts);
1298 RCP<Teuchos::CommRequest<int> >
1299 ireceive<int, unsigned long long> (
const Comm<int>& comm,
1300 const ArrayRCP<unsigned long long>& recvBuffer,
1301 const int sourceRank)
1303 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, unsigned long long>");
1304 return ireceiveImpl<unsigned long long> (comm, recvBuffer, sourceRank);
1308 RCP<Teuchos::CommRequest<int> >
1309 ireceive<int, unsigned long long> (
const ArrayRCP<unsigned long long>& recvBuffer,
1310 const int sourceRank,
1312 const Comm<int>& comm)
1314 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, unsigned long long>");
1315 return ireceiveImpl<unsigned long long> (recvBuffer, sourceRank, tag, comm);
1320 send<int, unsigned long long> (
const Comm<int>& comm,
1322 const unsigned long long sendBuffer[],
1325 return sendImpl<unsigned long long> (comm, count, sendBuffer, destRank);
1330 send<int, unsigned long long> (
const unsigned long long sendBuffer[],
1334 const Comm<int>& comm)
1336 return sendImpl<unsigned long long> (sendBuffer, count, destRank, tag, comm);
1340 RCP<Teuchos::CommRequest<int> >
1341 isend (
const ArrayRCP<const unsigned long long>& sendBuffer,
1344 const Comm<int>& comm)
1346 return isendImpl<unsigned long long> (sendBuffer, destRank, tag, comm);
1353 gather<int, long> (
const long sendBuf[],
1354 const int sendCount,
1356 const int recvCount,
1358 const Comm<int>& comm)
1360 gatherImpl<long> (sendBuf, sendCount, recvBuf, recvCount, root, comm);
1365 gatherv<int, long> (
const long sendBuf[],
1366 const int sendCount,
1368 const int recvCounts[],
1371 const Comm<int>& comm)
1373 gathervImpl<long> (sendBuf, sendCount, recvBuf, recvCounts, displs, root, comm);
1378 reduceAll<int, long> (
const Comm<int>& comm,
1379 const EReductionType reductType,
1381 const long sendBuffer[],
1382 long globalReducts[])
1384 TEUCHOS_COMM_TIME_MONITOR(
1385 "Teuchos::reduceAll<int, long> (" << count <<
", "
1386 << toString (reductType) <<
")"
1388 reduceAllImpl<long> (comm, reductType, count, sendBuffer, globalReducts);
1392 RCP<Teuchos::CommRequest<int> >
1393 ireceive<int, long> (
const Comm<int>& comm,
1394 const ArrayRCP<long>& recvBuffer,
1395 const int sourceRank)
1397 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, long>");
1398 return ireceiveImpl<long> (comm, recvBuffer, sourceRank);
1402 RCP<Teuchos::CommRequest<int> >
1403 ireceive<int, long> (
const ArrayRCP<long>& recvBuffer,
1404 const int sourceRank,
1406 const Comm<int>& comm)
1408 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, long>");
1409 return ireceiveImpl<long> (recvBuffer, sourceRank, tag, comm);
1414 send<int, long> (
const Comm<int>& comm,
1416 const long sendBuffer[],
1419 return sendImpl<long> (comm, count, sendBuffer, destRank);
1424 send<int, long> (
const long sendBuffer[],
1428 const Comm<int>& comm)
1430 return sendImpl<long> (sendBuffer, count, destRank, tag, comm);
1434 RCP<Teuchos::CommRequest<int> >
1435 isend (
const ArrayRCP<const long>& sendBuffer,
1438 const Comm<int>& comm)
1440 return isendImpl<long> (sendBuffer, destRank, tag, comm);
1447 gather<int, unsigned long> (
const unsigned long sendBuf[],
1448 const int sendCount,
1449 unsigned long recvBuf[],
1450 const int recvCount,
1452 const Comm<int>& comm)
1454 gatherImpl<unsigned long> (sendBuf, sendCount, recvBuf, recvCount, root, comm);
1459 gatherv<int, unsigned long> (
const unsigned long sendBuf[],
1460 const int sendCount,
1461 unsigned long recvBuf[],
1462 const int recvCounts[],
1465 const Comm<int>& comm)
1467 gathervImpl<unsigned long> (sendBuf, sendCount, recvBuf, recvCounts, displs, root, comm);
1472 reduceAll<int, unsigned long> (
const Comm<int>& comm,
1473 const EReductionType reductType,
1475 const unsigned long sendBuffer[],
1476 unsigned long globalReducts[])
1478 TEUCHOS_COMM_TIME_MONITOR(
1479 "Teuchos::reduceAll<int, unsigned long> (" << count <<
", "
1480 << toString (reductType) <<
")"
1482 reduceAllImpl<unsigned long> (comm, reductType, count, sendBuffer, globalReducts);
1486 RCP<Teuchos::CommRequest<int> >
1487 ireceive<int, unsigned long> (
const Comm<int>& comm,
1488 const ArrayRCP<unsigned long>& recvBuffer,
1489 const int sourceRank)
1491 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, unsigned long>");
1492 return ireceiveImpl<unsigned long> (comm, recvBuffer, sourceRank);
1496 RCP<Teuchos::CommRequest<int> >
1497 ireceive<int, unsigned long> (
const ArrayRCP<unsigned long>& recvBuffer,
1498 const int sourceRank,
1500 const Comm<int>& comm)
1502 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, unsigned long>");
1503 return ireceiveImpl<unsigned long> (recvBuffer, sourceRank, tag, comm);
1508 send<int, unsigned long> (
const Comm<int>& comm,
1510 const unsigned long sendBuffer[],
1513 return sendImpl<unsigned long> (comm, count, sendBuffer, destRank);
1518 send<int, unsigned long> (
const unsigned long sendBuffer[],
1522 const Comm<int>& comm)
1524 return sendImpl<unsigned long> (sendBuffer, count, destRank, tag, comm);
1528 RCP<Teuchos::CommRequest<int> >
1529 isend (
const ArrayRCP<const unsigned long>& sendBuffer,
1532 const Comm<int>& comm)
1534 return isendImpl<unsigned long> (sendBuffer, destRank, tag, comm);
1540 gather<int, int> (
const int sendBuf[],
1541 const int sendCount,
1543 const int recvCount,
1545 const Comm<int>& comm)
1547 gatherImpl<int> (sendBuf, sendCount, recvBuf, recvCount, root, comm);
1552 gatherv<int, int> (
const int sendBuf[],
1553 const int sendCount,
1555 const int recvCounts[],
1558 const Comm<int>& comm)
1560 gathervImpl<int> (sendBuf, sendCount, recvBuf, recvCounts, displs, root, comm);
1565 scatter<int, int> (
const int sendBuf[],
1566 const int sendCount,
1568 const int recvCount,
1570 const Comm<int>& comm)
1572 scatterImpl<int> (sendBuf, sendCount, recvBuf, recvCount, root, comm);
1577 scatterv<int, double> (
const double sendBuf[],
1578 const int sendCount[],
1581 const int recvCount,
1583 const Comm<int>& comm)
1585 scattervImpl<double> (sendBuf, sendCount, displs, recvBuf, recvCount, root, comm);
1590 scatterv<int, float> (
const float sendBuf[],
1591 const int sendCounts[],
1594 const int recvCount,
1596 const Comm<int>& comm)
1598 scattervImpl<float> (sendBuf, sendCounts, displs, recvBuf, recvCount, root, comm);
1603 reduce<int, int> (
const int sendBuf[],
1606 const EReductionType reductType,
1608 const Comm<int>& comm)
1610 TEUCHOS_COMM_TIME_MONITOR
1611 (
"Teuchos::reduce<int, int> (" << count <<
", " << toString (reductType)
1613 reduceImpl<int> (sendBuf, recvBuf, count, reductType, root, comm);
1617 reduce<int, long> (
const long sendBuf[],
1620 const EReductionType reductType,
1622 const Comm<int>& comm)
1624 TEUCHOS_COMM_TIME_MONITOR
1625 (
"Teuchos::reduce<int, int> (" << count <<
", " << toString (reductType)
1627 reduceImpl<long> (sendBuf, recvBuf, count, reductType, root, comm);
1632 reduce<int, unsigned long> (
const unsigned long sendBuf[],
1633 unsigned long recvBuf[],
1635 const EReductionType reductType,
1637 const Comm<int>& comm)
1639 TEUCHOS_COMM_TIME_MONITOR
1640 (
"Teuchos::reduce<int, int> (" << count <<
", " << toString (reductType)
1642 reduceImpl<unsigned long> (sendBuf, recvBuf, count, reductType, root, comm);
1647 reduce<int, unsigned long long > (
const unsigned long long sendBuf[],
1648 unsigned long long recvBuf[],
1650 const EReductionType reductType,
1652 const Comm<int>& comm)
1654 TEUCHOS_COMM_TIME_MONITOR
1655 (
"Teuchos::reduce<int, int> (" << count <<
", " << toString (reductType)
1657 reduceImpl<unsigned long long> (sendBuf, recvBuf, count, reductType, root, comm);
1662 reduce<int, double> (
const double sendBuf[],
1665 const EReductionType reductType,
1667 const Comm<int>& comm)
1669 TEUCHOS_COMM_TIME_MONITOR
1670 (
"Teuchos::reduce<int, int> (" << count <<
", " << toString (reductType)
1672 reduceImpl<double> (sendBuf, recvBuf, count, reductType, root, comm);
1676 reduceAll<int, int> (
const Comm<int>& comm,
1677 const EReductionType reductType,
1679 const int sendBuffer[],
1680 int globalReducts[])
1682 TEUCHOS_COMM_TIME_MONITOR(
1683 "Teuchos::reduceAll<int, int> (" << count <<
", "
1684 << toString (reductType) <<
")"
1686 reduceAllImpl<int> (comm, reductType, count, sendBuffer, globalReducts);
1690 RCP<Teuchos::CommRequest<int> >
1691 ireceive<int, int> (
const Comm<int>& comm,
1692 const ArrayRCP<int>& recvBuffer,
1693 const int sourceRank)
1695 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, int>");
1696 return ireceiveImpl<int> (comm, recvBuffer, sourceRank);
1700 RCP<Teuchos::CommRequest<int> >
1701 ireceive<int, int> (
const ArrayRCP<int>& recvBuffer,
1702 const int sourceRank,
1704 const Comm<int>& comm)
1706 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, int>");
1707 return ireceiveImpl<int> (recvBuffer, sourceRank, tag, comm);
1712 send<int, int> (
const Comm<int>& comm,
1714 const int sendBuffer[],
1717 return sendImpl<int> (comm, count, sendBuffer, destRank);
1722 send<int, int> (
const int sendBuffer[],
1726 const Comm<int>& comm)
1728 return sendImpl<int> (sendBuffer, count, destRank, tag, comm);
1732 RCP<Teuchos::CommRequest<int> >
1733 isend (
const ArrayRCP<const int>& sendBuffer,
1736 const Comm<int>& comm)
1738 return isendImpl<int> (sendBuffer, destRank, tag, comm);
1744 gather<int, unsigned int> (
const unsigned int sendBuf[],
1745 const int sendCount,
1746 unsigned int recvBuf[],
1747 const int recvCount,
1749 const Comm<int>& comm)
1751 gatherImpl<unsigned int> (sendBuf, sendCount, recvBuf, recvCount, root, comm);
1756 gatherv<int, unsigned int> (
const unsigned int sendBuf[],
1757 const int sendCount,
1758 unsigned int recvBuf[],
1759 const int recvCounts[],
1762 const Comm<int>& comm)
1764 gathervImpl<unsigned int> (sendBuf, sendCount, recvBuf, recvCounts, displs, root, comm);
1769 reduceAll<int, unsigned int> (
const Comm<int>& comm,
1770 const EReductionType reductType,
1772 const unsigned int sendBuffer[],
1773 unsigned int globalReducts[])
1775 TEUCHOS_COMM_TIME_MONITOR(
1776 "Teuchos::reduceAll<int, unsigned int> (" << count <<
", "
1777 << toString (reductType) <<
")"
1779 reduceAllImpl<unsigned int> (comm, reductType, count, sendBuffer, globalReducts);
1783 RCP<Teuchos::CommRequest<int> >
1784 ireceive<int, unsigned int> (
const Comm<int>& comm,
1785 const ArrayRCP<unsigned int>& recvBuffer,
1786 const int sourceRank)
1788 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, unsigned int>");
1789 return ireceiveImpl<unsigned int> (comm, recvBuffer, sourceRank);
1793 RCP<Teuchos::CommRequest<int> >
1794 ireceive<int, unsigned int> (
const ArrayRCP<unsigned int>& recvBuffer,
1795 const int sourceRank,
1797 const Comm<int>& comm)
1799 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, unsigned int>");
1800 return ireceiveImpl<unsigned int> (recvBuffer, sourceRank, tag, comm);
1805 send<int, unsigned int> (
const Comm<int>& comm,
1807 const unsigned int sendBuffer[],
1810 return sendImpl<unsigned int> (comm, count, sendBuffer, destRank);
1815 send<int, unsigned int> (
const unsigned int sendBuffer[],
1819 const Comm<int>& comm)
1821 return sendImpl<unsigned int> (sendBuffer, count, destRank, tag, comm);
1825 RCP<Teuchos::CommRequest<int> >
1826 isend (
const ArrayRCP<const unsigned int>& sendBuffer,
1829 const Comm<int>& comm)
1831 return isendImpl<unsigned int> (sendBuffer, destRank, tag, comm);
1838 gather<int, short> (
const short sendBuf[],
1839 const int sendCount,
1841 const int recvCount,
1843 const Comm<int>& comm)
1845 gatherImpl<short> (sendBuf, sendCount, recvBuf, recvCount, root, comm);
1850 gatherv<int, short> (
const short sendBuf[],
1851 const int sendCount,
1853 const int recvCounts[],
1856 const Comm<int>& comm)
1858 gathervImpl<short> (sendBuf, sendCount, recvBuf, recvCounts, displs, root, comm);
1863 reduceAll<int, short> (
const Comm<int>& comm,
1864 const EReductionType reductType,
1866 const short sendBuffer[],
1867 short globalReducts[])
1869 TEUCHOS_COMM_TIME_MONITOR(
1870 "Teuchos::reduceAll<int, short> (" << count <<
", "
1871 << toString (reductType) <<
")"
1873 reduceAllImpl<short> (comm, reductType, count, sendBuffer, globalReducts);
1877 RCP<Teuchos::CommRequest<int> >
1878 ireceive<int, short> (
const Comm<int>& comm,
1879 const ArrayRCP<short>& recvBuffer,
1880 const int sourceRank)
1882 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, short>");
1883 return ireceiveImpl<short> (comm, recvBuffer, sourceRank);
1887 RCP<Teuchos::CommRequest<int> >
1888 ireceive<int, short> (
const ArrayRCP<short>& recvBuffer,
1889 const int sourceRank,
1891 const Comm<int>& comm)
1893 TEUCHOS_COMM_TIME_MONITOR(
"ireceive<int, short>");
1894 return ireceiveImpl<short> (recvBuffer, sourceRank, tag, comm);
1899 send<int, short> (
const Comm<int>& comm,
1901 const short sendBuffer[],
1904 return sendImpl<short> (comm, count, sendBuffer, destRank);
1909 send<int, short> (
const short sendBuffer[],
1913 const Comm<int>& comm)
1915 return sendImpl<short> (sendBuffer, count, destRank, tag, comm);
1919 RCP<Teuchos::CommRequest<int> >
1920 isend (
const ArrayRCP<const short>& sendBuffer,
1923 const Comm<int>& comm)
1925 return isendImpl<short> (sendBuffer, destRank, tag, comm);
1940 reduceAll<int, char> (
const Comm<int>& comm,
1941 const EReductionType reductType,
1943 const char sendBuffer[],
1944 char globalReducts[])
1946 TEUCHOS_COMM_TIME_MONITOR(
1947 "Teuchos::reduceAll<int, char> (" << count <<
", "
1948 << toString (reductType) <<
")"
1950 reduceAllImpl<char> (comm, reductType, count, sendBuffer, globalReducts);
#define TEUCHOS_TEST_FOR_EXCEPTION(throw_exception_test, Exception, msg)
Macro for throwing an exception with breakpointing to ease debugging.
Declaration of Teuchos::Details::MpiTypeTraits (only if building with MPI)