Skip to content

Julia 1.14 compatibility; CI step selection - #3299

Merged
maleadt merged 8 commits into
mainfrom
tb/julia-1.14
Sep 26, 2026
Merged

maleadt merged 8 commits into
mainfrom
tb/julia-1.14

Conversation

@maleadt

@maleadt maleadt commented Sep 25, 2026 •

Copy link
Copy Markdown
Member

On main, nightly (1.14) fails from the first kernel using sync_threads onward.

  • CI: [only X]/[skip X] take comma-separated step tags, as in GPUCompiler: julia, nightly (new, separate from julia), cuda, downstream, special, docs, benchmarks, and tests for all test steps. Draft PRs only test the newest release (1.13) and nightly; older releases and everything else run once the PR is ready. Steps share their definition through YAML anchors. The README section is updated; it still listed a subpackages tag that no longer exists.
  • LLVM 21 intrinsics: Julia 1.14 uses LLVM 22. LLVM 21 removed llvm.nvvm.barrier0{,.popc,.and,.or}, barrier.sync, ex2.approx.f and atomic.load.{inc,dec}. llvmcall of a removed intrinsic silently compiles into a run-time jl_error, so every kernel using sync_threads threw a error was thrown during kernel execution. On LLVM ≥ 21 we now use barrier.cta.*, the overloaded ex2.approx.f32, and atomicrmw uinc_wrap/udec_wrap. Report llvmcall of unknown intrinsics at compile time GPUCompiler.jl#958 makes such calls a compile-time error in the future.
  • Bounds errors: the generic checkbounds (e.g. for views) now throws through Base._throw_boundserror_indices (Fix --trim compatibility for BoundsError JuliaLang/julia#61561), which bypassed our override and lost the exception type. Overridden too, with a test.
  • Type broadcasts: 1.14 specializes type arguments on Core.TypeEgal{T} (type system: Add TypeEgal kind JuliaLang/julia#62001), which the Broadcasted{…, Type{T}} adaptor rule didn't match, so Float32.(x) failed to compile. It now matches <:Type{T}.
  • Functions capturing a type: LinearAlgebra's triangular det now reduces with Base.Fix1(convert, T) (Check that matrix is square in det triangular fast-path JuliaLang/LinearAlgebra.jl#1658), which isn't isbits. Fix1/Fix2 capturing a type are converted to closures.
  • Tests: :module expressions carry the syntax version as a first argument on 1.14.

With JuliaGPU/GPUCompiler.jl#956 (write barriers), the full test suite passes locally on nightly (1.14.0-DEV.3363, RTX 5080). That's in GPUCompiler 2.9, which this PR now requires.

@codecov

codecov Bot commented Sep 25, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 40.74074% with 16 lines in your changes missing coverage. Please review.
✅ Project coverage is 38.43%. Comparing base (0046107) to head (c226270).

Files with missing lines Patch % Lines
CUDACore/src/device/intrinsics/synchronization.jl 43.75% 9 Missing ⚠️
CUDACore/src/compiler/execution.jl 0.00% 4 Missing ⚠️
CUDACore/src/device/quirks.jl 0.00% 2 Missing ⚠️
CUDACore/src/device/intrinsics/atomics.jl 66.66% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main    #3299       +/-   ##
===========================================
- Coverage   82.29%   38.43%   -43.87%     
===========================================
  Files         186      187        +1     
  Lines       18913    18607      -306     
===========================================
- Hits        15565     7151     -8414     
- Misses       3348    11456     +8108     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

maleadt and others added 8 commits September 26, 2026 08:27
Adopt GPUCompiler's commit message grammar, where `[only ...]` and
`[skip ...]` take a comma-separated list of step tags, e.g. `[only
nightly]` or `[skip special, docs]`, and add a separate `nightly` tag.
To save CI time, draft pull requests only test the newest Julia release
and nightly; older releases run once the pull request is marked ready.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Julia 1.14 reports bounds errors from the generic `checkbounds`, as used
e.g. when indexing views, through `Base._throw_boundserror_indices`
(JuliaLang/julia#61561), bypassing the `throw_boundserror` override so
that the exception was reported without its type and message.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Julia 1.14 specializes type-valued arguments on `Core.TypeEgal{T}`
(JuliaLang/julia#62001), so a broadcast of a type constructor has
`TypeEgal{T}` as its function type parameter. That isn't matched by
the `Type{T}` in our adaptor rule, which replaces the non-isbits type
with a closure, making such broadcasts fail to compile. Match any
subtype of `Type{T}` instead.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
LLVM 21 replaced the `llvm.nvvm.barrier0` family and `barrier.sync` with
`barrier.cta` intrinsics, and made `ex2.approx` overloaded. Julia 1.14
uses LLVM 22, where `llvmcall` of the old names fails to resolve and
silently compiles into a run-time error, breaking every kernel using
`sync_threads`.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
LLVM 21 removed the `llvm.nvvm.atomic.load.inc/dec` intrinsics in favor
of the corresponding `atomicrmw` operations, so on Julia 1.14 these calls
compiled into a run-time error.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
LinearAlgebra's `det` of triangular matrices now reduces with
`Base.Fix1(convert, T)`, which isn't isbits (JuliaLang/LinearAlgebra.jl#1658).
Convert `Fix1` and `Fix2` capturing a type into closures that carry the
type as a parameter instead, like we already do for broadcasting types.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Julia 1.14 prepends the syntax version to the arguments of `:module`
expressions, so the name and body are now the last two arguments.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@maleadt
maleadt marked this pull request as ready for review September 26, 2026 06:29
@maleadt
maleadt merged commit f8606eb into main Sep 26, 2026
1 check passed
@maleadt
maleadt deleted the tb/julia-1.14 branch September 26, 2026 13:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant