Skip to content

Commit 5223531

Browse files
authored
feat: support Static 1+ (#192)
* feat: support Static 1+ * fix: update Aqua tests to latest version
1 parent d9ef1e0 commit 5223531

File tree

4 files changed

+10
-11
lines changed

4 files changed

+10
-11
lines changed

Project.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "Octavian"
22
uuid = "6fd5a793-0b7e-452c-907f-f8bfe9c57db4"
33
authors = ["Chris Elrod", "Dilum Aluthge", "Mason Protter", "contributors"]
4-
version = "0.3.27"
4+
version = "0.3.28"
55

66
[deps]
77
CPUSummary = "2a0fbf3d-bb9c-48f3-b0a9-814d99fd7ab9"
@@ -34,7 +34,7 @@ LoopVectorization = "0.12.86"
3434
ManualMemory = "0.1.1"
3535
PolyesterWeave = "0.1.1, 0.2"
3636
PrecompileTools = "1"
37-
Static = "0.8.4"
37+
Static = "0.8.4, 1"
3838
StaticArrayInterface = "1"
3939
ThreadingUtilities = "0.5"
4040
VectorizationBase = "0.21.15"

src/matmul.jl

+2-2
Original file line numberDiff line numberDiff line change
@@ -965,7 +965,7 @@ function sync_mul!(
965965
while _atomic_load(atomp) sync_iters
966966
pause()
967967
end
968-
atomp += cache_linesize()
968+
atomp = __add(atomp, cache_linesize())
969969
end
970970
end
971971
# multiply
@@ -994,7 +994,7 @@ function sync_mul!(
994994
while _atomic_load(atomp + 4) sync_iters
995995
pause()
996996
end
997-
atomp += cache_linesize()
997+
atomp = __add(atomp, cache_linesize())
998998
end
999999
end
10001000
end

src/utils.jl

+4
Original file line numberDiff line numberDiff line change
@@ -103,3 +103,7 @@ end
103103
stridedpointer($gf(sp, :p), si, StaticInt{$Bn}())
104104
end
105105
end
106+
107+
__add(x, y) = x + y
108+
__add(x::Ptr, ::StaticInt{N}) where {N} = x + N
109+
__add(::StaticInt{N}, y::Ptr) where {N} = y + N

test/aqua.jl

+2-7
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,4 @@
11
@testset "Aqua.jl" begin
2-
Aqua.test_all(
3-
Octavian;
4-
ambiguities = false,
5-
project_toml_formatting = false,
6-
stale_deps = (; ignore = [:ForwardDiff])
7-
)
8-
@test isempty(Test.detect_ambiguities(Octavian))
2+
Aqua.test_all(Octavian; deps_compat=false, ambiguities=false)
3+
Aqua.test_ambiguities(Octavian; recursive=false)
94
end

0 commit comments

Comments
 (0)