Date: Sunday, February 5, 2023 @ 15:18:29
  Author: tpkessler
Revision: 1392784

archrelease: copy trunk to community-testing-x86_64

Added:
  rocrand/repos/community-testing-x86_64/PKGBUILD
    (from rev 1392783, rocrand/trunk/PKGBUILD)
  rocrand/repos/community-testing-x86_64/test.cpp
    (from rev 1392783, rocrand/trunk/test.cpp)
  rocrand/repos/community-testing-x86_64/test.sh
    (from rev 1392783, rocrand/trunk/test.sh)
Deleted:
  rocrand/repos/community-testing-x86_64/PKGBUILD
  rocrand/repos/community-testing-x86_64/test.cpp
  rocrand/repos/community-testing-x86_64/test.sh

----------+
 PKGBUILD |  102 ++++++++++++++++++++++++++++++-------------------------------
 test.cpp |   72 +++++++++++++++++++++----------------------
 test.sh  |   10 ++---
 3 files changed, 92 insertions(+), 92 deletions(-)

Deleted: PKGBUILD
===================================================================
--- PKGBUILD    2023-02-05 15:18:12 UTC (rev 1392783)
+++ PKGBUILD    2023-02-05 15:18:29 UTC (rev 1392784)
@@ -1,51 +0,0 @@
-# Maintainer: Torsten Keßler <tpkessler at archlinux dot org>
-# Contributor: Jakub Okoński <[email protected]>
-pkgname=rocrand
-pkgver=5.4.2
-pkgrel=1
-pkgdesc='Pseudo-random and quasi-random number generator on ROCm'
-arch=('x86_64')
-url='https://rocrand.readthedocs.io/en/latest/'
-license=('MIT')
-depends=('hip')
-makedepends=('rocm-cmake' 'gcc-fortran' 'python')
-optdepends=('gcc-fortran: Use Fortran wrapper'
-            'python: Use Python wrapper')
-_git='https://github.com/ROCmSoftwarePlatform/rocRAND'
-_hiprand='https://github.com/ROCmSoftwarePlatform/hipRAND'
-source=("$pkgname-$pkgver.tar.gz::$_git/archive/rocm-$pkgver.tar.gz"
-        
"$pkgname-hiprand-$pkgver.tar.gz::$_hiprand/archive/20ac3db9d7462c15a3e96a6f0507cd5f2ee089c4.tar.gz")
-sha256sums=('5dcefa55f865ac03660c4d6d3cfa3f56aa5764244eec20763f4bb487efdfc8be'
-            'ee38a68c9e88056b7ecd41553e496e455dbb3fe08871ff3545430d6733070e6b')
-options=(!lto)
-_dirname="$(basename "$_git")-$(basename "${source[0]}" ".tar.gz")"
-_hipname="$(basename "$_hiprand")-$(basename "${source[1]}" ".tar.gz")"
-
-prepare() {
-  rm -r "$srcdir/$_dirname/hipRAND"
-  ln -s "$srcdir/$_hipname" "$srcdir/$_dirname/hipRAND"
-}
-
-build() {
-  # -fcf-protection is not supported by HIP, see
-  # 
https://docs.amd.com/bundle/ROCm-Compiler-Reference-Guide-v5.4/page/Appendix_A.html
-  CXXFLAGS="${CXXFLAGS} -fcf-protection=none" \
-  cmake \
-    -Wno-dev \
-    -B build \
-    -S "$_dirname" \
-    -DCMAKE_BUILD_TYPE=None \
-    -DCMAKE_TOOLCHAIN_FILE=toolchain-linux.cmake \
-    -DCMAKE_CXX_COMPILER=/opt/rocm/hip/bin/hipcc \
-    -DCMAKE_INSTALL_PREFIX=/opt/rocm
-  cmake --build build
-}
-
-package() {
-  DESTDIR="$pkgdir" cmake --install build
-
-  echo '/opt/rocm/hiprand/lib' > rocrand.conf
-  echo '/opt/rocm/rocrand/lib' >> rocrand.conf
-  install -Dm644 rocrand.conf "$pkgdir/etc/ld.so.conf.d/$pkgname.conf"
-  install -Dm644 "$_dirname/LICENSE.txt" 
"$pkgdir/usr/share/licenses/$pkgname/LICENSE"
-}

