PackageCompiler error creating sysimage

Hello,

I’m having issues using PackageCompiler on a Linux on aarch64(nVidia Jetson TX2) machine. Running through the basic example from the documentation causes this error.

julia> create_sysimage(["Example"]; sysimage_path="ExampleSysimage.so")
⣠ [01m:01s] PackageCompiler: compiling incremental system imagefatal: error thrown and no exception handler available.
StackOverflowError()
⣄ [01m:01s] PackageCompiler: compiling incremental system imagejl_serialize_value_ at /buildworker/worker/package_linuxaarch64/build/src/staticdata.c:421
jl_serialize_value_ at /buildworker/worker/package_linuxaarch64/build/src/staticdata.c:458
⢰ [01m:02s] PackageCompiler: compiling incremental system image
ERROR: failed process: Process(`/usr/lib/julia/bin/julia --color=yes --startup-file=no --cpu-target=native -O3 --sysimage=/usr/lib/julia/lib/julia/sys.so --project=/home/ubuntu/NewSysImageEnv --output-o=/tmp/jl_kOZ89J.o /tmp/jl_215v2A`, ProcessExited(1)) [1]

Stacktrace:
 [1] pipeline_error
   @ ./process.jl:531 [inlined]
 [2] run(::Cmd; wait::Bool)
   @ Base ./process.jl:446
 [3] run
   @ ./process.jl:444 [inlined]
 [4] #14
   @ ~/.julia/packages/PackageCompiler/tdgyo/ext/TerminalSpinners.jl:157 [inlined]
 [5] spin(f::PackageCompiler.var"#14#15"{Cmd}, s::PackageCompiler.TerminalSpinners.Spinner{Base.TTY})
   @ PackageCompiler.TerminalSpinners ~/.julia/packages/PackageCompiler/tdgyo/ext/TerminalSpinners.jl:164
 [6] macro expansion
   @ ~/.julia/packages/PackageCompiler/tdgyo/ext/TerminalSpinners.jl:157 [inlined]
 [7] create_sysimg_object_file(object_file::String, packages::Vector{String}, packages_sysimg::Set{Base.PkgId}; project::String, base_sysimage::String, precompile_execution_file::Vector{String}, precompile_statements_file::Vector{String}, cpu_target::String, script::Nothing, sysimage_build_args::Cmd, extra_precompiles::String)
   @ PackageCompiler ~/.julia/packages/PackageCompiler/tdgyo/src/PackageCompiler.jl:356
 [8] create_sysimage(packages::Vector{String}; sysimage_path::String, project::String, precompile_execution_file::Vector{String}, precompile_statements_file::Vector{String}, 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, version::Nothing, soname::Nothing, compat_level::String, extra_precompiles::String)
   @ PackageCompiler ~/.julia/packages/PackageCompiler/tdgyo/src/PackageCompiler.jl:507
 [9] top-level scope
   @ REPL[6]:1

I’m on Julia 1.7.1

julia> versioninfo()
Julia Version 1.7.1
Commit ac5cc99908 (2021-12-22 19:35 UTC)
Platform Info:
  OS: Linux (aarch64-unknown-linux-gnu)
  CPU: unknown
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-12.0.1 (ORCJIT, cortex-a57)

Any ideas what is happening here?

I’m not sure if it’s related to this ARM CPU JIT issue https://github.com/JuliaLang/julia/issues/41852 but seems similar to the create_app issue although it’s coming from different location…