# GPU

**URL:** https://discourse.julialang.org/c/domain/gpu/11.md

[Latest](https://discourse.julialang.org/latest.md) · [Categories](https://discourse.julialang.org/categories.md) · [Tags](https://discourse.julialang.org/tags.md)

---

## [About the GPU category](https://discourse.julialang.org/t/about-the-gpu-category/88)

<div class="topic-metadata">

**Author:** [@vchuravy](https://discourse.julialang.org/u/vchuravy)\
**Replies:** 0

</div>

This subcategory is for discussion around GPU computing and GPU accelerated graphics. Also welcomed is discussion about the projects or packages maintained by the organisations below. Organisations JuliaGPU JuliaGL Pr…

---

## [Solving ModelingToolkit models with EnsembleGPUArray](https://discourse.julialang.org/t/solving-modelingtoolkit-models-with-ensemblegpuarray/139647)

<div class="topic-metadata">

**Author:** [@hochbean](https://discourse.julialang.org/u/hochbean)\
**Replies:** 3\
**Last updated:** [September 25, 2026, 8:39am UTC](https://discourse.julialang.org/t/solving-modelingtoolkit-models-with-ensemblegpuarray/139647 "2026-09-25T08:39:22Z")

</div>

Hi everyone, I’m running an ensemble of small (2–6 state) stiff/DAE thermal RC-network models (ModelingToolkit-built, many independent “buildings” of the same model structure with their own physical parameters) and tryi…

---

## [Seismic imaging with Julia and CUDA.jl](https://discourse.julialang.org/t/seismic-imaging-with-julia-and-cuda-jl/139609)

<div class="topic-metadata">

**Author:** [@aalquwayfili](https://discourse.julialang.org/u/aalquwayfili)\
**Replies:** 0\
**Last updated:** [September 22, 2026, 4:05pm UTC](https://discourse.julialang.org/t/seismic-imaging-with-julia-and-cuda-jl/139609 "2026-09-22T16:05:45Z")

</div>

Hey everyone, I’ve been experimenting with seismic imaging in Julia and CUDA.jl. I built a 2D model that sends waves through rock layers, records the echoes, and reconstructs the layer boundary using reverse-time migrati…

---

## ["Fixed iteration" DiffEq solvers on the GPU?](https://discourse.julialang.org/t/fixed-iteration-diffeq-solvers-on-the-gpu/139357)

<div class="topic-metadata">

**Author:** [@jl\_enthusiast](https://discourse.julialang.org/u/jl_enthusiast)\
**Replies:** 2\
**Last updated:** [September 11, 2026, 2:37pm UTC](https://discourse.julialang.org/t/fixed-iteration-diffeq-solvers-on-the-gpu/139357 "2026-09-11T14:37:32Z")

</div>

Hey, I am currently trying to (re)write some old hobby project into Julia (related to raytracing) and want to rely on the DiffEq solver interface, ideally inside a KernelAbstractions.jl kernel (as I am performing a lot …

---

## [Convolutions does not work on CUDA](https://discourse.julialang.org/t/convolutions-does-not-work-on-cuda/138703)

<div class="topic-metadata">

**Author:** [@Matej\_Zorek](https://discourse.julialang.org/u/Matej_Zorek)\
**Replies:** 0\
**Last updated:** [August 9, 2026, 12:49pm UTC](https://discourse.julialang.org/t/convolutions-does-not-work-on-cuda/138703 "2026-08-09T12:49:18Z")

</div>

Hi, I have a problem with Convolutional layers on gpu. It simply does not work. I have installed CUDA and cuDNN. GPU works for “simple” layers like Dense, LayerNorm etc, but when i try evaluate Conv it gives me an error…

---

## ["no method matching" error when running DiffEqGPU example from docs](https://discourse.julialang.org/t/no-method-matching-error-when-running-diffeqgpu-example-from-docs/138471)

<div class="topic-metadata">

**Author:** [@CourtA96](https://discourse.julialang.org/u/CourtA96)\
**Replies:** 3\
**Last updated:** [August 5, 2026, 2:52pm UTC](https://discourse.julialang.org/t/no-method-matching-error-when-running-diffeqgpu-example-from-docs/138471 "2026-08-05T14:52:51Z")

</div>

When I run the following example code from the DiffEqGPU documentation, using DiffEqGPU, OrdinaryDiffEq, StaticArrays, CUDA function lorenz(u, p, t) σ = p\[1\] ρ = p\[2\] β = p\[3\] du1 = σ \* (u\[2\] - u\[1\]) …

---

## [CUDA artifact selection for Pascal GPU](https://discourse.julialang.org/t/cuda-artifact-selection-for-pascal-gpu/137434)

<div class="topic-metadata">

**Author:** [@EGau](https://discourse.julialang.org/u/EGau)\
**Replies:** 5\
**Last updated:** [July 29, 2026, 7:49am UTC](https://discourse.julialang.org/t/cuda-artifact-selection-for-pascal-gpu/137434 "2026-07-29T07:49:28Z")

</div>

I am using CUDA.jl on a Pascal (sm\_61) hardware. Till now having driver 570xx (575xx also) worked when restricting cuDNN to v1.4.4 (so nvidia cudnn is \<v9.10.0, later Pascal is deprecated). This restricted also CUDA.jl …

---

## [What's the status of image convolutions on CPU & GPU?](https://discourse.julialang.org/t/whats-the-status-of-image-convolutions-on-cpu-gpu/6093)

<div class="topic-metadata">

**Author:** [@dfdx](https://discourse.julialang.org/u/dfdx)\
**Replies:** 44\
**Last updated:** [July 24, 2026, 8:17pm UTC](https://discourse.julialang.org/t/whats-the-status-of-image-convolutions-on-cpu-gpu/6093 "2026-07-24T20:17:02Z")

</div>

Most deep learning libraries rely on the same set of primitive functions such as matrix multiplication, element-wise operations, activation functions etc., and convolutions. Also, most of the code should run either on GP…

---

## [Blog post on GPU ecosystem](https://discourse.julialang.org/t/blog-post-on-gpu-ecosystem/137971)

<div class="topic-metadata">

**Author:** [@gdalle](https://discourse.julialang.org/u/gdalle)\
**Replies:** 0\
**Last updated:** [July 6, 2026, 1:28pm UTC](https://discourse.julialang.org/t/blog-post-on-gpu-ecosystem/137971 "2026-07-06T13:28:50Z")

</div>

Hi all! Following discussions on Slack, I got a blog post started to list the major packages in Julia’s GPU ecosystem and show how they interact. It’s getting close to completion and I would appreciate reviews / suggest…

---

## [GPU (CUDA) vs CPU QR decomposition performance of dense wide complex matrix](https://discourse.julialang.org/t/gpu-cuda-vs-cpu-qr-decomposition-performance-of-dense-wide-complex-matrix/137448)

<div class="topic-metadata">

**Author:** [@BambOoxX](https://discourse.julialang.org/u/BambOoxX)\
**Replies:** 0\
**Last updated:** [June 4, 2026, 3:54pm UTC](https://discourse.julialang.org/t/gpu-cuda-vs-cpu-qr-decomposition-performance-of-dense-wide-complex-matrix/137448 "2026-06-04T15:54:00Z")

</div>

Hello all, I have an algorithm that requires to compute the QR decomposition (though I’m only interested in R) of a wide complex double precision matrix with a typical size of (400 rows x 16000 columns). I have squeeze…

---

## [CUDA backward real complex FFT](https://discourse.julialang.org/t/cuda-backward-real-complex-fft/137254)

<div class="topic-metadata">

**Author:** [@FerreolS](https://discourse.julialang.org/u/FerreolS)\
**Replies:** 2\
**Last updated:** [May 23, 2026, 9:12pm UTC](https://discourse.julialang.org/t/cuda-backward-real-complex-fft/137254 "2026-05-23T21:12:58Z")

</div>

I’m trying to perform a convolution using CUDA fft and something puzzle me when comparing CPU and GPU result: using Adapt, CUDA, FFTW, AbstractFFTs T = Float32 sz = (2048,2048) x = randn(T,sz); x\_gpu = adapt(CuArray,x);…

---

## [CUDA.jl random number generation](https://discourse.julialang.org/t/cuda-jl-random-number-generation/137209)

<div class="topic-metadata">

**Author:** [@shiroghost](https://discourse.julialang.org/u/shiroghost)\
**Replies:** 2\
**Last updated:** [May 20, 2026, 11:11am UTC](https://discourse.julialang.org/t/cuda-jl-random-number-generation/137209 "2026-05-20T11:11:29Z")

</div>

Hi all, I am trying to understand Random Numbers generated in CUDA. In particular which RNG is used in each version/case. If I understood this correctly: using CUDA v = randn(Float64, N) will use CUDA.jl interface, …

---

## [Metal 4 TensorOps](https://discourse.julialang.org/t/metal-4-tensorops/137202)

<div class="topic-metadata">

**Author:** [@JarJar](https://discourse.julialang.org/u/JarJar)\
**Replies:** 0\
**Last updated:** [May 19, 2026, 10:46pm UTC](https://discourse.julialang.org/t/metal-4-tensorops/137202 "2026-05-19T22:46:54Z")

</div>

Hi, Does Metal.jl support the new Metal 4 TensorOps API? Thanks!

---

## [CUDA.jl with @threads causing memory leak?](https://discourse.julialang.org/t/cuda-jl-with-threads-causing-memory-leak/136853)

<div class="topic-metadata">

**Author:** [@noetheriankoala](https://discourse.julialang.org/u/noetheriankoala)\
**Replies:** 3\
**Last updated:** [April 27, 2026, 10:23pm UTC](https://discourse.julialang.org/t/cuda-jl-with-threads-causing-memory-leak/136853 "2026-04-27T22:23:37Z")

</div>

Hello. First of all, I am using Julia v1.12.6, CUDA v5.11.2, and FLoops v0.2.2. Consider the following code and comments. using CUDA using Base.Threads function func1() A = CuArray{Float64}(undef, 1500, 1500, 1000)…

---

## [Argmax mapreduce on GPU](https://discourse.julialang.org/t/argmax-mapreduce-on-gpu/134971)

<div class="topic-metadata">

**Author:** [@noetheriankoala](https://discourse.julialang.org/u/noetheriankoala)\
**Replies:** 6\
**Last updated:** [April 21, 2026, 9:35am UTC](https://discourse.julialang.org/t/argmax-mapreduce-on-gpu/134971 "2026-04-21T09:35:03Z")

</div>

Hello! I am trying to quickly compute \\text{argmax}\_{\\substack{1 \\leq s \\leq k\\\\ k+1 \\leq t \\leq n}} A\_{s,t} + (1-\\ell\_s)(1 + \\ell\_t) I do this on the CPU with the following code. f = ((i, j),) -\> (i, j, A\[i, j\]^2 + …

---

## [Migrating CUDA.jl atomic operations to ParallelStencil.jl using Atomix.jl?](https://discourse.julialang.org/t/migrating-cuda-jl-atomic-operations-to-parallelstencil-jl-using-atomix-jl/136710)

<div class="topic-metadata">

**Author:** [@Ludovic\_Dumoulin](https://discourse.julialang.org/u/Ludovic_Dumoulin)\
**Replies:** 2\
**Last updated:** [April 14, 2026, 1:57pm UTC](https://discourse.julialang.org/t/migrating-cuda-jl-atomic-operations-to-parallelstencil-jl-using-atomix-jl/136710 "2026-04-14T13:57:33Z")

</div>

Hello, I am currently porting my code from CUDA.jl to ParallelStencil.jl. While I have successfully managed the transition for mixed Float64 and ComplexF64 types, I have run into a challenge replacing CUDA-specific atom…

---

## [Choosing between KernelAbstractions, AcceleratedKernels, ParallelStencils, or just CUDA.jl](https://discourse.julialang.org/t/choosing-between-kernelabstractions-acceleratedkernels-parallelstencils-or-just-cuda-jl/135833)

<div class="topic-metadata">

**Author:** [@Ludovic\_Dumoulin](https://discourse.julialang.org/u/Ludovic_Dumoulin)\
**Replies:** 18\
**Last updated:** [March 18, 2026, 3:38pm UTC](https://discourse.julialang.org/t/choosing-between-kernelabstractions-acceleratedkernels-parallelstencils-or-just-cuda-jl/135833 "2026-03-18T15:38:30Z")

</div>

Hello, Until today, I have used mainly CUDA.jl to run simulations. I mostly do hydrodynamics and solve various PDEs. I would like to make my code available for other users in my lab, to be able to run simulations also …

---

## [DiffEqGPU - error calling solve() for SDE driven by 2 correlated Brownians](https://discourse.julialang.org/t/diffeqgpu-error-calling-solve-for-sde-driven-by-2-correlated-brownians/136118)

<div class="topic-metadata">

**Author:** [@sob](https://discourse.julialang.org/u/sob)\
**Replies:** 7\
**Last updated:** [March 17, 2026, 12:39pm UTC](https://discourse.julialang.org/t/diffeqgpu-error-calling-solve-for-sde-driven-by-2-correlated-brownians/136118 "2026-03-17T12:39:03Z")

</div>

Julia version: latest stable 1.12.5 on Linux, up to date on packages I have a 2D SDE driven by 2 Brownians with correlation ρ, and I’m trying to solve on the GPU using SciML. I should note that I am separately able to M…

---

## [GPU performance degradation due to 'A \\ B' calculation](https://discourse.julialang.org/t/gpu-performance-degradation-due-to-a-b-calculation/136072)

<div class="topic-metadata">

**Author:** [@WG-ZHENG](https://discourse.julialang.org/u/WG-ZHENG)\
**Replies:** 7\
**Last updated:** [March 6, 2026, 8:35pm UTC](https://discourse.julialang.org/t/gpu-performance-degradation-due-to-a-b-calculation/136072 "2026-03-06T20:35:30Z")

</div>

I was trying to accelerate my algorithm via CUDA.jl. Howerver, it is frustrating that the GPU version of the computing runs slower than the CPU one. The CPU version of key calculations in my algorithm is defined as belo…

---

## [How to ensure reproducibility when using CUDA.rand()?](https://discourse.julialang.org/t/how-to-ensure-reproducibility-when-using-cuda-rand/135987)

<div class="topic-metadata">

**Author:** [@WG-ZHENG](https://discourse.julialang.org/u/WG-ZHENG)\
**Replies:** 3\
**Last updated:** [March 3, 2026, 9:19am UTC](https://discourse.julialang.org/t/how-to-ensure-reproducibility-when-using-cuda-rand/135987 "2026-03-03T09:19:32Z")

</div>

It seems that it is not supported to pass a specified rng as argument to rand in CUDA.jl. The codes below raise an error: using CUDA rng = CUDA.RNG(42) a = CUDA.rand(rng, 1) ERROR: MethodError: no method matching rand…

---

## [Memory Scratch Allocation Strategy Recommendations](https://discourse.julialang.org/t/memory-scratch-allocation-strategy-recommendations/135921)

<div class="topic-metadata">

**Author:** [@termi-official](https://discourse.julialang.org/u/termi-official)\
**Replies:** 1\
**Last updated:** [February 28, 2026, 7:16pm UTC](https://discourse.julialang.org/t/memory-scratch-allocation-strategy-recommendations/135921 "2026-02-28T19:16:02Z")

</div>

I have some small GPU program (finite element assembly of a heat problem) which I have written using a combination of CUDA and KernelAbstractions. The main kernel will be called repeatedly, so I want to preallocate the n…

---

## [CUDA package having issues due to different versions of CUDA toolkit and NVIDIA driver CUDA version](https://discourse.julialang.org/t/cuda-package-having-issues-due-to-different-versions-of-cuda-toolkit-and-nvidia-driver-cuda-version/134755)

<div class="topic-metadata">

**Author:** [@Aditya747S](https://discourse.julialang.org/u/Aditya747S)\
**Replies:** 11\
**Last updated:** [January 24, 2026, 10:20pm UTC](https://discourse.julialang.org/t/cuda-package-having-issues-due-to-different-versions-of-cuda-toolkit-and-nvidia-driver-cuda-version/134755 "2026-01-24T22:20:48Z")

</div>

I have CUDA toolkit for CUDA 13.0 and my drivers have CUDA 13.1 which is why I am getting this error in julia Error: You are using CUDA 13.1.0, but CUDA.jl was precompiled for CUDA 13.0.0. │ │ This is unexpected; pleas…

---

## [Converting result of round or floor as Int in Metal](https://discourse.julialang.org/t/converting-result-of-round-or-floor-as-int-in-metal/98545)

<div class="topic-metadata">

**Author:** [@f.ij](https://discourse.julialang.org/u/f.ij)\
**Replies:** 10\
**Last updated:** [December 31, 2025, 5:35pm UTC](https://discourse.julialang.org/t/converting-result-of-round-or-floor-as-int-in-metal/98545 "2025-12-31T17:35:27Z")

</div>

I’m trying to get into GPU programming and I’m trying to write a simple kernel that calculates the correlation function of an image. I’ve run into a problem where I cannot convert the result of the round or floor functio…

---

## [Why Atomix.@atomic b\[\] += a\[i\] works and b\[\] = b\[\] + a\[i\] does not](https://discourse.julialang.org/t/why-atomix-atomic-b-a-i-works-and-b-b-a-i-does-not/134627)

<div class="topic-metadata">

**Author:** [@Tomas\_Pevny](https://discourse.julialang.org/u/Tomas_Pevny)\
**Replies:** 6\
**Last updated:** [December 18, 2025, 10:48am UTC](https://discourse.julialang.org/t/why-atomix-atomic-b-a-i-works-and-b-b-a-i-does-not/134627 "2025-12-18T10:48:02Z")

</div>

Hi all, I am updating my lecture on GPU programming and this year, I would like to have kernels written in CUDA.jl and KernelAbstractions.jl side by side. The idea is to show students, how GPU accelerators are similar a…

---

## [Failed to precompile CUDA](https://discourse.julialang.org/t/failed-to-precompile-cuda/134255)

<div class="topic-metadata">

**Author:** [@WuSiren](https://discourse.julialang.org/u/WuSiren)\
**Replies:** 14\
**Last updated:** [December 16, 2025, 10:59pm UTC](https://discourse.julialang.org/t/failed-to-precompile-cuda/134255 "2025-12-16T22:59:21Z")

</div>

julia\> using CUDA ┌ Warning: Circular dependency detected. Precompilation will be skipped for: │ SparseArraysExt \[85068d23-b5fb-53f1-8204-05c2aba6942f\] │ AtomixCUDAExt \[13011619-4c7c-5ef0-948f-5fc81565cd05\] │ Linea…

---

## [CUDA test failure](https://discourse.julialang.org/t/cuda-test-failure/134371)

<div class="topic-metadata">

**Author:** [@aklocker](https://discourse.julialang.org/u/aklocker)\
**Replies:** 8\
**Last updated:** [December 9, 2025, 12:57pm UTC](https://discourse.julialang.org/t/cuda-test-failure/134371 "2025-12-09T12:57:47Z")

</div>

Hi, I’m new to Julia and GPU computing. I installed CUDA and ran \]test CUDA to check it is working. When I do this I get the following errors: Info: Testing using device 0 (NVIDIA GH200 120GB). To change this, specify…

---

## [Block/Tile-Based GPU Programming (not Scratch)](https://discourse.julialang.org/t/block-tile-based-gpu-programming-not-scratch/127731)

<div class="topic-metadata">

**Author:** [@NonDairyNeutrino](https://discourse.julialang.org/u/NonDairyNeutrino)\
**Replies:** 3\
**Last updated:** [December 8, 2025, 5:20am UTC](https://discourse.julialang.org/t/block-tile-based-gpu-programming-not-scratch/127731 "2025-12-08T05:20:14Z")

</div>

I just found that there’s this new (at least to me) GPU programming framework called “Block/Tile-Based”, whether it’s “block” or “tile” seems to depend on who you ask. The three I’ve just seen are OpenAI’s Triton, NVIDI…

---

## [KernelAbstractions + CUDA + Reactant - how to get minimal working example](https://discourse.julialang.org/t/kernelabstractions-cuda-reactant-how-to-get-minimal-working-example/134164)

<div class="topic-metadata">

**Author:** [@Jakub\_Mitura](https://discourse.julialang.org/u/Jakub_Mitura)\
**Replies:** 12\
**Last updated:** [November 30, 2025, 6:34am UTC](https://discourse.julialang.org/t/kernelabstractions-cuda-reactant-how-to-get-minimal-working-example/134164 "2025-11-30T06:34:06Z")

</div>

Hello I tried to get minimal working example for reactant powered kernel abstractions plus Enzyme like using Pkg Pkg.activate(".") using Reactant using KernelAbstractions using CUDA using Enzyme using Test # Simple squ…

---

## [Potential issues with implementation of ziggurat algorithm](https://discourse.julialang.org/t/potential-issues-with-implementation-of-ziggurat-algorithm/134130)

<div class="topic-metadata">

**Author:** [@MrBelette](https://discourse.julialang.org/u/MrBelette)\
**Replies:** 0\
**Last updated:** [November 26, 2025, 2:03am UTC](https://discourse.julialang.org/t/potential-issues-with-implementation-of-ziggurat-algorithm/134130 "2025-11-26T02:03:09Z")

</div>

I’m seeing intermittent failures to finish issues when repeatedly running a kernel that calls randn many times. I’m wondering if someone can independently verify this behaviour, so I can decide if a bug needs to be repo…

---

## [Error in testset gpuarrays/linalg/core](https://discourse.julialang.org/t/error-in-testset-gpuarrays-linalg-core/134091)

<div class="topic-metadata">

**Author:** [@Roger\_Powell](https://discourse.julialang.org/u/Roger_Powell)\
**Replies:** 2\
**Last updated:** [November 25, 2025, 11:48am UTC](https://discourse.julialang.org/t/error-in-testset-gpuarrays-linalg-core/134091 "2025-11-25T11:48:08Z")

</div>

First time user of CUDA.jl. My Julia versioninfo() is Julia Version 1.12.2 Commit ca9b6662be4 (2025-11-20 16:25 UTC) Build Info: Official https://julialang.org release Platform Info: OS: Linux (x86\_64-linux-gnu) C…

[Next page](https://discourse.julialang.org/c/domain/gpu/11.md?page=1)
