Giter Site home page Giter Site logo

cpusummary.jl's People

Contributors

chriselrod avatar github-actions[bot] avatar mkitti avatar ranocha avatar tokazama avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

cpusummary.jl's Issues

Failed to precompile CPUSummary on x86

I don't know if it is a known issue, but the CPUSummary does not precompile on x86. I noticed from the CI of my ArDCA package.

More precisely, it fails on

But Julia v1.6 passes on all x86. The same precompilation error occurs in LoopVectorization.
I see that only Julia 1.6 is currently tested here. Perhaps later Julia versions are still not supported on x86.

CPUSummary.jl v0.1.14 breaks CI of Trixi.jl on skylake-avx512

We observed some specific problems when going from CPUSummary.jl v0.1.8 to v0.1.14 at Trixi.jl. Everything is fine with the old version of CPUSummary.jl. CI also passes with the new version unless the GitHub CI runner happens to use LLVM: libLLVM-12.0.1 (ORCJIT, skylake-avx512) (either ubuntu-latest or windows-latest).
I could reduce this problem at https://github.com/trixi-framework/TrixiDebug.jl. Using the latest version of CPUSummary.jl, CI fails on

Restricting CPUSummary.jl to v0.1.8 let's CI pass on

So far, we have not been able to reproduce this locally...

For context: We use some matrix multiplications based on matmul! from Octavian.jl. To me, it seems like these multiplications fail catastrophically, resulting in the errors shown in CI.

CC @sloede

Failed to precompile CPUSummary v.0.1.26

ERROR: LoadError: DimensionMismatch: arrays could not be broadcast to a common size; got a dimension with lengths 0 and 3
Stacktrace:
  [1] _bcs1
    @ ./broadcast.jl:516 [inlined]
  [2] _bcs
    @ ./broadcast.jl:510 [inlined]
  [3] broadcast_shape(::Tuple{Base.OneTo{Int64}}, ::Tuple{Base.OneTo{Int64}})
    @ Base.Broadcast ./broadcast.jl:504
  [4] combine_axes
    @ ./broadcast.jl:499 [inlined]
  [5] _axes
    @ ./broadcast.jl:224 [inlined]
  [6] axes
    @ ./broadcast.jl:222 [inlined]
  [7] copy
    @ ./broadcast.jl:1072 [inlined]
  [8] materialize(bc::Base.Broadcast.Broadcasted{Base.Broadcast.Style{Tuple}, Nothing, typeof(div), Tuple{Tuple{}, Tuple{Int64, Int64, Int64}}})
    @ Base.Broadcast ./broadcast.jl:860
  [9] top-level scope
    @ /opt/julia/packages/CPUSummary/WuyJY/src/x86.jl:29
 [10] include(mod::Module, _path::String)
    @ Base ./Base.jl:419
 [11] include(x::String)
    @ CPUSummary /opt/julia/packages/CPUSummary/WuyJY/src/CPUSummary.jl:1
 [12] top-level scope
    @ /opt/julia/packages/CPUSummary/WuyJY/src/CPUSummary.jl:46
 [13] include
    @ ./Base.jl:419 [inlined]
 [14] 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, UInt64}}, source::String)
    @ Base ./loading.jl:1554
 [15] top-level scope
    @ stdin:1
in expression starting at /opt/julia/packages/CPUSummary/WuyJY/src/x86.jl:29
in expression starting at /opt/julia/packages/CPUSummary/WuyJY/src/CPUSummary.jl:1
in expression starting at stdin:1
ERROR: LoadError: Failed to precompile CPUSummary [2a0fbf3d-bb9c-48f3-b0a9-814d99fd7ab9] to /opt/julia/compiled/v1.8/CPUSummary/jl_lTeBWI.

Invalidations

Continuing from JuliaLang/julia#41913:

