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

suggest is producing StackOverflowError #339

Open
simsurace opened this issue Jan 25, 2023 · 0 comments
Open

suggest is producing StackOverflowError #339

simsurace opened this issue Jan 25, 2023 · 0 comments

Comments

@simsurace
Copy link

Reproducible with the tutorial:

julia> using SnoopCompile

julia> cd(joinpath(pkgdir(SnoopCompile), "examples"));

julia> include("OptimizeMe.jl");

julia> tinf = @snoopi_deep OptimizeMe.main();

julia> itrigs = inference_triggers(tinf);

julia> itree = trigger_tree(itrigs)

julia> itree.children[1] |> suggest
Error showing value of type SnoopCompile.SuggestNode:
ERROR: StackOverflowError:
Stacktrace:
     [1] _string_n
       @ ./strings/string.jl:78 [inlined]
     [2] StringVector
       @ ./iobuffer.jl:31 [inlined]
     [3] #IOBuffer#423
       @ ./iobuffer.jl:114 [inlined]
     [4] GenericIOBuffer
       @ ./iobuffer.jl:105 [inlined]
     [5] print_tree(printnode::typeof(AbstractTrees.printnode), print_child_key::typeof(AbstractTrees.print_child_key), io::IOContext{IOBuffer}, node::SnoopCompile.SuggestNode; maxdepth::Int64, indicate_truncation::Bool, charset::AbstractTrees.TreeCharSet, printkeys::Nothing, depth::Int64, prefix::String, kw::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
       @ AbstractTrees ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:200
     [6] print_tree
       @ ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:190 [inlined]
     [7] print_tree(io::IOContext{IOBuffer}, node::SnoopCompile.SuggestNode; kw::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
       @ AbstractTrees ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:272
     [8] print_tree(io::IOContext{IOBuffer}, node::SnoopCompile.SuggestNode)
       @ AbstractTrees ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:272
     [9] show
       @ ~/.julia/packages/SnoopCompile/Ul2N6/src/parcel_snoopi_deep.jl:1734 [inlined]
    [10] #printnode#23
       @ ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:87 [inlined]
    [11] printnode(io::IOContext{IOBuffer}, node::SnoopCompile.SuggestNode)
       @ AbstractTrees ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:87
    [12] print_tree(printnode::typeof(AbstractTrees.printnode), print_child_key::typeof(AbstractTrees.print_child_key), io::IOContext{IOBuffer}, node::SnoopCompile.SuggestNode; maxdepth::Int64, indicate_truncation::Bool, charset::AbstractTrees.TreeCharSet, printkeys::Nothing, depth::Int64, prefix::String, kw::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
       @ AbstractTrees ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:201
--- the last 7 lines are repeated 3414 more times ---
 [23911] print_tree
       @ ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:190 [inlined]
 [23912] print_tree(io::IOContext{IOBuffer}, node::SnoopCompile.SuggestNode; kw::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
       @ AbstractTrees ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:272
 [23913] print_tree(io::IOContext{IOBuffer}, node::SnoopCompile.SuggestNode)
       @ AbstractTrees ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:272
 [23914] show
       @ ~/.julia/packages/SnoopCompile/Ul2N6/src/parcel_snoopi_deep.jl:1734 [inlined]
 [23915] #printnode#23
       @ ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:87 [inlined]
 [23916] printnode
       @ ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:87 [inlined]
 [23917] print_tree(printnode::typeof(AbstractTrees.printnode), print_child_key::typeof(AbstractTrees.print_child_key), io::IOContext{Base.TTY}, node::SnoopCompile.SuggestNode; maxdepth::Int64, indicate_truncation::Bool, charset::AbstractTrees.TreeCharSet, printkeys::Nothing, depth::Int64, prefix::String, kw::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
       @ AbstractTrees ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:201
 [23918] print_tree
       @ ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:190 [inlined]
 [23919] #print_tree#27
       @ ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:272 [inlined]
 [23920] print_tree
       @ ~/.julia/packages/AbstractTrees/EUx8s/src/printing.jl:272 [inlined]
 [23921] show
       @ ~/.julia/packages/SnoopCompile/Ul2N6/src/parcel_snoopi_deep.jl:1734 [inlined]
 [23922] show(io::IOContext{Base.TTY}, #unused#::MIME{Symbol("text/plain")}, x::SnoopCompile.SuggestNode)
       @ Base.Multimedia ./multimedia.jl:47
 [23923] (::REPL.var"#43#44"{REPL.REPLDisplay{REPL.LineEditREPL}, MIME{Symbol("text/plain")}, Base.RefValue{Any}})(io::Any)
       @ REPL ~/.julia/juliaup/julia-1.8.5+0.x64.linux.gnu/share/julia/stdlib/v1.8/REPL/src/REPL.jl:267
 [23924] with_repl_linfo(f::Any, repl::REPL.LineEditREPL)
       @ REPL ~/.julia/juliaup/julia-1.8.5+0.x64.linux.gnu/share/julia/stdlib/v1.8/REPL/src/REPL.jl:521
 [23925] display(d::REPL.REPLDisplay, mime::MIME{Symbol("text/plain")}, x::Any)
       @ REPL ~/.julia/juliaup/julia-1.8.5+0.x64.linux.gnu/share/julia/stdlib/v1.8/REPL/src/REPL.jl:260
 [23926] display(d::REPL.REPLDisplay, x::Any)
       @ REPL ~/.julia/juliaup/julia-1.8.5+0.x64.linux.gnu/share/julia/stdlib/v1.8/REPL/src/REPL.jl:272
 [23927] display(x::Any)
       @ Base.Multimedia ./multimedia.jl:328
 [23928] #invokelatest#2
       @ ./essentials.jl:729 [inlined]
 [23929] invokelatest
       @ ./essentials.jl:726 [inlined]
 [23930] print_response(errio::IO, response::Any, show_value::Bool, have_color::Bool, specialdisplay::Union{Nothing, AbstractDisplay})
       @ REPL ~/.julia/juliaup/julia-1.8.5+0.x64.linux.gnu/share/julia/stdlib/v1.8/REPL/src/REPL.jl:296
 [23931] (::REPL.var"#45#46"{REPL.LineEditREPL, Pair{Any, Bool}, Bool, Bool})(io::Any)
       @ REPL ~/.julia/juliaup/julia-1.8.5+0.x64.linux.gnu/share/julia/stdlib/v1.8/REPL/src/REPL.jl:278
 [23932] with_repl_linfo(f::Any, repl::REPL.LineEditREPL)
       @ REPL ~/.julia/juliaup/julia-1.8.5+0.x64.linux.gnu/share/julia/stdlib/v1.8/REPL/src/REPL.jl:521
 [23933] print_response(repl::REPL.AbstractREPL, response::Any, show_value::Bool, have_color::Bool)
       @ REPL ~/.julia/juliaup/julia-1.8.5+0.x64.linux.gnu/share/julia/stdlib/v1.8/REPL/src/REPL.jl:276
 [23934] (::REPL.var"#do_respond#66"{Bool, Bool, REPL.var"#77#87"{REPL.LineEditREPL, REPL.REPLHistoryProvider}, REPL.LineEditREPL, REPL.LineEdit.Prompt})(s::REPL.LineEdit.MIState, buf::Any, ok::Bool)
       @ REPL ~/.julia/juliaup/julia-1.8.5+0.x64.linux.gnu/share/julia/stdlib/v1.8/REPL/src/REPL.jl:857
 [23935] #invokelatest#2
       @ ./essentials.jl:729 [inlined]
 [23936] invokelatest
       @ ./essentials.jl:726 [inlined]
 [23937] run_interface(terminal::REPL.Terminals.TextTerminal, m::REPL.LineEdit.ModalInterface, s::REPL.LineEdit.MIState)
       @ REPL.LineEdit ~/.julia/juliaup/julia-1.8.5+0.x64.linux.gnu/share/julia/stdlib/v1.8/REPL/src/LineEdit.jl:2510
 [23938] run_frontend(repl::REPL.LineEditREPL, backend::REPL.REPLBackendRef)
       @ REPL ~/.julia/juliaup/julia-1.8.5+0.x64.linux.gnu/share/julia/stdlib/v1.8/REPL/src/REPL.jl:1248
julia> versioninfo()
Julia Version 1.8.5
Commit 17cfb8e65ea (2023-01-08 06:45 UTC)
Platform Info:
  OS: Linux (x86_64-linux-gnu)
  CPU: 8 × Intel(R) Core(TM) i7-9700K CPU @ 3.60GHz
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-13.0.1 (ORCJIT, skylake)
  Threads: 8 on 8 virtual cores
Environment:
  JULIA_PKG_USE_CLI_GIT = true
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