GNU bug report logs -
#32001
[PATCH] gnu: Add pocl.
Previous Next
Reported by: Fis Trivial <ybbs.daans <at> hotmail.com>
Date: Fri, 29 Jun 2018 00:11:01 UTC
Severity: normal
Tags: patch
Done: ludo <at> gnu.org (Ludovic Courtès)
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 32001 in the body.
You can then email your comments to 32001 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
guix-patches <at> gnu.org
:
bug#32001
; Package
guix-patches
.
(Fri, 29 Jun 2018 00:11:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Fis Trivial <ybbs.daans <at> hotmail.com>
:
New bug report received and forwarded. Copy sent to
guix-patches <at> gnu.org
.
(Fri, 29 Jun 2018 00:11:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/opencl.scm (pocl): New variable.
---
gnu/packages/opencl.scm | 53 +++++++++++++++++++++++++++++++++++++++++++++++--
1 file changed, 51 insertions(+), 2 deletions(-)
diff --git a/gnu/packages/opencl.scm b/gnu/packages/opencl.scm
index 644cd95e9..14eed5248 100644
--- a/gnu/packages/opencl.scm
+++ b/gnu/packages/opencl.scm
@@ -24,11 +24,13 @@
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
#:use-module (gnu packages)
+ #:use-module (gnu packages autotools)
#:use-module (gnu packages gl)
#:use-module (gnu packages gnupg)
#:use-module (gnu packages compression)
#:use-module (gnu packages libedit)
#:use-module (gnu packages llvm)
+ #:use-module (gnu packages mpi)
#:use-module (gnu packages ncurses)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages python)
@@ -38,8 +40,8 @@
#:use-module (gnu packages xorg))
;; This file adds OpenCL implementation related packages. Due to the fact that
-;; OpenCL devices are not available during build (store environment), tests are
-;; all disabled.
+;; OpenCL devices like GPU are not available during build (store environment),
+;; tests that require such devices are all disabled.
;; Check https://lists.gnu.org/archive/html/guix-devel/2018-04/msg00293.html
(define (make-opencl-headers major-version subversion)
@@ -288,3 +290,50 @@ functions required to initialize the device, create the command queues, the
kernels and the programs, and run them on the GPU. The code also contains a
back-end for the LLVM compiler framework.")
(license license:lgpl2.1+)))
+
+(define-public pocl
+ (package
+ (name "pocl")
+ (version "1.1")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append
+ "https://github.com/pocl/pocl/archive/v"
+ version ".tar.gz"))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32
+ "0lrw3hlb0w53xzmrf2hvbda406l70ar4gyadflvlkj4879lx138y"))))
+ (build-system cmake-build-system)
+ (native-inputs
+ `(("libltdl" ,libltdl)
+ ("pkg-config" ,pkg-config)))
+ (inputs
+ `(("clang" ,clang)
+ ("hwloc" ,hwloc "lib")
+ ("llvm" ,llvm)
+ ("ocl-icd" ,ocl-icd)))
+ (arguments
+ `(#:configure-flags
+ (list "-DENABLE_ICD=ON"
+ "-DENABLE_TESTSUITES=ON"
+ ;; We are not developers, don't run conformance suite.
+ "-DENABLE_CONFORMANCE=OFF"
+ (string-append "-DEXTRA_HOST_LD_FLAGS=-L"
+ (assoc-ref %build-inputs "libc") "/lib"))
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'install 'remove-headers
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out")))
+ (delete-file-recursively
+ (string-append out "/include")))))
+ (add-before 'check 'set-HOME
+ (lambda _
+ (setenv "HOME" "/tmp")
+ #t)))))
+ (home-page "http://portablecl.org/")
+ (synopsis "Portable Computing Language (pocl), is an OpenCL implementation")
+ (description "Pocl is being developed towards an efficient implementation
+of OpenCL standard which can be easily adapted for new targets.")
+ (license license:expat)))
--
2.14.4
Information forwarded
to
guix-patches <at> gnu.org
:
bug#32001
; Package
guix-patches
.
(Mon, 02 Jul 2018 15:37:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 32001 <at> debbugs.gnu.org (full text, mbox):
Hello Fis,
Fis Trivial <ybbs.daans <at> hotmail.com> skribis:
> * gnu/packages/opencl.scm (pocl): New variable.
So this fixes the linker issue you mentioned before? Does it depend on
another patch?
Thanks,
Ludo’.
Information forwarded
to
guix-patches <at> gnu.org
:
bug#32001
; Package
guix-patches
.
(Mon, 02 Jul 2018 16:28:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 32001 <at> debbugs.gnu.org (full text, mbox):
Ludovic Courtès writes:
> Hello Fis,
>
> Fis Trivial <ybbs.daans <at> hotmail.com> skribis:
>
>> * gnu/packages/opencl.scm (pocl): New variable.
>
> So this fixes the linker issue you mentioned before? Does it depend on
> another patch?
>
> Thanks,
> Ludo’.
Yes, it fixes the linker issue, on pthread backend. Seems so trivial
... I still don't know why I would have to read the source code of
ld-wrapper, part of llvm and pocl to come up with this .. :(
Anyway, all unit tests passed. And I have boost-compute at my own repo
which uses pocl as native-input for testing in store, runs very well.
cheers
Jiaming
Reply sent
to
ludo <at> gnu.org (Ludovic Courtès)
:
You have taken responsibility.
(Tue, 03 Jul 2018 15:34:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Fis Trivial <ybbs.daans <at> hotmail.com>
:
bug acknowledged by developer.
(Tue, 03 Jul 2018 15:34:02 GMT)
Full text and
rfc822 format available.
Message #16 received at 32001-done <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Gaaming Jyun <ybbs.daans <at> hotmail.com> skribis:
> Yes, it fixes the linker issue, on pthread backend. Seems so trivial
> ... I still don't know why I would have to read the source code of
> ld-wrapper, part of llvm and pocl to come up with this .. :(
>
> Anyway, all unit tests passed. And I have boost-compute at my own repo
> which uses pocl as native-input for testing in store, runs very well.
Perfect. Applied with the changes below.
Thanks!
Ludo’.
[Message part 2 (text/x-patch, inline)]
diff --git a/gnu/packages/opencl.scm b/gnu/packages/opencl.scm
index 14eed5248..42cedd154 100644
--- a/gnu/packages/opencl.scm
+++ b/gnu/packages/opencl.scm
@@ -327,13 +327,22 @@ back-end for the LLVM compiler framework.")
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(delete-file-recursively
- (string-append out "/include")))))
+ (string-append out "/include"))
+ #t)))
(add-before 'check 'set-HOME
(lambda _
(setenv "HOME" "/tmp")
#t)))))
(home-page "http://portablecl.org/")
- (synopsis "Portable Computing Language (pocl), is an OpenCL implementation")
- (description "Pocl is being developed towards an efficient implementation
-of OpenCL standard which can be easily adapted for new targets.")
+ (synopsis "Portable Computing Language (pocl), an OpenCL implementation")
+ (description
+ "Pocl is a portable implementation of the OpenCL standard (1.2 with some
+2.0 features supported). This project seeks to improve performance
+portability of OpenCL programs with the kernel compiler and the task run-time,
+reducing the need for target-dependent manual optimizations.
+
+pocl uses Clang as an OpenCL C frontend and LLVM for kernel compiler
+implementation, and as a portability layer. Thus, if your desired target has
+an LLVM backend, it should be able to get OpenCL support easily by using
+pocl.")
(license license:expat)))
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Wed, 01 Aug 2018 11:24:04 GMT)
Full text and
rfc822 format available.
This bug report was last modified 6 years and 324 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.