It's not just Polyester:

 deleting num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42 invalidated:
   mt_backedges:  1: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for Polyester.worker_size() (1 children)
                  2: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for Polyester._batch_no_reserve(::Polyester.var"#11#12", ::UInt16, ::UInt32, ::UInt16, ::UInt64, ::UInt64, ::UInt64, ::Static.StaticInt{1}, ::Static.StaticInt{1}) (1 children)
                  3: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for TriangularSolve.div_dispatch!(::Matrix{Float64}, ::Matrix{Float64}, ::Matrix{Float64}, ::Val{true}, ::Val{true}) (1 children)
                  4: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for TriangularSolve.nmuladd!(::VectorizationBase.StridedPointer{Float64, 2, 2, 0, (2, 1), Tuple{Int64, Static.StaticInt{8}}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::VectorizationBase.StridedPointer{Float64, 2, 2, 0, (2, 1), Tuple{Int64, Static.StaticInt{8}}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::VectorizationBase.StridedPointer{Float64, 2, 2, 0, (2, 1), Tuple{Int64, Static.StaticInt{8}}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::Int64, ::Int64, ::Int64) (1 children)
                  5: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for TriangularSolve.multithread_rdiv!(::VectorizationBase.StridedPointer{Float64, 2, 2, 0, (2, 1), Tuple{Int64, Static.StaticInt{8}}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::VectorizationBase.StridedPointer{Float64, 2, 2, 0, (2, 1), Tuple{Int64, Static.StaticInt{8}}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::VectorizationBase.StridedPointer{Float64, 2, 2, 0, (2, 1), Tuple{Int64, Static.StaticInt{8}}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::Int64, ::Int64, ::Int64, ::Val{false}, ::Static.StaticInt{2}) (1 children)
                  6: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for TriangularSolve.div_dispatch!(::LinearAlgebra.Transpose{Float64, Matrix{Float64}}, ::LinearAlgebra.Transpose{Float64, Matrix{Float64}}, ::LinearAlgebra.Transpose{Float64, Matrix{Float64}}, ::Val{true}, ::Val{true}) (1 children)
                  7: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for TriangularSolve.multithread_rdiv!(::VectorizationBase.StridedPointer{Float64, 2, 2, 0, (2, 1), Tuple{Int64, Static.StaticInt{8}}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::VectorizationBase.StridedPointer{Float64, 2, 2, 0, (2, 1), Tuple{Int64, Static.StaticInt{8}}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::VectorizationBase.StridedPointer{Float64, 2, 2, 0, (2, 1), Tuple{Int64, Static.StaticInt{8}}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::Int64, ::Int64, ::Int64, ::Val{true}, ::Static.StaticInt{2}) (1 children)
                  8: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for TriangularSolve._nthreads() (1 children)
                  9: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for TriangularSolve.div_dispatch!(::LinearAlgebra.Transpose{Float64, Matrix{Float64}}, ::LinearAlgebra.Transpose{Float64, Matrix{Float64}}, ::LinearAlgebra.Transpose{Float64, Matrix{Float64}}, ::Val{false}, ::Val{true}) (1 children)
                 10: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for TriangularSolve.multithread_rdiv!(::VectorizationBase.StridedPointer{Float64, 2, 1, 0, (1, 2), Tuple{Static.StaticInt{8}, Int64}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::VectorizationBase.StridedPointer{Float64, 2, 1, 0, (1, 2), Tuple{Static.StaticInt{8}, Int64}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::VectorizationBase.StridedPointer{Float64, 2, 1, 0, (1, 2), Tuple{Static.StaticInt{8}, Int64}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::Int64, ::Int64, ::Int64, ::Val{false}, ::Static.StaticInt{1}) (1 children)
                 11: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for TriangularSolve.multithread_rdiv!(::VectorizationBase.StridedPointer{Float64, 2, 1, 0, (1, 2), Tuple{Static.StaticInt{8}, Int64}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::VectorizationBase.StridedPointer{Float64, 2, 1, 0, (1, 2), Tuple{Static.StaticInt{8}, Int64}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::VectorizationBase.StridedPointer{Float64, 2, 1, 0, (1, 2), Tuple{Static.StaticInt{8}, Int64}, Tuple{Static.StaticInt{0}, Static.StaticInt{0}}}, ::Int64, ::Int64, ::Int64, ::Val{true}, ::Static.StaticInt{1}) (1 children)
                 12: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for TriangularSolve.div_dispatch!(::Matrix{Float64}, ::Matrix{Float64}, ::Matrix{Float64}, ::Val{false}, ::Val{true}) (1 children)
                 13: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for RecursiveFactorization.recurse!(::StrideArraysCore.PtrArray{Tuple{Int64, Int64}, (true, true), Float64, 2, 1, 0, (1, 2), Tuple{Static.StaticInt{8}, Int64}, Tuple{Static.StaticInt{1}, Static.StaticInt{1}}}, ::Val{true}, ::Int64, ::Int64, ::Int64, ::StrideArraysCore.PtrArray{Tuple{Int64}, (true,), Int64, 1, 1, 0, (1,), Tuple{Static.StaticInt{8}}, Tuple{Static.StaticInt{1}}}, ::Int64, ::Int64) (1 children)
                 14: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for RecursiveFactorization.apply_permutation_threaded!(::StrideArraysCore.PtrArray{Tuple{Int64}, (true,), Int64, 1, 1, 0, (1,), Tuple{Static.StaticInt{8}}, Tuple{Static.StaticInt{1}}}, ::StrideArraysCore.PtrArray{Tuple{Int64, Int64}, (true, false), Float64, 2, 1, 0, (1, 2), Tuple{Static.StaticInt{8}, Int64}, Tuple{Static.StaticInt{1}, Static.StaticInt{1}}}) (1 children)
                 15: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for RecursiveFactorization.apply_permutation_threaded!(::StrideArraysCore.PtrArray{Tuple{Int64}, (true,), Int64, 1, 1, 0, (1,), Tuple{Static.StaticInt{8}}, Tuple{Static.StaticInt{1}}}, ::Any) (1 children)
                 16: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for RecursiveFactorization.apply_permutation_threaded!(::StrideArraysCore.PtrArray{Tuple{Int64}, (true,), Int64, 1, 1, 0, (1,), Tuple{Static.StaticInt{8}}, Tuple{Static.StaticInt{1}}}, ::StrideArraysCore.PtrArray{Tuple{Int64, Int64}, (true, true), Float64, 2, 1, 0, (1, 2), Tuple{Static.StaticInt{8}, Int64}, Tuple{Static.StaticInt{1}, Static.StaticInt{1}}}) (1 children)
                 17: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for DiffEqBase.var"#_#32"(::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}, ::DiffEqBase.LUFactorize, ::Vector{Float64}, ::Matrix{Float64}, ::Vector{Float64}, ::Bool) (1 children)
                 18: signature num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:94 (formerly num_threads() in CPUSummary at /home/tim/.julia/dev/CPUSummary/src/topology.jl:42) triggered MethodInstance for OrdinaryDiffEq.compute_step!(::OrdinaryDiffEq.NLSolver{NLNewton{Rational{Int64}, Rational{Int64}, Rational{Int64}}, true, Vector{Float64}, Float64, Nothing, Float64, Ordin...

The way I have it set:

julia> Sys.CPU_THREADS
4

julia> Threads.nthreads()
1

which may explain why I'm seeing those invalidations and others may not?

InitError when porting precompiled module

Similar to JuliaSIMD/VectorizationBase.jl#57, I experience the following InitError, when porting the precompiled module between different machines. Seems to be the same bug, but now triggered in a different subpackage of LoopVectorization.

ERROR: InitError: TypeError: non-boolean (Nothing) used in boolean context
Stacktrace:
  [1] _define_cache(N::Int64, c::NamedTuple{(:size, :linesize, :associativity, :type, :inclusive), Tuple{Int64, Int64, Nothing, Nothing, Nothing}})
    @ CPUSummary ~/.julia/packages/CPUSummary/ZAemo/src/topology.jl:221
  [2] redefine_cache(N::Int64)
    @ CPUSummary ~/.julia/packages/CPUSummary/ZAemo/src/topology.jl:246
  [3] foreach
    @ ./abstractarray.jl:2694 [inlined]
  [4] __init__()
    @ CPUSummary ~/.julia/packages/CPUSummary/ZAemo/src/CPUSummary.jl:18
  [5] _include_from_serialized(path::String, depmods::Vector{Any})
    @ Base ./loading.jl:768
  [6] _require_search_from_serialized(pkg::Base.PkgId, sourcepath::String)
    @ Base ./loading.jl:854
  [7] _tryrequire_from_serialized(modkey::Base.PkgId, build_id::UInt64, modpath::String)
    @ Base ./loading.jl:783
  [8] _require_search_from_serialized(pkg::Base.PkgId, sourcepath::String)
    @ Base ./loading.jl:843
  [9] _tryrequire_from_serialized(modkey::Base.PkgId, build_id::UInt64, modpath::String)
    @ Base ./loading.jl:783
 [10] _require_search_from_serialized(pkg::Base.PkgId, sourcepath::String)
    @ Base ./loading.jl:843
 [11] _require(pkg::Base.PkgId)
    @ Base ./loading.jl:1097
 [12] require(uuidkey::Base.PkgId)
    @ Base ./loading.jl:1013
 [13] require(into::Module, mod::Symbol)
    @ Base ./loading.jl:997
during initialization of module CPUSummary

TagBot trigger issue

This issue is used to trigger TagBot; feel free to unsubscribe.

If you haven't already, you should update your TagBot.yml to include issue comment triggers.
Please see this post on Discourse for instructions and more details.

If you'd like for me to do this for you, comment TagBot fix on this issue.
I'll open a PR within a few hours, please be patient!

Warning: `cpucores_total()` is deprecated, use `cputhreads()` instead.

┌ Warning: `cpucores_total()` is deprecated, use `cputhreads()` instead.
│   caller = _get_num_cores at x86.jl:10 [inlined]
└ @ Core C:\Users\Hossein Pourbozorg\.julia\packages\CPUSummary\oVNmm\src\x86.jl:10
┌ Warning: `cpucores_total()` is deprecated, use `cputhreads()` instead.
│   caller = _get_num_cores at x86.jl:10 [inlined]
└ @ Core C:\Users\Hossein Pourbozorg\.julia\packages\CPUSummary\oVNmm\src\x86.jl:10
┌ Warning: `cpucores_total()` is deprecated, use `cputhreads()` instead.
│   caller = _extra_init() at x86.jl:60
└ @ CPUSummary C:\Users\Hossein Pourbozorg\.julia\packages\CPUSummary\oVNmm\src\x86.jl:60

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.