Repository navigation
LLVM issues on windows #159
Description
Activity
I experience the same issue on Windows, both when calling
Multibody.renderorPlots.plotWe have a fix in progress in JuliaSimCompiler, I'll report back here once a new release is out. If you're really keen on getting it to work, you can try applying this patch. You might get some warnings while defining those since you're effectively redefining a bunch of methods in JuliaSimCompiler, but that's fine. The patch changes the
targetfrom LLVM toJuliaTarget(), the theory is that it's the LLVM compiler that is causing the issues.import JuliaSimCompiler as JSC function JSC.SymbolicIndexingInterface.observed(sys::JSC.ScheduledSystem, sym) return JSC.build_explicit_observed_function(sys, sym; remap_params = true, target=JSC.JuliaTarget()) end function JSC.SymbolicIndexingInterface.parameter_observed(sys::JSC.ScheduledSystem, sym) return JSC.build_explicit_observed_function( sys, sym; param_only = true, remap_params = true, target=JSC.JuliaTarget()) end function (m::JSC.Memoized{HasIV})(vars) where {HasIV} let H = Val(HasIV) get!(m.obsdict, vars) do JSC.build_explicit_observed_function(m.ss, vars, H; remap_params = true, target=JSC.JuliaTarget()) end end end
A new version of JSCompiler has been released, v0.1.22. I hope this resolves your issues!
I only see v0.1.21 on JuliaHub registry
Could you try to do
pkg> upin that environment (not pkg> registry up) and see if that updates to the latest version?What's your output of
Pkg.pkg_server()? if it's not juliahub.com, you need to go though the steps here https://help.juliahub.com/juliasim/stable/gettingstarted/juliahubregistry/#Adding-the-JuliaHub-registryThanks, the above fixed the update issue. I already went through those steps to install the package the first time, but I think
This will also change the package server to https://juliahub.com/ for all Julia sessions that run startup.jl.
doesn't hold true for me. It's still https://pkg.julialang.org. But no problem I can deal with that.However, being on JuliaSimCompiler 0.1.22 I now experience crashes when calling
sol = solve(prob, Rodas4())in springmass example andsol = solve(prob, FBDF(autodiff=false), reltol=1e-8, abstol=1e-8)in quad example.
Not sure how to get the error message as you posted in the first post.What messages do you get? Does Julia terminate?
Yes Julia terminates
If you run this in a regular terminal (one that does not terminate upon segfault), do you get some message then?
No, even from a terminal julia closes without error message.
In debug I get:Internal error: encountered unexpected error in runtime:
BoundsError(a=svec(), i=1)
ijl_bounds_error_int at C:/workdir/src\rtutils.c:187
jl_f__svec_ref at C:/workdir/src\builtins.c:1668
getindex at .\essentials.jl:769 [inlined]
_new_array_nothrow at .\compiler\tfuncs.jl:2955
new_array_nothrow at .\compiler\tfuncs.jl:2950
new_array_effects at .\compiler\tfuncs.jl:2936 [inlined]
foreigncall_effects at .\compiler\tfuncs.jl:2881 [inlined]
abstract_eval_foreigncall at .\compiler\abstractinterpretation.jl:2582
abstract_eval_statement_expr at .\compiler\abstractinterpretation.jl:2495
abstract_eval_statement at .\compiler\abstractinterpretation.jl:2624
abstract_eval_basic_statement at .\compiler\abstractinterpretation.jl:2913
typeinf_local at .\compiler\abstractinterpretation.jl:3098
typeinf_nocycle at .\compiler\abstractinterpretation.jl:3186
_typeinf at .\compiler\typeinfer.jl:247
typeinf at .\compiler\typeinfer.jl:216
typeinf_ext at .\compiler\typeinfer.jl:1051
typeinf_ext_toplevel at .\compiler\typeinfer.jl:1082
typeinf_ext_toplevel at .\compiler\typeinfer.jl:1078
jfptr_typeinf_ext_toplevel_38981.1 at C:\Users\guill.julia\juliaup\julia-1.10.4+0.x64.w64.mingw32\lib\julia\sys.dll (unknown line)
_jl_invoke at C:/workdir/src\gf.c:2895 [inlined]
ijl_apply_generic at C:/workdir/src\gf.c:3077 [inlined]
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
jl_type_infer at C:/workdir/src\gf.c:394
jl_generate_fptr_impl at C:/workdir/src\jitlayers.cpp:504
jl_compile_method_internal at C:/workdir/src\gf.c:2481
jl_compile_method_internal at C:/workdir/src\gf.c:2372 [inlined]
_jl_invoke at C:/workdir/src\gf.c:2887 [inlined]
ijl_apply_generic at C:/workdir/src\gf.c:3077
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
jl_f__call_in_world at C:/workdir/src\builtins.c:831
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_apply at C:/workdir/src\builtins.c:768
#invoke_in_world#3 at .\essentials.jl:926
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_apply at C:/workdir/src\builtins.c:768
invoke_in_world at .\essentials.jl:923
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_apply at C:/workdir/src\builtins.c:768
bypass_builtins at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:213
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:253
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:559
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:559
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:559
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:559
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:559
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:559
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:559
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:477
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:559
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:477
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:477
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:559
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:477
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:477
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:559
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
#evaluate_call_recurse!#65 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:290
evaluate_call_recurse! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:251 [inlined]
eval_rhs at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:391
unknown function (ip: 000001ad6188f64d)
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:554
step_expr! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\interpret.jl:614
finish! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:14
finish_and_return! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:30
unknown function (ip: 000001ad618913b6)
finish_stack! at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:60
unknown function (ip: 000001ad61898ad6)
#debug_command#85 at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:521
debug_command at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\JuliaInterpreter\src\commands.jl:453
unknown function (ip: 000001ad6189612a)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
jl_f__call_latest at C:/workdir/src\builtins.c:812
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_apply at C:/workdir/src\builtins.c:768
#invokelatest#2 at .\essentials.jl:892
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_apply at C:/workdir/src\builtins.c:768
invokelatest at .\essentials.jl:889
our_debug_command at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\DebugAdapter\src\DebugEngines.jl:244
run at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\DebugAdapter\src\DebugEngines.jl:331
run at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\DebugAdapter\src\packagedef.jl:160
startdebugger at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\packages\VSCodeDebugger\src\VSCodeDebugger.jl:45
unknown function (ip: 000001ad61837fc4)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_call at C:/workdir/src\interpreter.c:126
eval_value at C:/workdir/src\interpreter.c:223
eval_stmt_value at C:/workdir/src\interpreter.c:174 [inlined]
eval_body at C:/workdir/src\interpreter.c:635
jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:775
top-level scope at c:\Users\guill.vscode\extensions\julialang.language-julia-1.124.2\scripts\debugger\run_debugger.jl:12
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:934
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877
ijl_toplevel_eval at C:/workdir/src\toplevel.c:943 [inlined]
ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:985
eval at .\boot.jl:385 [inlined]
include_string at .\loading.jl:2076
_include at .\loading.jl:2136
include at .\Base.jl:495
jfptr_include_49732.1 at C:\Users\guill.julia\juliaup\julia-1.10.4+0.x64.w64.mingw32\lib\julia\sys.dll (unknown line)
exec_options at .\client.jl:318
_start at .\client.jl:552
jfptr__start_86591.1 at C:\Users\guill.julia\juliaup\julia-1.10.4+0.x64.w64.mingw32\lib\julia\sys.dll (unknown line)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
true_main at C:/workdir/src\jlapi.c:582
jl_repl_entrypoint at C:/workdir/src\jlapi.c:731
mainCRTStartup at C:/workdir/cli\loader_exe.c:58
BaseThreadInitThunk at C:\WINDOWS\System32\KERNEL32.DLL (unknown line)
RtlUserThreadStart at C:\WINDOWS\SYSTEM32\ntdll.dll (unknown line)even though julia terminates. the terminal might stay alive with the segfault error message on display? The terminal in vscode dies completely, so vscode is usually not good for reading such messages
14 remaining items
Could you apply the following patch before running the script? Please let me know if it fixes your segfault issue.
using LinearAlgebra using JuliaSimCompiler: Buffer, solve2x2!, solve3x3!, _lufact!, _jscluldiv!, _free import JuliaSimCompiler: linsolve! @inline function linsolve!(A::Buffer{NN, T}, b::Buffer{N, T}, bound = 10eps(T)) where {N, NN, T} if N == 2 info = @inline solve2x2!(A, b) elseif N == 3 info = @inline solve3x3!(A, b) else ipiv = Buffer{N, Int}() info::Int = 0 GC.@preserve ipiv A b begin pA = pointer(A) pb = pointer(b) pi = pointer(ipiv) info′ = _lufact!(pA, pi, N) _jscluldiv!(pA, pi, N, pb, info′) info = info′ if iszero(info′) && bound > 0 for (j, i) in enumerate(diagind(N, N)) Ai = @inbounds A[i] if abs(Ai) < bound info = j end end end end _free(ipiv) end return info end
Running with JuliaSimCompiler v0.1.21, on the terminal I have the error message below when calling
Plots.plot(sol, idxs = [spring1.s, spring2.s])on the springmass example.Please submit a bug report with steps to reproduce this fault, and any error messages that follow (in their entirety). Thanks. Exception: EXCEPTION_ACCESS_VIOLATION at 0x20bf5739585 -- getindex at .\essentials.jl:13 [inlined] _broadcast_getindex at .\broadcast.jl:675 [inlined] _getindex at .\broadcast.jl:706 [inlined] _getindex at .\broadcast.jl:705 [inlined] _getindex at .\broadcast.jl:705 [inlined] _broadcast_getindex at .\broadcast.jl:681 [inlined] getindex at .\broadcast.jl:636 [inlined] macro expansion at .\broadcast.jl:1004 [inlined] macro expansion at .\simdloop.jl:77 [inlined] copyto! at .\broadcast.jl:1003 [inlined] copyto! at .\broadcast.jl:956 [inlined] copy at .\broadcast.jl:928 [inlined] materialize at .\broadcast.jl:903 [inlined] TimeDependentObservedFunction at C:\Users\guill\.julia\packages\SymbolicIndexingInterface\cwAFH\src\state_indexing.jl:84 in expression starting at REPL[4]:1 getindex at .\essentials.jl:13 [inlined] _broadcast_getindex at .\broadcast.jl:675 [inlined] _getindex at .\broadcast.jl:706 [inlined] _getindex at .\broadcast.jl:705 [inlined] _getindex at .\broadcast.jl:705 [inlined] _broadcast_getindex at .\broadcast.jl:681 [inlined] getindex at .\broadcast.jl:636 [inlined] macro expansion at .\broadcast.jl:1004 [inlined] macro expansion at .\simdloop.jl:77 [inlined] copyto! at .\broadcast.jl:1003 [inlined] copyto! at .\broadcast.jl:956 [inlined] copy at .\broadcast.jl:928 [inlined] materialize at .\broadcast.jl:903 [inlined] TimeDependentObservedFunction at C:\Users\guill\.julia\packages\SymbolicIndexingInterface\cwAFH\src\state_indexing.jl:84 TimeDependentObservedFunction at C:\Users\guill\.julia\packages\SymbolicIndexingInterface\cwAFH\src\state_indexing.jl:80 [inlined] AbstractStateGetIndexer at C:\Users\guill\.julia\packages\SymbolicIndexingInterface\cwAFH\src\value_provider_interface.jl:166 unknown function (ip: 0000020bf5739842) AbstractODESolution at C:\Users\guill\.julia\packages\SciMLBase\PTTHz\src\solutions\ode_solutions.jl:343 #_#479 at C:\Users\guill\.julia\packages\SciMLBase\PTTHz\src\solutions\ode_solutions.jl:220 [inlined] AbstractODESolution at C:\Users\guill\.julia\packages\SciMLBase\PTTHz\src\solutions\ode_solutions.jl:215 [inlined] AbstractODESolution at C:\Users\guill\.julia\packages\SciMLBase\PTTHz\src\solutions\ode_solutions.jl:215 unknown function (ip: 0000020bf56eaee3) solplot_vecs_and_labels at C:\Users\guill\.julia\packages\SciMLBase\PTTHz\src\solutions\solution_interface.jl:506 diffeq_to_arrays at C:\Users\guill\.julia\packages\SciMLBase\PTTHz\src\solutions\solution_interface.jl:400 unknown function (ip: 0000020bf56d7fb2) macro expansion at C:\Users\guill\.julia\packages\SciMLBase\PTTHz\src\solutions\solution_interface.jl:210 [inlined] macro expansion at C:\Users\guill\.julia\packages\RecipesBase\BRe07\src\RecipesBase.jl:340 [inlined] macro expansion at C:\Users\guill\.julia\packages\SciMLBase\PTTHz\src\solutions\solution_interface.jl:204 [inlined] apply_recipe at C:\Users\guill\.julia\packages\RecipesBase\BRe07\src\RecipesBase.jl:300 unknown function (ip: 0000020bf56c3b1f) jl_apply at C:/workdir/src\julia.h:1982 [inlined] do_apply at C:/workdir/src\builtins.c:768 _process_userrecipes! at C:\Users\guill\.julia\packages\RecipesPipeline\BGM3l\src\user_recipe.jl:38 recipe_pipeline! at C:\Users\guill\.julia\packages\RecipesPipeline\BGM3l\src\RecipesPipeline.jl:72 _plot! at C:\Users\guill\.julia\packages\Plots\kLeqV\src\plot.jl:223 #plot#188 at C:\Users\guill\.julia\packages\Plots\kLeqV\src\plot.jl:102 plot at C:\Users\guill\.julia\packages\Plots\kLeqV\src\plot.jl:93 jl_apply at C:/workdir/src\julia.h:1982 [inlined] do_call at C:/workdir/src\interpreter.c:126 eval_value at C:/workdir/src\interpreter.c:223 eval_stmt_value at C:/workdir/src\interpreter.c:174 [inlined] eval_body at C:/workdir/src\interpreter.c:635 jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:775 jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:934 jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877 jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877 jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877 ijl_toplevel_eval at C:/workdir/src\toplevel.c:943 [inlined] ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:985 eval at .\boot.jl:385 [inlined] eval_user_input at C:\workdir\usr\share\julia\stdlib\v1.10\REPL\src\REPL.jl:150 repl_backend_loop at C:\workdir\usr\share\julia\stdlib\v1.10\REPL\src\REPL.jl:246 #start_repl_backend#46 at C:\workdir\usr\share\julia\stdlib\v1.10\REPL\src\REPL.jl:231 start_repl_backend at C:\workdir\usr\share\julia\stdlib\v1.10\REPL\src\REPL.jl:228 #run_repl#59 at C:\workdir\usr\share\julia\stdlib\v1.10\REPL\src\REPL.jl:389 run_repl at C:\workdir\usr\share\julia\stdlib\v1.10\REPL\src\REPL.jl:375 jfptr_run_repl_95791.1 at C:\Users\guill\.julia\juliaup\julia-1.10.4+0.x64.w64.mingw32\lib\julia\sys.dll (unknown line) #1013 at .\client.jl:432 jfptr_YY.1013_86566.1 at C:\Users\guill\.julia\juliaup\julia-1.10.4+0.x64.w64.mingw32\lib\julia\sys.dll (unknown line) jl_apply at C:/workdir/src\julia.h:1982 [inlined] jl_f__call_latest at C:/workdir/src\builtins.c:812 #invokelatest#2 at .\essentials.jl:892 [inlined] invokelatest at .\essentials.jl:889 [inlined] run_main_repl at .\client.jl:416 exec_options at .\client.jl:333 _start at .\client.jl:552 jfptr__start_86591.1 at C:\Users\guill\.julia\juliaup\julia-1.10.4+0.x64.w64.mingw32\lib\julia\sys.dll (unknown line) jl_apply at C:/workdir/src\julia.h:1982 [inlined] true_main at C:/workdir/src\jlapi.c:582 jl_repl_entrypoint at C:/workdir/src\jlapi.c:731 mainCRTStartup at C:/workdir/cli\loader_exe.c:58 BaseThreadInitThunk at C:\WINDOWS\System32\KERNEL32.DLL (unknown line) RtlUserThreadStart at C:\WINDOWS\SYSTEM32\ntdll.dll (unknown line) Allocations: 114151663 (Pool: 114016604; Big: 135059); GC: 97The patch yingbo posted is related to
solve, the problem with plotting and rendering may or may not be related. Would you mind trying it on the latest JSCompiler?Debugging this appears very hard, it no longer fails on windows on our CI machine 🙃
One more release of JSCompiler has been made, v0.1.24, where a lot of performance optimization in
linsolve!have been turned off. Once again, I really hope this fixes the issue 🤞 Thank you for sticking with usI have the same crash if I run @YingboMa's script before the springmass example. Note that I only enter N==2 and N==3 cases (not the else).
One more release of JSCompiler has been made, v0.1.24, where a lot of performance optimization in
linsolve!have been turned off. Once again, I really hope this fixes the issue 🤞 Thank you for sticking with usSame crash as well (with and without running the script).
Should I contact you on Slack when I have availability if it helps ?
We have now released v0.1.26 of JSCompiler and this version passes all the CI tests on windows. I hope this has finally resolved the issue!
I tested with JSCompiler v0.1.26 and all the examples solve and render correctly... except the quadrotor example.
The quadrotor solves fine, but calling
rendercompletely freezes my laptop after 20 seconds and I have to reboot.
If I run withaddLoad = falsethen it renders correctly. (1)
I tried connecting the Load to the Body without the Rope: freeze. (2)
I tried to replace the Rope by a FixedTranslation: freeze. (3)
If I first render withaddLoad = falseand then call (3) in the same session then I managed to render (3), but it seems to be random (freezes the laptop 1/3 of the time...).
If I first render withaddLoad = falseand then call (2) : freeze.The FullCar and RobotArm examples - which to me seem more complex to render than the QuadRotor- systematically render fine.
Thanks for testing! The quadrotor with load cable is significantly more complex than the robot example, each joint in the robot has a single degree of freedom, while each joint in the cable has 3 and the body of the aircraft has 6. I know that the quadrotor example is rather slow, it's slow to
structural_simplify, slow to plot, to render and to linearize, but it should ideally not freeze your computer :/Could you potentially be running out of RAM when the computer freezes?
This is still an issue for me (Windows freezing on some models).
The RAM is not particularly high.I was able to reproduce the problem in pure GLMakie, outside of Multibody.jl.
Fixed by forcing Windows to use my Nvidia GPU instead of my integrated graphic card.Reacted by Fredrik Bagge Carlsondo you have an MWE?
This is the minimal example that caused a system freeze:
using GLMakie # set up the scene size = (600, 450) fig = Figure(; size) scene = LScene(fig[1, 1])#.scene cam3d!(scene, center=true) fig.current_axis.x.show_axis[] = false # Add a Cylinder (stripped down from render! Frame) O = Point3f(0.0, 0.0, 0.0) x = Point3f(1.0, 0.0, 0.0) radius = 0.01f0 thing = Makie.GeometryBasics.Cylinder(O, x, radius) mesh!(scene, thing, color=:red, shading=NoShading, fxaa=false, inspectable=false) # Add an Arrow (stripped down from render! WorldForce) origin = GLMakie.GeometryBasics.Point{3, Float32}[[0.156001, 1.0f-6, 1.650001]] d = GLMakie.GeometryBasics.Point{3, Float32}[[-1.0, -1.0, -0.0]] a = Makie.arrows!(origin, d, shading=NoShading, fxaa=false, inspectable=false) fig
It crashes after a few camera movement with the mouse - system is completely unresponsive.
If I only have Cylinders (or any other meshes) then it seems fine.
If I only have Arrows then it seems fine.
My problem only appeared when mixing both.As it looks like a hardware/driver issue, I updated my GPU driver and then realised that the work was happening on the integrated GPU.
Could be worth debugging, sometimes a bug only materializes on a certain GPU, but not on others, but mainly because the other vendors are more forgiving.
If it's easy to reproduce and you haven't used the newest version (released yesterday, Makie@0.22.2), could you try it out?
We fixed a few rare segfaults/bugs, although they were all a bit different.
Another thing thing to try would be to set GLMakie.ModernGL.enable_opengl_debugging[] = trueandGLMakie.GLAbstraction.GLMAKIE_DEBUG[] = true`.JuliaSimCompiler, and therefore any LLVM hacks, are being removed from the Multibody dependency stack, so I'll close this issue.
Reacted by pitx-perf



@SimonDanisch is experiencing lots of issues running on windows
The robot example is failing during rendering with
and with
cache=falsehe instead getsIt looks like the issue stems from calling a function generated by JSCompiler with the LLVM backend.