-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use ThreadSafeModule/Context on Julia 1.9 #324
Conversation
Maybe add a rule here to not run the Buildkite reverse CI while the PR is in draft -- those tests are fairly expensive. CUDA.jl has such a check for some of the more expensive jobs. |
@pchintalapudi reminder that we need a fix for |
We can always temporarily use LLVM.jl to render the IR on 1.9, but we need to get this fixed in time of course. |
Does this PR depend on JuliaLang/julia#44960? |
No, not yet. I pulled out the GCN changes on this branch to just focus on updates for 1.9. This will now depend on JuliaLang/julia#45251, which is the necessary fix to |
c8f7657
to
5926405
Compare
JuliaLang/julia#45252 is working out even better, passing all tests for me locally. |
5926405
to
21576f7
Compare
CI is very unhappy? |
21576f7
to
08dc22a
Compare
Ahh, yeah, I guess I just have to always leave the struct in. Pushed. |
Back to draft while I figure out the GCN failures... |
Any update? The asserts build throws an assertion:
|
08dc22a
to
6838cc4
Compare
Codecov Report
@@ Coverage Diff @@
## master #324 +/- ##
==========================================
+ Coverage 75.52% 76.67% +1.14%
==========================================
Files 24 23 -1
Lines 2799 2379 -420
==========================================
- Hits 2114 1824 -290
+ Misses 685 555 -130
Continue to review full report at Codecov.
|
Not sure what's up with the macOS failure? I don't have a system to reproduce on. |
cc: @pchintalapudi for the mac error? |
712f617
to
d220d68
Compare
There's a failed assertion on 1.8 (only tried macOS) too:
No useful backtrace of course, this being JITLink on 1.8/LLVM 13. I'll try with a debug build. EDIT: never mind, this one is an issue with the new Metal backend. I'll have a look at the 1.9 macOS failure tomorrow. |
I can't reproduce the failure, but that's using a significantly more recent version of Julia: DEV-649 instead of -439 on CI. Looks like the nightlies are very much out of date? |
I was fed up with nightlies being out of date / unsigned / unavailable, so we're just compiling Julia from source now. Looking good, the only thing that now still needs to be addressed is #324 (comment) |
CI is green except for Enzyme, is that related? @vchuravy |
Will have to take a closer look at that, but shouldn't hold this up. Since we are testing 1.6 there |
Co-authored-by: Valentin Churavy <[email protected]>
|
The error:
Something looks wrong with the non-RAII
|
Don't merge this yet; this PR breaks debug info: ; julia> ptx_code_llvm(identity, Tuple{Nothing}; dump_module=true, raw=true)
warning: ignoring debug info with an invalid version (0) in
; ModuleID = 'start'
source_filename = "start"
target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v16:16:16-v32:32:32-v64:64:64-v128:128:128-n16:32:64"
target triple = "nvptx64-nvidia-cuda"
; @ operators.jl:513 within `identity`
define void @julia_identity_1531() local_unnamed_addr #0 !dbg !3 {
top:
ret void, !dbg !5
}
attributes #0 = { "probe-stack"="inline-asm" }
!llvm.dbg.cu = !{!0}
!0 = distinct !DICompileUnit(language: DW_LANG_Julia, file: !1, producer: "julia", isOptimized: true, runtimeVersion: 0, emissionKind: NoDebug, enums: !2, nameTableKind: None)
!1 = !DIFile(filename: "operators.jl", directory: ".")
!2 = !{}
!3 = distinct !DISubprogram(name: "identity", linkageName: "julia_identity_1531", scope: null, file: !1, line: 513, type: !4, scopeLine: 513, spFlags: DISPFlagDefinition | DISPFlagOptimized, unit: !0, retainedNodes: !2)
!4 = !DISubroutineType(types: !2)
!5 = !DILocation(line: 513, scope: !3) vs 1.8: ; julia> ptx_code_llvm(identity, Tuple{Nothing}; dump_module=true, raw=true)
; ModuleID = 'text'
source_filename = "text"
target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v16:16:16-v32:32:32-v64:64:64-v128:128:128-n16:32:64"
target triple = "nvptx64-nvidia-cuda"
; @ operators.jl:526 within `identity`
define void @julia_identity_754() local_unnamed_addr #0 !dbg !5 {
top:
ret void, !dbg !7
}
attributes #0 = { "probe-stack"="inline-asm" }
!llvm.module.flags = !{!0, !1}
!llvm.dbg.cu = !{!2}
!0 = !{i32 2, !"Dwarf Version", i32 4}
!1 = !{i32 2, !"Debug Info Version", i32 3}
!2 = distinct !DICompileUnit(language: DW_LANG_Julia, file: !3, producer: "julia", isOptimized: true, runtimeVersion: 0, emissionKind: NoDebug, enums: !4, nameTableKind: None)
!3 = !DIFile(filename: "operators.jl", directory: ".")
!4 = !{}
!5 = distinct !DISubprogram(name: "identity", linkageName: "julia_identity_754", scope: null, file: !3, line: 526, type: !6, scopeLine: 526, spFlags: DISPFlagDefinition | DISPFlagOptimized, unit: !2, retainedNodes: !4)
!6 = !DISubroutineType(types: !4)
!7 = !DILocation(line: 526, scope: !5)
|
Shouldn't be emitted now that 1.9 doesn't set-up the module.
From changes originally by @collinwarner