PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

Free OpenACC Webinar

Q: Error compiling 'ssm' channel in MPICH2 w/ PGI 6.0?

 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling
View previous topic :: View next topic  
Author Message
Brian Dobbins



Joined: 07 Sep 2004
Posts: 4

PostPosted: Tue Jun 14, 2005 2:52 pm    Post subject: Q: Error compiling 'ssm' channel in MPICH2 w/ PGI 6.0? Reply with quote

Hi Mat,

I'll cross-post this to the MPICH2 people, but chances are I'm just missing something simple - I'm trying to compile MPICH2-1.0.2 with PGI 6.0-4, and everything works fine when I use the 'shm' [shared memory] channel. However, switching to 'ssm' for shared memory on dual processor nodes, the compiler dies very early and leaves me the following message:

PGC-F-0249-#error -- *** No atomic memory operation specified to implement busy locks *** (./mpidu_process_locks.h: 234)
PGC/x86-64 Linux/x86-64 6.0-4: compilation aborted

This error comes up due to some code in the file mentioned in the error above - basically, it has some assembler code which is compiled when a #define is true for having GCC. This assembler code is as follows:

#define HAVE_COMPARE_AND_SWAP
static inline char
__attribute__ ((unused))
compare_and_swap (volatile long int *p, long int oldval, long int newval)
{
char ret;
long int readval;

__asm__ __volatile__ ("lock; cmpxchgq %3, %1; sete %0"
: "=q" (ret), "=m" (*p), "=a" (readval)
: "r" (newval), "m" (*p), "a" (oldval) : "memory");
return ret;
}

I don't know much about how PGI handles in-line assembler, but I briefly tried compiling this section with pgcc -c -Masmkeyword, and it failed, so I deleted the double-underscores surrounding 'asm' and 'volatile' and tried again, but still no luck:

"Recovery attempted by replacing asm by keyword gasm"

Any ideas how I can compile this while keeping it in a .c source file?

Thanks very much,
- Brian
Back to top
View user's profile
mkcolg



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

PostPosted: Wed Jun 15, 2005 9:46 am    Post subject: Reply with quote

Hi Brian,

Unfortunately, pgcc doesn't yet support extended asm statements. The good news is that we are working on adding this. We don't have a firm timeline when this work will be completed but expect it sometime in the next few releases. In the meantime, you'll need to compile this file with gcc.

Thanks,
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
Page 1 of 1

 
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