multicore for linux-ppc, tested on turing
authorGengbin Zheng <gzheng@illinois.edu>
Fri, 6 Mar 2009 08:10:14 +0000 (08:10 +0000)
committerGengbin Zheng <gzheng@illinois.edu>
Fri, 6 Mar 2009 08:10:14 +0000 (08:10 +0000)
src/arch/multicore-linux-ppc/conv-mach.h [new file with mode: 0644]
src/arch/multicore-linux-ppc/conv-mach.sh [new file with mode: 0644]

diff --git a/src/arch/multicore-linux-ppc/conv-mach.h b/src/arch/multicore-linux-ppc/conv-mach.h
new file mode 100644 (file)
index 0000000..f2d98a8
--- /dev/null
@@ -0,0 +1,84 @@
+/*****************************************************************************
+ * $Source$
+ * $Author$
+ * $Date$
+ * $Revision$
+ *****************************************************************************/
+
+#ifndef _CONV_MACH_H
+#define _CONV_MACH_H
+
+#define CMK_SMP                                            1
+#define CMK_MULTICORE                                      1
+
+#define CMK_ASYNC_NOT_NEEDED                               0
+#define CMK_ASYNC_USE_FIOASYNC_AND_FIOSETOWN               0
+#define CMK_ASYNC_USE_FIOASYNC_AND_SIOCSPGRP               0
+#define CMK_ASYNC_USE_FIOSSAIOSTAT_AND_FIOSSAIOOWN         0
+#define CMK_ASYNC_USE_F_SETFL_AND_F_SETOWN                 1
+
+#define CMK_GETPAGESIZE_AVAILABLE                          0
+
+#define CMK_MALLOC_USE_GNU_MALLOC                          0
+#define CMK_MALLOC_USE_OS_BUILTIN                          1
+
+#define CMK_MEMORY_PAGESIZE                                4096
+#define CMK_MEMORY_PROTECTABLE                             0
+
+#define CMK_NODE_QUEUE_AVAILABLE                           1
+
+#define CMK_RSH_IS_A_COMMAND                               1
+#define CMK_RSH_NOT_NEEDED                                 0
+#define CMK_RSH_USE_REMSH                                  0
+
+#define CMK_SHARED_VARS_UNAVAILABLE                        0
+#define CMK_SHARED_VARS_UNIPROCESSOR                       0
+#define CMK_SHARED_VARS_POSIX_THREADS_SMP                  1
+
+#define CMK_THREADS_USE_CONTEXT                            1
+#define CMK_THREADS_USE_PTHREADS                           0
+#define CMK_THREADS_ARE_WIN32_FIBERS                       0
+
+#define CMK_SIGNAL_NOT_NEEDED                              0
+#define CMK_SIGNAL_USE_SIGACTION                           1
+#define CMK_SIGNAL_USE_SIGACTION_WITH_RESTART              0
+
+#define CMK_THREADS_REQUIRE_NO_CPV                         0
+#define CMK_THREADS_COPY_STACK                             0
+
+#define CMK_TIMER_USE_RDTSC                                0
+#define CMK_TIMER_USE_GETRUSAGE                            1
+#define CMK_TIMER_USE_SPECIAL                              0
+#define CMK_TIMER_USE_TIMES                                0
+
+#define CMK_TYPEDEF_INT2 short
+#define CMK_TYPEDEF_INT4 int
+#define CMK_TYPEDEF_INT8 long long
+#define CMK_TYPEDEF_UINT2 unsigned short
+#define CMK_TYPEDEF_UINT4 unsigned int
+#define CMK_TYPEDEF_UINT8 unsigned long long
+#define CMK_TYPEDEF_FLOAT4 float
+#define CMK_TYPEDEF_FLOAT8 double
+
+#define CMK_WHEN_PROCESSOR_IDLE_BUSYWAIT                   0
+#define CMK_WHEN_PROCESSOR_IDLE_USLEEP                     1
+
+
+#define CMK_DEBUG_MODE                                    0 
+#define CMK_WEB_MODE                                       1
+
+#define CMK_LBDB_ON                                       1
+
+#define CMK_STACKSIZE_DEFAULT                              65536
+
+#define __ONESIDED_IMPL 1
+#define __ONESIDED_NO_HARDWARE  1
+
+#define CMK_MMAP_PROBE                                      1
+
+/*#define CMK_PCQUEUE_LOCK                                   1  */
+/*#define CMK_USE_TLS_THREAD                                 1 */
+
+#endif
+
+
diff --git a/src/arch/multicore-linux-ppc/conv-mach.sh b/src/arch/multicore-linux-ppc/conv-mach.sh
new file mode 100644 (file)
index 0000000..9109b09
--- /dev/null
@@ -0,0 +1,44 @@
+CMK_DEFS=' -D_REENTRANT '
+CMK_CPP_CHARM="/lib/cpp -P"
+CMK_CPP_C="gcc -E"
+CMK_CC="gcc -fPIC $CMK_DEFS "
+CMK_CXX="g++ -fPIC $CMK_DEFS "
+CMK_CXXPP="$CMK_CXX -x c++ -E "
+CMK_RANLIB="ranlib"
+CMK_LIBS="-lckqt -lpthread"
+#CMK_LD="$CMK_CC -Wl,--allow-multiple-definition "
+#CMK_LDXX="$CMK_CXX -Wl,--allow-multiple-definition "
+CMK_LD="$CMK_CC  $CMK_DEFS "
+CMK_LDXX="$CMK_CXX  $CMK_DEFS "
+CMK_LD_SHARED="-shared"
+CMK_LD_LIBRARY_PATH="-Wl,-rpath,$CHARMLIBSO/"
+CMK_XIOPTS=""
+CMK_QT="linux-smp"
+
+# fortran compiler Absoft or gnu f95
+CMK_CF77="g77 "
+CMK_F77LIBS="-lg2c "
+CMK_CF90=`which xlf90_r 2>/dev/null`
+if test -n "$CMK_CF90"
+then
+# xlf
+  bindir=`dirname $CMK_CF90`
+  libdir="$bindir/../lib"
+  CMK_CF90="$CMK_CF90 -qpic=large -qthreaded -qlanglvl=90std -qwarn64 -qspill=32648 -qsuppress=1513-029:1518-012:1518-059 -qsuffix=f=f90:cpp=F90 "
+  CMK_CF90_FIXED="$CMK_CF90 -qsuffix=f=f:cpp=F -qfixed=132 "
+  CMK_F90LIBS="-L/opt/ibmcmp/xlf/11.1/bin/../../../xlsmp/1.7/lib -L$libdir -lxl -lxlf90 -lxlfmath -lxlopt -lxlsmp"
+  CMK_F90_USE_MODDIR=1
+  CMK_F90_MODINC="-I"
+else
+# gnu f95
+  CMK_CF90=`which f95 2>/dev/null`
+  if test -n "$CMK_CF90"
+  then
+    CMK_FPP="/lib/cpp -P -CC"
+    CMK_CF90="$CMK_CF90 -fpic -fautomatic -fdollar-ok "
+    CMK_CF90_FIXED="$CMK_CF90 -ffixed-form "
+    CMK_F90LIBS="-lgfortran "
+    CMK_F90_USE_MODDIR=1
+    CMK_F90_MODINC="-I"
+  fi
+fi