[llvm-commits] [polly] r147543 - in /polly/trunk/www: get_started.html polly.sh

Sebastian Pop spop at codeaurora.org
Wed Jan 4 12:11:19 PST 2012


Author: spop
Date: Wed Jan  4 14:11:18 2012
New Revision: 147543

URL: http://llvm.org/viewvc/llvm-project?rev=147543&view=rev
Log:
add polly.sh script

Added:
    polly/trunk/www/polly.sh
Modified:
    polly/trunk/www/get_started.html

Modified: polly/trunk/www/get_started.html
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/www/get_started.html?rev=147543&r1=147542&r2=147543&view=diff
==============================================================================
--- polly/trunk/www/get_started.html (original)
+++ polly/trunk/www/get_started.html Wed Jan  4 14:11:18 2012
@@ -150,6 +150,12 @@
 To check if Polly works correctly you can run <em>make polly-test</em> for the
 cmake build or <em>make polly-test -C tools/polly/test/</em> for the autoconf
 build.
+
+<h2> Automatize </h2>
+
+To automate the checkout, update, build, and test of Polly, one can
+use this <a href="polly.sh">script</a> that contains all the commands
+from this page in a single bash script.
 </div>
 </body>
 </html>

Added: polly/trunk/www/polly.sh
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/www/polly.sh?rev=147543&view=auto
==============================================================================
--- polly/trunk/www/polly.sh (added)
+++ polly/trunk/www/polly.sh Wed Jan  4 14:11:18 2012
@@ -0,0 +1,64 @@
+#!/bin/bash -xe
+
+export BASE=`pwd`
+export LLVM_SRC=${BASE}/llvm
+export POLLY_SRC=${LLVM_SRC}/tools/polly
+export CLOOG_SRC=${BASE}/cloog_src
+export CLOOG_INSTALL=${BASE}/cloog_install
+export LLVM_BUILD=${BASE}/llvm_build
+export SCOPLIB_DIR=${BASE}/scoplib-0.2.0
+export POCC_DIR=${BASE}/pocc-1.0-rc3.1
+
+if [ -e /proc/cpuinfo ]; then
+    procs=`cat /proc/cpuinfo | grep processor | wc -l`
+else
+    procs=1
+fi
+
+if ! test -d ${LLVM_SRC}; then
+    git clone http://llvm.org/git/llvm.git ${LLVM_SRC}
+fi
+
+if ! test -d ${POLLY_SRC}; then
+    git clone http://llvm.org/git/polly.git ${POLLY_SRC}
+fi
+
+${POLLY_SRC}/utils/checkout_cloog.sh ${CLOOG_SRC}
+cd ${CLOOG_SRC}
+
+if ! test -e ${CLOOG_SRC}/config.log; then
+    ./configure --prefix=${CLOOG_INSTALL}
+fi
+make
+make install
+cd ${BASE}
+
+if ! test -d ${POCC_DIR}; then
+    wget http://www.cse.ohio-state.edu/~pouchet/software/pocc/download/pocc-1.0-rc3.1-full.tar.gz
+    tar xzf pocc-1.0-rc3.1-full.tar.gz
+    cd ${POCC_DIR}
+    ./install.sh
+    cd ${BASE}
+fi
+export PATH=${POCC_DIR}/bin:$PATH
+
+if ! test -d ${SCOPLIB_DIR}; then
+    wget http://www.cse.ohio-state.edu/~pouchet/software/pocc/download/modules/scoplib-0.2.0.tar.gz
+    tar xzf  scoplib-0.2.0.tar.gz
+    cd ${SCOPLIB_DIR}
+    ./configure --enable-mp-version --prefix=${SCOPLIB_DIR}/usr
+    make -j${procs} -l${procs} && make install
+fi
+
+mkdir -p ${LLVM_BUILD}
+cd ${LLVM_BUILD}
+
+if which cmake ; then
+    cmake -DCMAKE_PREFIX_PATH=${CLOOG_INSTALL} ${LLVM_SRC}
+    make -j$procs -l$procs
+    make polly-test
+else
+    ${LLVM_SRC}/configure --with-cloog=${CLOOG_INSTALL} --with-isl=${CLOOG_INSTALL}
+    make -j$procs -l$procs
+    make polly-test -C tools/polly/test/
+fi





More information about the llvm-commits mailing list