diff options
| author | Ludovic Courtès <ludo@gnu.org> | 2026-03-19 12:29:53 +0100 |
|---|---|---|
| committer | Cayetano Santos <csantosb@inventati.org> | 2026-03-24 14:21:49 +0100 |
| commit | 34ead5615673c97a64f0930ea75946d18b57364e (patch) | |
| tree | b5e6a2da4d5574a78997e0355ff56345ecb5a91f /gnu/packages | |
| parent | 5591ac77724f775d2b62f5051321ea3bf34431f3 (diff) | |
Add (guix amd-gpu).
Moving these definitions to a separate module is necessary to avoid circular
references at the top-level among package modules.
* gnu/packages/rocm.scm (%default-amd-gpu-targets, current-amd-gpu-targets)
(current-amd-gpu-targets-string): Move to…
* guix/amd-gpu.scm: … here. New file.
* Makefile.am (MODULES): Add it.
Merges guix/guix!7251
Change-Id: I60496fb4d81ea0445ec176add7afc388f6790bd3
Signed-off-by: Cayetano Santos <csantosb@inventati.org>
Diffstat (limited to 'gnu/packages')
| -rw-r--r-- | gnu/packages/rocm.scm | 19 |
1 files changed, 4 insertions, 15 deletions
diff --git a/gnu/packages/rocm.scm b/gnu/packages/rocm.scm index 6b5bc632ddf..1f2175ecc17 100644 --- a/gnu/packages/rocm.scm +++ b/gnu/packages/rocm.scm @@ -26,6 +26,7 @@ #:use-module (guix utils) #:use-module (guix git-download) #:use-module (guix build-system cmake) + #:use-module (guix amd-gpu) #:use-module (gnu packages) #:use-module (gnu packages base) #:use-module (gnu packages boost) @@ -53,9 +54,9 @@ #:use-module (gnu packages xorg) #:use-module (gnu packages libffi) #:use-module (ice-9 match) - #:export (%default-amd-gpu-targets - current-amd-gpu-targets - current-amd-gpu-targets-string)) + #:re-export (%default-amd-gpu-targets + current-amd-gpu-targets + current-amd-gpu-targets-string)) ;; The components are tightly integrated and can only be upgraded as a unit. If ;; you want to upgrade ROCm, bump this version number and the version number in @@ -328,18 +329,6 @@ CPUs to execute unmodified HIP code. It is generic and does not assume a particular CPU vendor or architecture.") (license license:expat)))) -(define %default-amd-gpu-targets - '("gfx908" "gfx90a" "gfx942" "gfx1030" "gfx1100" "gfx1101" "gfx1200" "gfx1201")) - -(define-syntax-rule (current-amd-gpu-targets) - "Return the list of AMD GPU targets for this package, as a list of strings." - (or (assoc-ref (package-properties this-package) 'amd-gpu-targets) - %default-amd-gpu-targets)) - -(define-syntax-rule (current-amd-gpu-targets-string) - "Return the list of AMD GPU targets for this package, as a string separated by \";\"." - (string-join (current-amd-gpu-targets) ";")) - (define-public rocm-bandwidth-test (package (name "rocm-bandwidth-test") |
