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

FieldError: type OptimizationState has no field ir #625

Open
nsajko opened this issue Mar 9, 2025 · 1 comment
Open

FieldError: type OptimizationState has no field ir #625

nsajko opened this issue Mar 9, 2025 · 1 comment

Comments

@nsajko
Copy link

nsajko commented Mar 9, 2025

Cthulhu doesn't work on nightly even after Compiler is dev-ed:

julia> using Cthulhu
Info Given Cthulhu was explicitly requested, output will be shown live 
┌ Error: Errorred while running the precompile workload, the package may or may not work but latency will be long
│   exeption =
│    FieldError: type OptimizationState has no field `ir`, available fields: `linfo`, `src`, `result`, `stmt_info`, `mod`, `sptypes`, `slottypes`, `inlining`, `cfg`, `unreachable`, `bb_vartables`, `insert_coverage`
│    Stacktrace:
│      [1] getproperty
│        @ ./Base_compiler.jl:55 [inlined]
│      [2] create_cthulhu_source
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/interpreter.jl:129 [inlined]
│      [3] set_cthulhu_source!
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/interpreter.jl:138 [inlined]
│      [4] finish!
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/interpreter.jl:149 [inlined]
│      [5] finish_nocycle(::Cthulhu.CthulhuInterpreter, frame::Compiler.InferenceState)
│        @ Compiler ~/tmp/jl/julia-git/invalidations_build/Compiler/src/typeinfer.jl:207
│      [6] typeinf(interp::Cthulhu.CthulhuInterpreter, frame::Compiler.InferenceState)
│        @ Compiler ~/tmp/jl/julia-git/invalidations_build/Compiler/src/abstractinterpretation.jl:4393
│      [7] top-level scope
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:856
│      [8] top-level scope
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:868
│      [9] top-level scope
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:890
│     [10] top-level scope
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:888
│     [11] __descend_with_error_handling(args::Any; terminal::Any, kwargs...)
│        @ Cthulhu ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:275
│     [12] __descend_with_error_handling
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:272 [inlined]
│     [13] #_descend_with_error_handling#80
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:264 [inlined]
│     [14] _descend_with_error_handling
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:256 [inlined]
│     [15] descend
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:318 [inlined]
│     [16] macro expansion
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:972 [inlined]
│     [17] macro expansion
│        @ ~/.julia/packages/PrecompileTools/L8A3n/src/workloads.jl:78 [inlined]
│     [18] macro expansion
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:971 [inlined]
│     [19] macro expansion
│        @ ~/.julia/packages/PrecompileTools/L8A3n/src/workloads.jl:140 [inlined]
│     [20] top-level scope
│        @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:966
│     [21] include(mod::Module, _path::String)
│        @ Base ./Base.jl:305
│     [22] include_package_for_output(pkg::Base.PkgId, input::String, depot_path::Vector{String}, dl_load_path::Vector{String}, load_path::Vector{String}, concrete_deps::Vector{Pair{Base.PkgId, UInt128}}, source::Nothing)
│        @ Base ./loading.jl:3004
│     [23] top-level scope
│        @ stdin:6
│     [24] eval(m::Module, e::Any)
│        @ Core ./boot.jl:489
│     [25] include_string(mapexpr::typeof(identity), mod::Module, code::String, filename::String)
│        @ Base ./loading.jl:2855
│     [26] include_string
│        @ ./loading.jl:2865 [inlined]
│     [27] exec_options(opts::Base.JLOptions)
│        @ Base ./client.jl:326
│     [28] _start()
│        @ Base ./client.jl:560
└ @ Cthulhu ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:977
Precompiling Cthulhu finished.
  7 dependencies successfully precompiled in 109 seconds. 14 already precompiled.
  1 dependency had output during precompilation:
┌ Cthulhu
│  [Output was shown above]
└  

julia> @descend sin(0.3)
ERROR: FieldError: type OptimizationState has no field `ir`, available fields: `linfo`, `src`, `result`, `stmt_info`, `mod`, `sptypes`, `slottypes`, `inlining`, `cfg`, `unreachable`, `bb_vartables`, `insert_coverage`
Stacktrace:
  [1] getproperty
    @ ./Base_compiler.jl:55 [inlined]
  [2] create_cthulhu_source
    @ ~/.julia/packages/Cthulhu/OXvAA/src/interpreter.jl:129 [inlined]
  [3] set_cthulhu_source!
    @ ~/.julia/packages/Cthulhu/OXvAA/src/interpreter.jl:138 [inlined]
  [4] finish!
    @ ~/.julia/packages/Cthulhu/OXvAA/src/interpreter.jl:149 [inlined]
  [5] finish_nocycle(::Cthulhu.CthulhuInterpreter, frame::Compiler.InferenceState)
    @ Compiler ~/tmp/jl/julia-git/invalidations_build/Compiler/src/typeinfer.jl:207
  [6] typeinf(interp::Cthulhu.CthulhuInterpreter, frame::Compiler.InferenceState)
    @ Compiler ~/tmp/jl/julia-git/invalidations_build/Compiler/src/abstractinterpretation.jl:4393
  [7] do_typeinf!(interp::Cthulhu.CthulhuInterpreter, mi::Core.MethodInstance)
    @ Cthulhu ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:856
  [8] mkinterp(interp::Compiler.NativeInterpreter, args::Any)
    @ Cthulhu ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:868
  [9] #_descend#110
    @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:890 [inlined]
 [10] __descend_with_error_handling(args::Any; terminal::Any, kwargs...)
    @ Cthulhu ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:275
 [11] top-level scope
    @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:272
 [12] top-level scope
    @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:264
 [13] top-level scope
    @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:256
 [14] top-level scope
    @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:318
 [15] top-level scope
    @ ~/.julia/packages/Cthulhu/OXvAA/src/Cthulhu.jl:318
 [16] top-level scope
    @ REPL[2]:1

(@v1.13) pkg> st Compiler Cthulhu
Status `~/.julia/environments/v1.13/Project.toml`
  [807dbc54] Compiler v0.0.3 `../../../tmp/jl/julia-git/invalidations_build/Compiler`
  [f68482b8] Cthulhu v2.16.4
@nsajko
Copy link
Author

nsajko commented Mar 9, 2025

Julia Version 1.13.0-DEV.185
Commit bbcdc0f6a61 (2025-03-08 16:13 UTC)
Build Info:
  Official https://julialang.org release
Platform Info:
  OS: Linux (x86_64-linux-gnu)
  CPU: 8 × AMD Ryzen 3 5300U with Radeon Graphics
  WORD_SIZE: 64
  LLVM: libLLVM-19.1.7 (ORCJIT, znver2)
  GC: Built with stock GC
Threads: 1 default, 1 interactive, 1 GC (on 8 virtual cores)

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