Skip to content

Commit 2b217a2

Browse files
Merge pull request #1914 from CliMA/ck/deprecate_dynamic_Nh
Add deprecations for removed static Nh
2 parents b38c1fb + e28c2b6 commit 2b217a2

File tree

3 files changed

+43
-0
lines changed

3 files changed

+43
-0
lines changed

NEWS.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,14 @@ ClimaCore.jl Release Notes
44
main
55
-------
66

7+
- Support for matrix fields on spectral and point spaces was added, PR [#1884](https://github.com/CliMA/ClimaCore.jl/pull/1884).
8+
- Support for 3-component DSS transform was added, PR [#1693](https://github.com/CliMA/ClimaCore.jl/pull/1693).
9+
- Support for column-wise "accumulate"/"reduce" operations were added, PR [#1903](https://github.com/CliMA/ClimaCore.jl/pull/1903). These abstractions will allow us to group, paralellize and optimize more column-wise work on the GPU.
10+
- A new macro, `Fields.@rprint_diff` was added, which recursively print differences between two `FieldVector`s (of the same type) (PR [#1886](https://github.com/CliMA/ClimaCore.jl/pull/1886)).
11+
- Julia 1.11 fixes (PR [#1883](https://github.com/CliMA/ClimaCore.jl/pull/1883))
12+
- `Nh` has been added to the type parameter space, which allows us to more flexibly write performant backend kernels (PR [#1894](https://github.com/CliMA/ClimaCore.jl/pull/1894)). This was leveraged in PR [#1898](https://github.com/CliMA/ClimaCore.jl/pull/1898), and may result in slightly more performant kernels.
13+
14+
715
v0.14.10
816
-------
917

src/deprecated.jl

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import .Spaces:
88
FiniteDifferenceSpace
99
import .Topologies: IntervalTopology
1010
import .Meshes: IntervalMesh
11+
import .DataLayouts
1112

1213
@deprecate IntervalTopology(mesh::IntervalMesh) IntervalTopology(
1314
ClimaComms.SingletonCommsContext(ClimaComms.device()),
@@ -26,3 +27,29 @@ import .Meshes: IntervalMesh
2627
@deprecate FiniteDifferenceGrid(mesh::IntervalMesh) FiniteDifferenceGrid(
2728
IntervalTopology(ClimaComms.device(), mesh),
2829
)
30+
31+
@deprecate DataLayouts.IJFH{S, Nij}(
32+
::Type{ArrayType},
33+
nelements,
34+
) where {S, Nij, ArrayType} DataLayouts.IJFH{S, Nij, nelements}(ArrayType) false
35+
36+
@deprecate DataLayouts.IJFH{S, Nij}(
37+
array::AbstractArray{T, 4},
38+
) where {S, Nij, T} DataLayouts.IJFH{S, Nij, size(array, 4)}(array) false
39+
@deprecate DataLayouts.IFH{S, Ni}(array::AbstractArray{T, 3}) where {S, Ni, T} DataLayouts.IFH{
40+
S,
41+
Ni,
42+
size(array, 3),
43+
}(
44+
array,
45+
) false
46+
@deprecate DataLayouts.IFH{S, Ni}(
47+
::Type{ArrayType},
48+
nelements,
49+
) where {S, Ni, ArrayType} DataLayouts.IFH{S, Ni, nelements}(ArrayType) false
50+
@deprecate DataLayouts.VIJFH{S, Nv, Nij}(
51+
array::AbstractArray{T, 5},
52+
) where {S, Nv, Nij, T} DataLayouts.VIJFH{S, Nv, Nij, size(array, 5)}(array) false
53+
@deprecate DataLayouts.VIFH{S, Nv, Ni}(
54+
array::AbstractArray{T, 4},
55+
) where {S, Nv, Ni, T} DataLayouts.VIFH{S, Nv, Ni, size(array, 4)}(array) false

test/deprecations.jl

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import ClimaCore.Spaces:
99
FaceFiniteDifferenceSpace,
1010
FiniteDifferenceSpace
1111
import ClimaCore.Grids: FiniteDifferenceGrid
12+
import ClimaCore.DataLayouts
1213
import ClimaComms
1314
ClimaComms.@import_required_backends
1415

@@ -44,6 +45,13 @@ ClimaComms.@import_required_backends
4445
@test_deprecated FaceFiniteDifferenceSpace(z_mesh)
4546
@test_deprecated CenterFiniteDifferenceSpace(z_mesh)
4647
@test_deprecated FiniteDifferenceGrid(z_mesh)
48+
49+
S = Float64
50+
@test_deprecated DataLayouts.IJFH{S, 3}(zeros(3, 3, 1, 10))
51+
@test_deprecated DataLayouts.IJFH{S, 3}(typeof(zeros(3, 3, 1, 10)), 10)
52+
@test_deprecated DataLayouts.IFH{S, 3}(zeros(3, 1, 10))
53+
@test_deprecated DataLayouts.VIJFH{S, 10, 4}(zeros(10, 4, 4, 1, 20))
54+
@test_deprecated DataLayouts.VIFH{S, 10, 4}(zeros(10, 4, 1, 20))
4755
end
4856

4957
nothing

0 commit comments

Comments
 (0)