Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Nick Papior Andersen
If misalignment is the case then adding "sequence" to the data type might help. So: type :: sequence integer :: ... real :: ... end type Note that you cannot use the alignment on types with allocatables and pointers for obvious reasons. 2014-10-03 0:39 GMT+00:00 Kawashima, Takahiro

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
Dears, First of all. Really really thanks for you help, I am learning a lot. Second: I try to study the MPI_TYPE_CREATE_STRUCT and all the things look correct. I use Intel Fortran compiler and when I compile with -r8 means that I am compiling in double precision. About Nick suggestion: Coding

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Nick Papior Andersen
I would never compile a fortran program relying on a specific compiler option! I would never use r8/i8! I would highly encourage you to explicitly set the precision of each variable if you need specific variable precision. There are plenty of tutorials around for this (selected_real/int_kind).

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
Dear all, dear Nick, thanks lot. I have understood something, so I have create this variable type: TYPE tParticle SEQUENCE INTEGER :: ip INTEGER :: fake REAL:: RP(2) REAL:: QQ(4) END TYPE tParticle In the point number 2, do you mean to insert some align options?

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Nick Papior Andersen
2014-10-03 13:00 GMT+00:00 Diego Avesani : > Dear all, dear Nick, > thanks lot. > I have understood something, so I have create this variable type: > > TYPE tParticle > SEQUENCE > INTEGER :: ip > INTEGER :: fake > REAL:: RP(2) > REAL:: QQ(4)

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
Dear Nick, thanks again. After reading your post I have thought to compile as mpif90 -r8 *.f90 and to have this type variable TYPE tParticle SEQUENCE INTEGER :: ip INTEGER :: fake REAL:: RP(2) REAL:: QQ(4) END TYPE tParticle where I use fake to have 4 + 4 bytes, and

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Nick Papior Andersen
Yes, I guess this is correct. Testing is easy! Try testing! As I stated, I do not know enough about the custom type in MPI, this was my hunch feeling... 2014-10-03 13:23 GMT+00:00 Diego Avesani : > Dear Nick, > thanks again. > After reading your post I have thought to

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
Dear Nick, after that I call: CALL MPI_Sendrecv(P_SEND,nptSend,MPI_PARTICLE_TYPE,BCPU,201,& P_RECV,nptSend,MPI_PARTICLE_TYPE,TCPU,201,& MPI_COMM_WORLD,MPI_STATUS_IGNORE,MPI%iErr) but I have the following error [diedroLap:16824] *** An error occurred in MPI_Sendrecv [diedroLap:16824] ***

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Nick Papior Andersen
Well it says MPI_ERR_TYPE: invalid datatype so I guess you have done something wrong. ;) You should debug as much as you can your self. 1) Check that your type-creation calls actually proceed as expected 2) Check that your type-commit actually proceed as expected 3) Telling us that "it is not

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
Dear Nick, thank you, The important things is that the MPI_TYPE_CREATE_STRUCT works. Now I will proceed with the debug by myself, I will check MPI_TYPE_CREATE_STRUCT ierr output and other part of my program. Again thanks you Diego On 3 October 2014 15:45, Nick Papior Andersen

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
Dear all, Dear Jeff, when I use use MPI, I get /tmp/ifortiW8IBH.i90: catastrophic error: **Internal compiler error: segmentation violation signal raised** Please report this error along with the circumstances in which it occurred in a Software Problem Report. Note: File and line given may not be

[OMPI users] Compiling OpenMPI 1.8.3 with PGI 14.9

