Skip to content

Instantly share code, notes, and snippets.

@abhro
Created November 24, 2024 15:46
Show Gist options
  • Save abhro/3e17c9ee109f7519aaab43cc7f1efd13 to your computer and use it in GitHub Desktop.
Save abhro/3e17c9ee109f7519aaab43cc7f1efd13 to your computer and use it in GitHub Desktop.
MWE transcript of PackageCompiler.jl error involving CUDA.jl and BFloat16s
PS> julia
_
_ _ _(_)_ | Documentation: https://docs.julialang.org
(_) | (_) (_) |
_ _ _| |_ __ _ | Type "?" for help, "]?" for Pkg help.
| | | | | | |/ _` | |
| | |_| | | | (_| | | Version 1.11.1 (2024-10-16)
_/ |\__'_|_|_|\__'_| | Official https://julialang.org/ release
|__/ |
julia> versioninfo()
Julia Version 1.11.1
Commit 8f5b7ca12a (2024-10-16 10:53 UTC)
Build Info:
Official https://julialang.org/ release
Platform Info:
OS: Windows (x86_64-w64-mingw32)
CPU: 32 × 13th Gen Intel(R) Core(TM) i9-13900K
WORD_SIZE: 64
LLVM: libLLVM-16.0.6 (ORCJIT, alderlake)
Threads: 1 default, 0 interactive, 1 GC (on 32 virtual cores)
(@v1.11) pkg> activate --temp
Activating new project at `$HOME\AppData\Local\Temp\jl_W5DHw4`
(jl_W5DHw4) pkg> add CUDA PackageCompiler
Resolving package versions...
Updating `$HOME\AppData\Local\Temp\jl_W5DHw4\Project.toml`
[052768ef] + CUDA v5.5.2
[9b87118b] + PackageCompiler v2.1.24
Updating `$HOME\AppData\Local\Temp\jl_W5DHw4\Manifest.toml`
[621f4979] + AbstractFFTs v1.5.0
[79e6a3ab] + Adapt v4.1.1
[a9b6321e] + Atomix v0.1.0
[ab4f0b2a] + BFloat16s v0.5.0
[fa961155] + CEnum v0.5.0
[052768ef] + CUDA v5.5.2
[1af6417a] + CUDA_Runtime_Discovery v0.3.5
[3da002f7] + ColorTypes v0.12.0
[5ae59095] + Colors v0.13.0
[34da2185] + Compat v4.16.0
[a8cc5b0e] + Crayons v4.1.1
[9a962f9c] + DataAPI v1.16.0
[a93c6f00] + DataFrames v1.7.0
[864edb3b] + DataStructures v0.18.20
[e2d170a0] + DataValueInterfaces v1.0.0
[e2ba6199] + ExprTools v0.1.10
[53c48c17] + FixedPointNumbers v0.8.5
⌅ [0c68f7d7] + GPUArrays v10.3.1
⌅ [46192b85] + GPUArraysCore v0.1.6
⌅ [61eb1bfa] + GPUCompiler v0.27.8
[c27321d9] + Glob v1.3.1
[842dd82b] + InlineStrings v1.4.2
[41ab1584] + InvertedIndices v1.3.0
[82899510] + IteratorInterfaceExtensions v1.0.0
[692b3bcd] + JLLWrappers v1.6.1
[63c18a36] + KernelAbstractions v0.9.29
[929cbde3] + LLVM v9.1.3
[8b046642] + LLVMLoopInfo v1.0.0
[b964fa9f] + LaTeXStrings v1.4.0
[1914dd2f] + MacroTools v0.5.13
[e1d29d7a] + Missings v1.2.0
[5da4648a] + NVTX v0.3.5
[bac558e1] + OrderedCollections v1.6.3
[9b87118b] + PackageCompiler v2.1.24
[2dfb63ee] + PooledArrays v1.4.3
[aea7be01] + PrecompileTools v1.2.1
[21216c6a] + Preferences v1.4.3
[08abe8d2] + PrettyTables v2.4.0
[74087812] + Random123 v1.7.0
[e6cf234a] + RandomNumbers v1.6.0
[189a3867] + Reexport v1.2.2
[05181044] + RelocatableFolders v1.0.1
[ae029012] + Requires v1.3.0
[6c6a2e73] + Scratch v1.2.1
[91c51154] + SentinelArrays v1.4.7
[a2af1166] + SortingAlgorithms v1.2.1
[90137ffa] + StaticArrays v1.9.8
[1e83bf80] + StaticArraysCore v1.4.3
[10745b16] + Statistics v1.11.1
[892a3eda] + StringManipulation v0.4.0
[3783bdb8] + TableTraits v1.0.1
[bd369af6] + Tables v1.12.0
[a759f4b9] + TimerOutputs v0.5.25
[013be700] + UnsafeAtomics v0.2.1
[d80eeb9a] + UnsafeAtomicsLLVM v0.2.1
[4ee394cb] + CUDA_Driver_jll v0.10.4+0
[76a88914] + CUDA_Runtime_jll v0.15.5+0
[9c1d0b0a] + JuliaNVTXCallbacks_jll v0.2.1+0
[dad2f222] + LLVMExtra_jll v0.0.34+0
[e98f9f5b] + NVTX_jll v3.1.0+2
[1e29f10c] + demumble_jll v1.3.0+0
[0dad84c5] + ArgTools v1.1.2
[56f22d72] + Artifacts v1.11.0
[2a0f44e3] + Base64 v1.11.0
[ade2ca70] + Dates v1.11.0
[f43a241f] + Downloads v1.6.0
[7b1f6079] + FileWatching v1.11.0
[9fa8497b] + Future v1.11.0
[b77e0a4c] + InteractiveUtils v1.11.0
[4af54fe1] + LazyArtifacts v1.11.0
[b27032c2] + LibCURL v0.6.4
[76f85450] + LibGit2 v1.11.0
[8f399da3] + Libdl v1.11.0
[37e2e46d] + LinearAlgebra v1.11.0
[56ddb016] + Logging v1.11.0
[d6f4376e] + Markdown v1.11.0
[ca575930] + NetworkOptions v1.2.0
[44cfe95a] + Pkg v1.11.0
[de0858da] + Printf v1.11.0
[9a3f8284] + Random v1.11.0
[ea8e919c] + SHA v0.7.0
[9e88b42a] + Serialization v1.11.0
[2f01184e] + SparseArrays v1.11.0
[fa267f1f] + TOML v1.0.3
[a4e569a6] + Tar v1.10.0
[8dfed614] + Test v1.11.0
[cf7118a7] + UUIDs v1.11.0
[4ec0a83e] + Unicode v1.11.0
[e66e0078] + CompilerSupportLibraries_jll v1.1.1+0
[deac9b47] + LibCURL_jll v8.6.0+0
[e37daf67] + LibGit2_jll v1.7.2+0
[29816b5a] + LibSSH2_jll v1.11.0+1
[c8ffd9c3] + MbedTLS_jll v2.28.6+0
[14a3606d] + MozillaCACerts_jll v2023.12.12
[4536629a] + OpenBLAS_jll v0.3.27+1
[bea87d4a] + SuiteSparse_jll v7.7.0+0
[83775a58] + Zlib_jll v1.2.13+1
[8e850b90] + libblastrampoline_jll v5.11.0+0
[8e850ede] + nghttp2_jll v1.59.0+0
[3f19e933] + p7zip_jll v17.4.0+2
Info Packages marked with ⌅ have new versions available but compatibility constraints restrict them from upgrading. To see why use `status --outdated -m`
julia> using PackageCompiler
julia> create_sysimage(["CUDA"], sysimage_path = "CUDA.jl-sysimage.dll")
✔ [02m:31s] PackageCompiler: compiling incremental system image
Warning: .drectve `-exclude-symbols:jl_gvar_idxs_0 ' unrecognized
Warning: .drectve `-exclude-symbols:jl_fvar_idxs_0 ' unrecognized
Warning: .drectve `-exclude-symbols:jl_gvar_offsets_0 ' unrecognized
Warning: .drectve `-exclude-symbols:jl_fvar_count_0 ' unrecognized
Warning: .drectve `-exclude-symbols:jl_fvar_ptrs_0 ' unrecognized
Warning: .drectve `-exclude-symbols:jl_clone_slots_0 ' unrecognized
Warning: .drectve `-exclude-symbols:jl_clone_idxs_0 ' unrecognized
Warning: .drectve `-exclude-symbols:jl_clone_ptrs_0 ' unrecognized
Warning: .drectve `-exclude-symbols:jl_shard_tables ' unrecognized
Warning: .drectve `-exclude-symbols:jl_pgcstack_func_slot ' unrecognized
Warning: .drectve `-exclude-symbols:jl_pgcstack_key_slot ' unrecognized
Warning: .drectve `-exclude-symbols:jl_tls_offset ' unrecognized
Warning: .drectve `-exclude-symbols:jl_ptls_table ' unrecognized
Warning: .drectve `-exclude-symbols:jl_small_typeof ' unrecognized
$HOME\AppData\Local\Temp\jl_ZA7qvMLupC-o.a(text#0.o): In function `BFloat16':
$HOME\.julia\packages\BFloat16s\u3WQc\src/bfloat16.jl:158: undefined reference to `__truncdfbf2'
$HOME\.julia\packages\BFloat16s\u3WQc\src/bfloat16.jl:158: undefined reference to `__truncdfbf2'
collect2.exe: error: ld returned 1 exit status
ERROR: failed process: Process(setenv(`'$HOME\.julia\artifacts\fdff308295487f361ef6e8dc2d27f5abe8a6eee9\mingw64\bin\g++.exe' -m64 -march=x86-64 -shared '-L$HOME\.julia\juliaup\julia-1.11.1+0.x64.w64.mingw32\bin' '-L$HOME\.julia\juliaup\julia-1.11.1+0.x64.w64.mingw32\bin' -o CUDA.jl-sysimage.dll -Wl,--whole-archive '$HOME\AppData\Local\Temp\jl_ZA7qvMLupC-o.a' -Wl,--no-whole-archive -ljulia -ljulia-internal -lopenlibm -Wl,--export-all-symbols`,["WINDIR=C:\\WINDOWS", "PATH=C:\\Program Files\\PowerShell\\7;C:\\Program Files\\Quarto\\bin;C:\\Program Files\\Python312\\Scripts;C:\\Program Files\\Python312;C:\\WINDOWS\\system32;C:\\WINDOWS;C:\\WINDOWS\\System32\\Wbem;C:\\WINDOWS\\System32\\WindowsPowerShell\\v1.0\\;C:\\WINDOWS\\System32\\OpenSSH\\;C:\\Program Files (x86)\\Sennheiser\\SoftphoneSDK\\;C:\\Program Files (x86)\\NVIDIA Corporation\\PhysX\\Common;C:\\Program Files\\Microsoft VS Code\\bin;C:\\Program Files (x86)\\Windows Kits\\10\\Windows Performance Toolkit;C:\\Program Files\\dotnet\\;C:\\Program Files\\Pandoc;C:\\Program Files\\PowerShell\\7;C:\\Program Files\\Git\\cmd;C:\\Program Files\\7-Zip;C:\\MinGW\\msys\\1.0\\bin;C:\\Program Files\\CMake\\bin;C:\\Program Files\\LLVM\\bin;$HOME\\AppData\\Local\\Microsoft\\WindowsApps;$HOME\\Documents\\WindowsPowerShell\\Scripts;$HOME\\AppData\\Local\\Programs\\MiKTeX\\miktex\\bin\\x64\\;$HOME\\AppData\\Roaming\\Python\\Python312\\Scripts;$HOME\\AppData\\Local\\GitHubDesktop\\bin;$HOME\\.julia\\artifacts\\fdff308295487f361ef6e8dc2d27f5abe8a6eee9\\mingw64\\bin", "WSLENV=WT_SESSION:WT_PROFILE_ID:", "ZES_ENABLE_SYSMAN=1", "LOCALAPPDATA=$HOME\\AppData\\Local", "HOMEPATH=$HOME", "PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 183 Stepping 1, GenuineIntel", "NUMBER_OF_PROCESSORS=32", "PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.PY;.PYW;.CPL" … "PROCESSOR_LEVEL=6", "SYSTEMDRIVE=C:", "IFORT_COMPILER24=C:\\Program Files (x86)\\Intel\\oneAPI\\compiler\\2024.2\\", "PROGRAMW6432=C:\\Program Files", "HOMEDRIVE=C:", "OPENBLAS_MAIN_FREE=1", "PROCESSOR_ARCHITECTURE=AMD64", "TEMP=$HOME\\AppData\\Local\\Temp"]), ProcessExited(1)) [1]
Stacktrace:
[1] pipeline_error
@ .\process.jl:598 [inlined]
[2] run(::Cmd; wait::Bool)
@ Base .\process.jl:513
[3] run
@ .\process.jl:510 [inlined]
[4] run_compiler(cmd::Cmd; cplusplus::Bool)
@ PackageCompiler $HOME\.julia\packages\PackageCompiler\gMDVC\src\PackageCompiler.jl:200
[5] run_compiler
@ $HOME\.julia\packages\PackageCompiler\gMDVC\src\PackageCompiler.jl:196 [inlined]
[6] create_sysimg_from_object_file(object_files::Vector{String}, sysimage_path::String; version::Nothing, compat_level::String, soname::Nothing)
@ PackageCompiler $HOME\.julia\packages\PackageCompiler\gMDVC\src\PackageCompiler.jl:725
[7] create_sysimg_from_object_file
@ $HOME\.julia\packages\PackageCompiler\gMDVC\src\PackageCompiler.jl:711 [inlined]
[8] create_sysimage(packages::Vector{…}; sysimage_path::String, project::String, precompile_execution_file::Vector{…}, precompile_statements_file::Vector{…}, incremental::Bool, filter_stdlibs::Bool, cpu_target::String, script::Nothing, sysimage_build_args::Cmd, include_transitive_dependencies::Bool, base_sysimage::Nothing, julia_init_c_file::Nothing, julia_init_h_file::Nothing, version::Nothing, soname::Nothing, compat_level::String, extra_precompiles::String, import_into_main::Bool)
@ PackageCompiler $HOME\.julia\packages\PackageCompiler\gMDVC\src\PackageCompiler.jl:691
[9] top-level scope
@ REPL[4]:1
Some type information was truncated. Use `show(err)` to see complete types.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment