Skip to content
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

Segfault during dominator tree disposal #366

Closed
maleadt opened this issue Sep 29, 2023 · 2 comments
Closed

Segfault during dominator tree disposal #366

maleadt opened this issue Sep 29, 2023 · 2 comments

Comments

@maleadt
Copy link
Owner

maleadt commented Sep 29, 2023

In #363, I decided to ignore the (unrelated) CI failure. Of course, fixing that failure in #365 revealed an actual issue with the new dominator functionality, on Windows: https://github.com/maleadt/LLVM.jl/actions/runs/6350708044/job/17250828312?pr=365

Exception: EXCEPTION_ACCESS_VIOLATION at 0x7ffd5aee7955 -- llvm::DenseMapBase<llvm::DenseMap<llvm::BasicBlock*, std::unique_ptr<llvm::DomTreeNodeBase<llvm::BasicBlock>, std::default_delete<llvm::DomTreeNodeBase<llvm::BasicBlock> > >, llvm::DenseMapInfo<llvm::BasicBlock*, void>, llvm::detail::DenseMapPair<llvm::BasicBlock*, std::unique_ptr<llvm::DomTreeNodeBase<llvm::BasicBlock>, std::default_delete<llvm::DomTreeNodeBase<llvm::BasicBlock> > > > >, llvm::BasicBlock*, std::unique_ptr<llvm::DomTreeNodeBase<llvm::BasicBlock>, std::default_delete<llvm::DomTreeNodeBase<llvm::BasicBlock> > >, llvm::DenseMapInfo<llvm::BasicBlock*, void>, llvm::detail::DenseMapPair<llvm::BasicBlock*, std::unique_ptr<llvm::DomTreeNodeBase<llvm::BasicBlock>, std::default_delete<llvm::DomTreeNodeBase<llvm::BasicBlock> > > > >::destroyAll() at C:\Users\runneradmin\.julia\scratchspaces\929cbde3-209d-540e-8aea-75f648917ca0\build\lib\libLLVMExtra-14.dll (unknown line)
in expression starting at D:\a\LLVM.jl\LLVM.jl\test\analysis_tests.jl:29
llvm::DenseMapBase<llvm::DenseMap<llvm::BasicBlock*, std::unique_ptr<llvm::DomTreeNodeBase<llvm::BasicBlock>, std::default_delete<llvm::DomTreeNodeBase<llvm::BasicBlock> > >, llvm::DenseMapInfo<llvm::BasicBlock*, void>, llvm::detail::DenseMapPair<llvm::BasicBlock*, std::unique_ptr<llvm::DomTreeNodeBase<llvm::BasicBlock>, std::default_delete<llvm::DomTreeNodeBase<llvm::BasicBlock> > > > >, llvm::BasicBlock*, std::unique_ptr<llvm::DomTreeNodeBase<llvm::BasicBlock>, std::default_delete<llvm::DomTreeNodeBase<llvm::BasicBlock> > >, llvm::DenseMapInfo<llvm::BasicBlock*, void>, llvm::detail::DenseMapPair<llvm::BasicBlock*, std::unique_ptr<llvm::DomTreeNodeBase<llvm::BasicBlock>, std::default_delete<llvm::DomTreeNodeBase<llvm::BasicBlock> > > > >::destroyAll() at C:\Users\runneradmin\.julia\scratchspaces\929cbde3-209d-540e-8aea-75f648917ca0\build\lib\libLLVMExtra-14.dll (unknown line)
llvm::DenseMap<llvm::BasicBlock*, std::unique_ptr<llvm::DomTreeNodeBase<llvm::BasicBlock>, std::default_delete<llvm::DomTreeNodeBase<llvm::BasicBlock> > >, llvm::DenseMapInfo<llvm::BasicBlock*, void>, llvm::detail::DenseMapPair<llvm::BasicBlock*, std::unique_ptr<llvm::DomTreeNodeBase<llvm::BasicBlock>, std::default_delete<llvm::DomTreeNodeBase<llvm::BasicBlock> > > > >::~DenseMap() at C:\Users\runneradmin\.julia\scratchspaces\929cbde3-209d-540e-8aea-75f648917ca0\build\lib\libLLVMExtra-14.dll (unknown line)
llvm::DominatorTreeBase<llvm::BasicBlock, false>::~DominatorTreeBase() at C:\Users\runneradmin\.julia\scratchspaces\929cbde3-209d-540e-8aea-75f648917ca0\build\lib\libLLVMExtra-14.dll (unknown line)
llvm::DominatorTree::~DominatorTree() at C:\Users\runneradmin\.julia\scratchspaces\929cbde3-209d-540e-8aea-75f648917ca0\build\lib\libLLVMExtra-14.dll (unknown line)
.text at C:\Users\runneradmin\.julia\scratchspaces\929cbde3-209d-540e-8aea-75f648917ca0\build\lib\libLLVMExtra-14.dll (unknown line)
LLVMDisposeDominatorTree at D:\a\LLVM.jl\LLVM.jl\lib\libLLVM_extra.jl:432 [inlined]
dispose at D:\a\LLVM.jl\LLVM.jl\src\analysis.jl:29
unknown function (ip: 000001afee9fb066)
jl_apply at C:/workdir/src\julia.h:1880 [inlined]
do_call at C:/workdir/src\interpreter.c:126
eval_value at C:/workdir/src\interpreter.c:226
eval_stmt_value at C:/workdir/src\interpreter.c:177 [inlined]
eval_body at C:/workdir/src\interpreter.c:624
eval_body at C:/workdir/src\interpreter.c:533
jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:762
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:912
jl_eval_module_expr at C:/workdir/src\toplevel.c:203 [inlined]
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:715
ijl_toplevel_eval at C:/workdir/src\toplevel.c:921 [inlined]
ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:971
eval at .\boot.jl:370 [inlined]
#85 at C:\Users\runneradmin\.julia\packages\ReTestItems\OTEAP\src\ReTestItems.jl:923 [inlined]
with_source_path at C:\Users\runneradmin\.julia\packages\ReTestItems\OTEAP\src\ReTestItems.jl:791
#84 at C:\Users\runneradmin\.julia\packages\ReTestItems\OTEAP\src\ReTestItems.jl:923 [inlined]
#redirect_stdio#718 at .\stream.jl:1413
redirect_stdio at .\stream.jl:1376 [inlined]
_redirect_logs at C:\Users\runneradmin\.julia\packages\ReTestItems\OTEAP\src\log_capture.jl:122
#27 at C:\Users\runneradmin\.julia\packages\ReTestItems\OTEAP\src\log_capture.jl:107 [inlined]
#open#409 at .\io.jl:395
open at .\io.jl:392 [inlined]
_redirect_logs at C:\Users\runneradmin\.julia\packages\ReTestItems\OTEAP\src\log_capture.jl:107 [inlined]
macro expansion at C:\Users\runneradmin\.julia\packages\ReTestItems\OTEAP\src\macros.jl:82 [inlined]
#runtestitem#83 at C:\Users\runneradmin\.julia\packages\ReTestItems\OTEAP\src\ReTestItems.jl:922
runtestitem at C:\Users\runneradmin\.julia\packages\ReTestItems\OTEAP\src\ReTestItems.jl:855
unknown function (ip: 000001afee9cb64a)
jl_apply at C:/workdir/src\julia.h:1880 [inlined]
do_call at C:/workdir/src\interpreter.c:126
eval_value at C:/workdir/src\interpreter.c:226
eval_stmt_value at C:/workdir/src\interpreter.c:177 [inlined]
eval_body at C:/workdir/src\interpreter.c:624
jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:762
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:912
ijl_toplevel_eval at C:/workdir/src\toplevel.c:921 [inlined]
ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:971
eval at .\boot.jl:370 [inlined]
execute at C:\Users\runneradmin\.julia\packages\ReTestItems\OTEAP\src\workers.jl:303 [inlined]
macro expansion at C:\Users\runneradmin\.julia\packages\ReTestItems\OTEAP\src\workers.jl:317 [inlined]
#22 at .\threadingconstructs.jl:410
unknown function (ip: 000001afee9b1362)
jl_apply at C:/workdir/src\julia.h:1880 [inlined]
start_task at C:/workdir/src\task.c:1092
Allocations: 4709903 (Pool: 4707212; Big: 2691); GC: 8
@maleadt maleadt mentioned this issue Sep 29, 2023
@maleadt
Copy link
Owner Author

maleadt commented Sep 29, 2023

An error during dispose normally indicates some badly ordered destructors being called, but here dispose is neatly called right after the dominator tests, i.e., the module can't have been freed in between.

@maleadt
Copy link
Owner Author

maleadt commented Oct 3, 2023

Somehow disappeared when we bumped the JLL, so this may be related to a toolchain mismatch or so.

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

No branches or pull requests

1 participant