Copied: rocrand/repos/community-testing-x86_64/PKGBUILD (from rev 1392783, 
rocrand/trunk/PKGBUILD)
===================================================================
--- PKGBUILD                            (rev 0)
+++ PKGBUILD    2023-02-05 15:18:29 UTC (rev 1392784)
@@ -0,0 +1,51 @@
+# Maintainer: Torsten Keßler <tpkessler at archlinux dot org>
+# Contributor: Jakub Okoński <[email protected]>
+pkgname=rocrand
+pkgver=5.4.2
+pkgrel=2
+pkgdesc='Pseudo-random and quasi-random number generator on ROCm'
+arch=('x86_64')
+url='https://rocrand.readthedocs.io/en/latest/'
+license=('MIT')
+depends=('hip')
+makedepends=('rocm-cmake' 'gcc-fortran' 'python')
+optdepends=('gcc-fortran: Use Fortran wrapper'
+            'python: Use Python wrapper')
+_git='https://github.com/ROCmSoftwarePlatform/rocRAND'
+_hiprand='https://github.com/ROCmSoftwarePlatform/hipRAND'
+source=("$pkgname-$pkgver.tar.gz::$_git/archive/rocm-$pkgver.tar.gz"
+        
"$pkgname-hiprand-$pkgver.tar.gz::$_hiprand/archive/20ac3db9d7462c15a3e96a6f0507cd5f2ee089c4.tar.gz")
+sha256sums=('5dcefa55f865ac03660c4d6d3cfa3f56aa5764244eec20763f4bb487efdfc8be'
+            'ee38a68c9e88056b7ecd41553e496e455dbb3fe08871ff3545430d6733070e6b')
+options=(!lto)
+_dirname="$(basename "$_git")-$(basename "${source[0]}" ".tar.gz")"
+_hipname="$(basename "$_hiprand")-$(basename "${source[1]}" ".tar.gz")"
+
+prepare() {
+  rm -r "$srcdir/$_dirname/hipRAND"
+  ln -s "$srcdir/$_hipname" "$srcdir/$_dirname/hipRAND"
+}
+
+build() {
+  # -fcf-protection is not supported by HIP, see
+  # 
https://docs.amd.com/bundle/ROCm-Compiler-Reference-Guide-v5.4/page/Appendix_A.html
+  CXXFLAGS="${CXXFLAGS} -fcf-protection=none" \
+  cmake \
+    -Wno-dev \
+    -B build \
+    -S "$_dirname" \
+    -DCMAKE_BUILD_TYPE=None \
+    -DCMAKE_TOOLCHAIN_FILE=toolchain-linux.cmake \
+    -DCMAKE_CXX_COMPILER=/opt/rocm/hip/bin/hipcc \
+    -DCMAKE_INSTALL_PREFIX=/opt/rocm
+  cmake --build build
+}
+
+package() {
+  DESTDIR="$pkgdir" cmake --install build
+
+  echo '/opt/rocm/hiprand/lib' > rocrand.conf
+  echo '/opt/rocm/rocrand/lib' >> rocrand.conf
+  install -Dm644 rocrand.conf "$pkgdir/etc/ld.so.conf.d/$pkgname.conf"
+  install -Dm644 "$_dirname/LICENSE.txt" 
"$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+}

Deleted: test.cpp
===================================================================
--- test.cpp    2023-02-05 15:18:12 UTC (rev 1392783)
+++ test.cpp    2023-02-05 15:18:29 UTC (rev 1392784)
@@ -1,36 +0,0 @@
-#include <hiprand/hiprand.hpp>
-#include <vector>
-#include <numeric>
-#include <cmath>
-#include <iostream>
-
-int main()
-{
-    size_t size = 1024 * 1024;
-    float mean = -1.24f;
-    float std = 0.43f;
-    hiprandGenerator_t gen;
-    hiprandCreateGenerator(&gen, HIPRAND_RNG_PSEUDO_DEFAULT);
-
-    float *x;
-    hipMalloc((void**)&x, sizeof *x * size);
-    hiprandGenerateNormal(gen, x, size, mean, std);
-
-    std::vector<float> x_d(size);
-    hipMemcpy(x_d.data(), x, sizeof *x * size, hipMemcpyDeviceToHost);
-
-    float mean_hat = std::accumulate(x_d.begin(), x_d.end(), 0.0f) / size;
-
-    // Tolerance set so that test may at most fail in 1 of 10,000 runs
-    float tol = 3e-1;
-    if(std::abs(mean - mean_hat) > tol){
-        std::cout << "Tolerance in mean not reached:\n"
-            << mean_hat << " differs more than " << tol
-            << " from " << mean << std::endl;
-        return 1;
-    }
-    std::cout << "TESTS PASSED!" << std::endl;
-
-    hiprandDestroyGenerator(gen);
-    hipFree(x);
-}

Copied: rocrand/repos/community-testing-x86_64/test.cpp (from rev 1392783, 
rocrand/trunk/test.cpp)
===================================================================
--- test.cpp                            (rev 0)
+++ test.cpp    2023-02-05 15:18:29 UTC (rev 1392784)
@@ -0,0 +1,36 @@
+#include <hiprand/hiprand.hpp>
+#include <vector>
+#include <numeric>
+#include <cmath>
+#include <iostream>
+
+int main()
+{
+    size_t size = 1024 * 1024;
+    float mean = -1.24f;
+    float std = 0.43f;
+    hiprandGenerator_t gen;
+    hiprandCreateGenerator(&gen, HIPRAND_RNG_PSEUDO_DEFAULT);
+
+    float *x;
+    hipMalloc((void**)&x, sizeof *x * size);
+    hiprandGenerateNormal(gen, x, size, mean, std);
+
+    std::vector<float> x_d(size);
+    hipMemcpy(x_d.data(), x, sizeof *x * size, hipMemcpyDeviceToHost);
+
+    float mean_hat = std::accumulate(x_d.begin(), x_d.end(), 0.0f) / size;
+
+    // Tolerance set so that test may at most fail in 1 of 10,000 runs
+    float tol = 3e-1;
+    if(std::abs(mean - mean_hat) > tol){
+        std::cout << "Tolerance in mean not reached:\n"
+            << mean_hat << " differs more than " << tol
+            << " from " << mean << std::endl;
+        return 1;
+    }
+    std::cout << "TESTS PASSED!" << std::endl;
+
+    hiprandDestroyGenerator(gen);
+    hipFree(x);
+}

Deleted: test.sh
===================================================================
--- test.sh     2023-02-05 15:18:12 UTC (rev 1392783)
+++ test.sh     2023-02-05 15:18:29 UTC (rev 1392784)
@@ -1,5 +0,0 @@
-#! /usr/bin/env sh
-
-OUT=$(mktemp -d)
-/opt/rocm/bin/hipcc -o "$OUT"/test test.cpp -lhiprand -lrocrand
-"$OUT"/test

Copied: rocrand/repos/community-testing-x86_64/test.sh (from rev 1392783, 
rocrand/trunk/test.sh)
===================================================================
--- test.sh                             (rev 0)
+++ test.sh     2023-02-05 15:18:29 UTC (rev 1392784)
@@ -0,0 +1,5 @@
+#! /usr/bin/env sh
+
+OUT=$(mktemp -d)
+/opt/rocm/bin/hipcc -o "$OUT"/test test.cpp -lhiprand -lrocrand
+"$OUT"/test

Reply via email to