PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

CUDA-x86.

same code intel compiler compiles but portland doesn't..why?
Goto page 1, 2  Next
 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling
View previous topic :: View next topic  
Author Message
Gunjan



Joined: 22 Jul 2004
Posts: 5

PostPosted: Thu Jul 22, 2004 2:35 pm    Post subject: same code intel compiler compiles but portland doesn't..why? Reply with quote

I am using the portland group compiler for a 3-d problem and it doesn't compile at all if I go above a certain resolution, though that resolution doesn't use the whole memory of the computer. The same code with same resolution gets compiled with the intel compiler. Even when i use both processors of that computer, it gives "segmentation fault" in portland group compiler. Can anybody please help me out in this.
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6070
Location: The Portland Group Inc.

PostPosted: Thu Jul 22, 2004 3:59 pm    Post subject: Re: same code intel compiler compiles but portland doesn't.. Reply with quote

I think I need a bit more information before I can give you an answer. If I understand you correctly, there are two issues. The first is that the program won't compile at a higher optimizations and the second is that when it does compile, the program seg faults?

While seg faults happen for a variety of reasons, one major cause is that the stack size is too small. You might try increasing your stack size using 'unlimit' (Assuming your on a linux system). If this doesn't work, you'd need to use pgdbg to determine where the seg faults occurs and try and diagnosis from there.

As for compilation issues, I would need to know what type of system, the compiler, and optimizations your using, and the error message generated to have any hope of determining what's wrong. If the code is small, or a small sample of the code that exhibits the same problem, please post this as well.

The more information you can provide, the more likely others can help.

- Mat
Back to top
View user's profile
Gunjan



Joined: 22 Jul 2004
Posts: 5

PostPosted: Thu Jul 22, 2004 4:59 pm    Post subject: more information Reply with quote

ya im using linux system and i want to run this program in one computer which has got 2 processors in it....and my code is related to 3-d mantle convection...so when i try to increase the resolution of the box it doesn't compile...e.g. when i use 73x73x73 resolution of the box, it compiles and run properly, but if i put 161x161x161 grid points resolution, then it doesnt compile...the messages after not compiling is given below:

solve_free.o(.text+0x650): In function `por_solve_x_':
: relocation truncated to fit: R_X86_64_PC32 itrtot_
solve_free.o(.text+0xc2e): In function `por_solve_y_':
: relocation truncated to fit: R_X86_64_PC32 itrtot_
read_write_a.o(.text+0x19a): In function `reada_':
: relocation truncated to fit: R_X86_64_PC32 rdaerr_
read_write_a.o(.text+0x3e2): In function `reada_':
: relocation truncated to fit: R_X86_64_PC32 rdaerr_
read_write_a.o(.text+0x3f5): In function `reada_':
: relocation truncated to fit: R_X86_64_PC32 rdaerr_
read_write_a.o(.text+0x7f2): In function `iread_':
: relocation truncated to fit: R_X86_64_PC32 rdaerr_
read_write_a.o(.text+0xb62): In function `isrd_':
: relocation truncated to fit: R_X86_64_PC32 rdaerr_
/usr/local/pgi/linux86-64/5.1/lib/libpgmp.a(barrier.o)(.text+0x69): In function `_mp_get_parpar':
: relocation truncated to fit: R_X86_64_32S _mp_parpar
/usr/local/pgi/linux86-64/5.1/lib/libpgmp.a(barrier.o)(.text+0x347): In function `_mp_lcpu2':
: relocation truncated to fit: R_X86_64_32S _mp_parpar
/usr/local/pgi/linux86-64/5.1/lib/libpgmp.a(barrier.o)(.text+0x382): In function `_mp_ncpus2':
: relocation truncated to fit: R_X86_64_32S _mp_parpar
/usr/local/pgi/linux86-64/5.1/lib/libpgmp.a(barrier.o)(.text+0x3e5): In function `_mp_barrier2':
: additional relocation overflows omitted from the output[/i][/b]

here read_write_a.f and solve_free.f are 2 codes which don't have any errors in it .

Now another thing is when i run the same code in both processors of the same computer, it runs only at say 73x73x73 grid point resolution, whether when i choose only one processor to run it, then i can go upto 161x161x161 grid points....in both processor case if i put more than 73x73x73 resolution, then it gives me segmentation fault when the codes run.

I am confused , because i'm not having this kind of problem when i am using the intel compiler. I am very much sure that this is not a memory problem.
[/u]
Back to top
View user's profile
mleair



Joined: 19 Jul 2004
Posts: 67
Location: Portland Group

PostPosted: Thu Jul 22, 2004 11:40 pm    Post subject: RE: doesn't compile on PGI Reply with quote

Hi,

What is the data type of the array(s) that you are trying to allocate 161x161x161? It looks like you may be exceeding the 2GB size limit of the small memory model data segment. Are you using the 64-bit compilers? If so, you may want to try compiling with -mcmodel=medium. See section 3.5 in the latest release notes for PGI Workstation 5.2:

http://www.pgroup.com/doc/pgiwsrn.pdf

Assuming this allows you to compile and link your program, you may need to increase your stack size as mentioned in another reply above. See section 3.5.3 in the release notes for an example.

-Mark
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6070
Location: The Portland Group Inc.

PostPosted: Fri Jul 23, 2004 8:00 am    Post subject: relocation message just a warning Reply with quote

FYI, the relocation messages are just warnings and shouldn't cause the compilation to fail. Are there any other messages being emitted? Also, what optimization flags are you using?

-Mat
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling All times are GMT - 7 Hours
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © phpBB Group