Skip to content

Commit

Permalink
get_cpu_name
Browse files Browse the repository at this point in the history
  • Loading branch information
chriselrod committed Nov 14, 2022
1 parent 6da3643 commit 693f6fc
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "LoopVectorization"
uuid = "bdcacae8-1622-11e9-2a5c-532679323890"
authors = ["Chris Elrod <[email protected]>"]
version = "0.12.138"
version = "0.12.139"

[deps]
ArrayInterface = "4fba245c-0d91-5ea0-9b3e-6abc04ee57a9"
Expand Down Expand Up @@ -39,7 +39,7 @@ ChainRulesCore = "1"
CloseOpenIntervals = "0.1.10"
DocStringExtensions = "0.8, 0.9"
ForwardDiff = "0.9, 0.10"
HostCPUFeatures = "0.1.3"
HostCPUFeatures = "0.1.10"
IfElse = "0.1"
LayoutPointers = "0.1.11"
OffsetArrays = "1.4.1"
Expand Down
2 changes: 1 addition & 1 deletion src/LoopVectorization.jl
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ using VectorizationBase:
maybestaticsize#,zero_mask

using HostCPUFeatures:
pick_vector_width, register_size, register_count, has_opmask_registers, unwrap
pick_vector_width, register_size, register_count, has_opmask_registers, unwrap, get_cpu_name
using CPUSummary: num_threads, num_cores, cache_linesize, cache_size


Expand Down
2 changes: 1 addition & 1 deletion src/codegen/lowering.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1039,7 +1039,7 @@ function calc_Ureduct!(ls::LoopSet, us::UnrollSpecification)
# rem = length(u₁loop) -
# max(1, cld(rem, u₁))
else
Core.ifelse(Sys.CPU_NAME === "znver1", 1, Core.ifelse(u₁ 4, 2, 1))
Core.ifelse(get_cpu_name() === "znver1", 1, Core.ifelse(u₁ 4, 2, 1))
end
else
-1
Expand Down

2 comments on commit 693f6fc

@chriselrod
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/72160

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.12.139 -m "<description of version>" 693f6fcc07802436b2211fa897b77bbb3a9bb974
git push origin v0.12.139

Please sign in to comment.