2014-10-03 Thread Maxime Boissonneault
Hi, I am trying to compile OpenMPI 1.8.3 with PGI 14.9 I am getting a severe errors here : 1956 PGC-S-0039-Use of undeclared variable INT64_T (ompi_datatype_module.c: 278) 1957 PGC-S-0039-Use of undeclared variable AINT (ompi_datatype_module.c: 278) 1958 PGC-S-0074-Non-constant expression in

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Jeff Squyres (jsquyres)
On Oct 3, 2014, at 10:38 AM, Diego Avesani wrote: > Dear all, Dear Jeff, > when I use > use MPI, I get > > /tmp/ifortiW8IBH.i90: catastrophic error: **Internal compiler error: > segmentation violation signal raised** Please report this error along with > the

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
Dear Jeff, how can I do that? Do I need to re-install OMPI? Thanks again Diego On 3 October 2014 16:47, Jeff Squyres (jsquyres) wrote: > On Oct 3, 2014, at 10:38 AM, Diego Avesani > wrote: > > > Dear all, Dear Jeff, > > when I use > > use

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Nick Papior Andersen
Might I chip in and ask "why in the name of fortran are you using -r8"? It seems like you do not really need it, more that it is a convenience flag for you (so that you have to type less?)? Again as I stated in my previous mail, I would never do that (and would discourage the use of it for almost

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
Dear all, using ifort -r8, will reduce the error, I am sure that every variable is in double precision, even when I convert an integer to a real with real(X) or when I use FLOOR. So, where con I insert the flag. Now I am converting the code with DP just to be able to debug my code What do you

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Jeff Squyres (jsquyres)
On Oct 3, 2014, at 10:55 AM, Diego Avesani wrote: > Dear Jeff, > how can I do that? Er... can you be more specific? I mentioned several things in my email. If you're asking about how to re-install OMPI compiled with -r8, please first read Nick's email (essentially

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Nick Papior Andersen
2014-10-03 15:17 GMT+00:00 Diego Avesani : > Dear all, > using ifort -r8, will reduce the error, > I am sure that every variable is in double precision, even when I convert > an integer to a real with real(X) or when I use FLOOR. > Yes, that is the whole point of -r8. It

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
Dear Jeff, Dear Nick, the question is about, inserting the FLAG for using -r8 Now I have written a simple code with select_kind to avoid -r8. I get the same error. You can find the code in the attachment. probably there is something wrong with ompi configuration What do you think? Again,

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Nick Papior Andersen
Dear Diego, Instead of instantly going about using cartesian communicators you should try and create a small test case, something like this: I have successfully runned this small snippet on my machine. As I state in the source, the culprit was the integer address size. It is inherently of type

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
dear N., here my results: 0.20002980232 0.200 1.00 0.20002980232 0.200 1.00 1.00 1.00 I suppose that in case of 0.2 we have a real that is different in double or in single precision. when I write

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Nick Papior Andersen
2014-10-03 16:27 GMT+00:00 Diego Avesani : > dear N., > here my results: > > 0.20002980232 > 0.200 >1.00 > 0.20002980232 > 0.200 >1.00 >1.00 >1.00 > > I suppose that in

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
Dear N., thanks for the explanation. really really sorry, but I am not able to see your example. where is it? thanks again Diego On 3 October 2014 18:35, Nick Papior Andersen wrote: > > > 2014-10-03 16:27 GMT+00:00 Diego Avesani : > >> dear

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Nick Papior Andersen
It is attached in the previous mail. 2014-10-03 16:47 GMT+00:00 Diego Avesani : > Dear N., > thanks for the explanation. > > really really sorry, but I am not able to see your example. where is it? > > thanks again > > > Diego > > > On 3 October 2014 18:35, Nick Papior

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Diego Avesani
Dear Nick, thanks a lot, again. Now I will write the shift part and the send and the send and receive part. I'll let you know Thanks, thanks again Diego On 3 October 2014 18:49, Nick Papior Andersen wrote: > It is attached in the previous mail. > > 2014-10-03 16:47

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread George Bosilca
Diego, I strongly suggest a careful reading of the Datatype chapter in the MPI 3.0 standard. More precisely, the example 4.18 might be of particular interest in your case, as it explains everything that you need to do in order to obtain a portable datatype, one that works in all cases

Re: [OMPI users] SENDRECV + MPI_TYPE_CREATE_STRUCT

2014-10-03 Thread Jeff Squyres (jsquyres)
On Oct 3, 2014, at 3:50 PM, George Bosilca wrote: > 1. I’m not a Fortran expert but I think that real is not MPI_DOUBLE_RECISION > but MPI_FLOAT. It's actually MPI_REAL. :-) (MPI_FLOAT is for the C "float" type) /me goes back in my Fortran hole... -- Jeff Squyres

Re: [OMPI users] Compiling OpenMPI 1.8.3 with PGI 14.9

2014-10-03 Thread Maxime Boissonneault
I figured it out. It seems like setting CPP to pgprepro isn't the right variable. Thanks, Maxime Le 2014-10-03 10:39, Maxime Boissonneault a écrit : Hi, I am trying to compile OpenMPI 1.8.3 with PGI 14.9 I am getting a severe errors here : 1956 PGC-S-0039-Use of undeclared variable