From 3ab1c96ccc0a7ac4228fc779cfd37d5b858ce3e6 Mon Sep 17 00:00:00 2001 From: graysky Date: Mon, 8 Jun 2015 18:00:40 -0400 Subject: [PATCH] Initial import --- .SRCINFO | 19 +++++++++++++++++++ PKGBUILD | 40 ++++++++++++++++++++++++++++++++++++++++ linpack.conf | 22 ++++++++++++++++++++++ readme.install | 11 +++++++++++ runme.template | 15 +++++++++++++++ 5 files changed, 107 insertions(+) create mode 100644 .SRCINFO create mode 100644 PKGBUILD create mode 100644 linpack.conf create mode 100644 readme.install create mode 100644 runme.template diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 0000000..653c4af --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,19 @@ +pkgbase = linpack + pkgver = 11.2.2.010 + pkgrel = 1 + url = http://software.intel.com/en-us/articles/intel-math-kernel-library-linpack-download + arch = i686 + arch = x86_64 + license = custom + source = http://registrationcenter.intel.com/irc_nas/5232/l_lpk_p_11.2.2.010.tgz + source = linpack.conf + source = runme.template + sha256sums = 88fcc540425a7be8bd9e78af66474492f8c0f11d9ad4ad8a82879dc5757ffdf2 + sha256sums = d7e31c8c7e2648c8fa3c4838d98dfc39b8fadf0f74bdaa4ca52cd38277ec8254 + sha256sums = 8c880adeee3de6c0e6005e210cea0e01b471219c590e25e824298a25ab0eef31 + +pkgname = linpack + pkgdesc = Benchmark based on linear algebra excellent app for stress testing. + install = readme.install + backup = etc/linpack.conf + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 0000000..acc259e --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,40 @@ +# Contributor: graysky + +pkgname=('linpack') +pkgver=11.2.2.010 +_pkgvershort=11.2.2 +_stupid_number=5232 +pkgrel=1 +arch=('i686' 'x86_64') +license=('custom') +url="http://software.intel.com/en-us/articles/intel-math-kernel-library-linpack-download" +source=("http://registrationcenter.intel.com/irc_nas/$_stupid_number/l_lpk_p_$pkgver.tgz" +'linpack.conf' 'runme.template') +sha256sums=('88fcc540425a7be8bd9e78af66474492f8c0f11d9ad4ad8a82879dc5757ffdf2' + 'd7e31c8c7e2648c8fa3c4838d98dfc39b8fadf0f74bdaa4ca52cd38277ec8254' + '8c880adeee3de6c0e6005e210cea0e01b471219c590e25e824298a25ab0eef31') + +build() { + [[ -z "$CARCH" ]] && echo "Cannot determine architecture of this system!" && exit 1 + [[ "$CARCH" = "x86_64" ]] && bit=64 || bit=32 + export bit +} + +package_linpack() { + pkgdesc='Benchmark based on linear algebra excellent app for stress testing.' + install=readme.install + backup=(etc/linpack.conf) + _path="l_lpk_p_$pkgver/linpack_$_pkgvershort/benchmarks/linpack" + _docpath="l_lpk_p_$pkgver/linpack_$_pkgvershort/doc" + + # setup based on detected arch + sed -e "s/@TARGET_BIT@/$bit/g" linpack_runme_xeon$bit + + install -Dm755 linpack_runme_xeon$bit "$pkgdir/usr/bin/linpack_runme_xeon$bit" + install -Dm644 linpack.conf "$pkgdir/etc/linpack.conf" + install -Dm644 "$srcdir/$_docpath/lpkEULA.txt" "$pkgdir/usr/share/licenses/linpack/lpkEULA.txt" + install -Dm644 "$srcdir/$_docpath/lpksupport.txt" "$pkgdir/usr/share/doc/linpack/lpksupport.txt" + install -Dm755 "$srcdir/$_path/xlinpack_xeon$bit" "$pkgdir/usr/bin/xlinpack_xeon$bit" + install -Dm644 "$srcdir/$_path/xhelp.lpk" "$pkgdir/usr/share/doc/${pkgname}/xhelp.lpk" + cp -r "$srcdir/$_docpath/mkl_userguide" "$pkgdir/usr/share/doc/linpack" +} diff --git a/linpack.conf b/linpack.conf new file mode 100644 index 0000000..e64a880 --- /dev/null +++ b/linpack.conf @@ -0,0 +1,22 @@ +Sample Intel(R) LINPACK data file +Intel(R) LINPACK data +1 # number of tests +12600 # problem sizes +12600 # leading dimensions +100 # times to run a test +4 # alignment values (in KBytes) + +# Change the problem sizes and leading dimensions to suite your FREE physical memory +# +# Memory use = 8 x (problem size)^2 +# or +# Problem size = sqrt (memory use / 8) +# +# Consider the following as a conservative guide +# For 1 GB use a problem size and leading dimensions of 6300 +# For 2 GB use a problem size and leading dimensions of 12600 +# For 4 GB use a problem size and leading dimensions of 18900 +# For 8 GB use a problem size and leading dimensions of 25200 +# For 16 GB use a problem size and leading dimensions of 31500 +# For 32 GB use a problem size and leading dimensions of 37800 +# For 64 GB use a problem size and leading dimensions of 44100 diff --git a/readme.install b/readme.install new file mode 100644 index 0000000..06f69f0 --- /dev/null +++ b/readme.install @@ -0,0 +1,11 @@ +post_install() { + echo '-----------------------------------------------------------------------' + echo '1) Edit /etc/linpack.conf to configure memory usage for your system.' + echo + echo '2) Run the benchmark by typing:' + echo 'linpack_runme_xeon64' + echo ' or' + echo 'linpack_runme_xeon32' + echo '-----------------------------------------------------------------------' +} + diff --git a/runme.template b/runme.template new file mode 100644 index 0000000..7be7bd1 --- /dev/null +++ b/runme.template @@ -0,0 +1,15 @@ +#!/bin/bash +# +export KMP_AFFINITY=nowarnings,compact + +echo -e "Edit \E[31m/etc/linpack.conf\E[37m to adjust the amount of physical memory to consume." +echo +echo -e "Starting calculation.... hit ctrl+c to stop." +echo -e "Consult \E[31m~/lin_xeon@TARGET_BIT@.txt\E[37m for results as they are caculated." + +date +date >> ~/lin_xeon@TARGET_BIT@.txt +/usr/bin/xlinpack_xeon@TARGET_BIT@ /etc/linpack.conf >> ~/lin_xeon@TARGET_BIT@.txt +date >> ~/lin_xeon@TARGET_BIT@.txt +echo -n "Done: " +date