Merge branch 'charm' of charmgit:charm into charm
authorChao Mei <chaomei2@illinois.edu>
Thu, 27 May 2010 16:33:34 +0000 (11:33 -0500)
committerChao Mei <chaomei2@illinois.edu>
Thu, 27 May 2010 16:33:34 +0000 (11:33 -0500)
src/conv-core/cpuaffinity.c

index 13dd5f6259bbfa43095f99639af1edeccd36d94b..62b113f26b157ffe257cf40e4f7ce19e6ba5abbd 100644 (file)
@@ -16,6 +16,7 @@ cpu affinity.
 #include "sockRoutines.h"
 
 #define DEBUGP(x)   /* CmiPrintf x;  */
+CpvDeclare(int, myCPUAffToCore);
 
 #if CMK_HAS_SETAFFINITY || defined (_WIN32) || CMK_HAS_BINDPROCESSOR
 
@@ -156,7 +157,6 @@ int set_thread_affinity(int cpuid) {
 }
 #endif
 
-CpvDeclare(int, myCPUAffToCore);
 
 int CmiSetCPUAffinity(int mycore)
 {
@@ -641,7 +641,7 @@ void CmiInitCPUAffinity(char **argv)
   if (affinity_flag && CmiMyPe()==0)
     CmiPrintf("sched_setaffinity() is not supported, +setcpuaffinity disabled.\n");
 
-  CpvInitialize(myCPUAffToCore);
+  CpvInitialize(int, myCPUAffToCore);
   CpvAccess(myCPUAffToCore) = -1;
 }