8989
9090# The methods below are specialized on the mortar type
9191# and called from the basic `create_cache` method at the top.
92- function create_cache (mesh:: Union {TreeMesh{2 }, StructuredMesh{2 }, UnstructuredMesh2D,
93- P4estMesh{2 }, P4estMeshView{2 }, T8codeMesh{2 }},
94- equations, mortar_l2:: LobattoLegendreMortarL2 , uEltype)
92+ function create_cache (mesh:: TreeMesh{2} , equations,
93+ mortar_l2:: LobattoLegendreMortarL2 , uEltype)
9594 # TODO : Taal performance using different types
96- MA2d = MArray{Tuple{nvariables (equations), nnodes (mortar_l2)}, uEltype, 2 ,
95+ MA2d = MArray{Tuple{nvariables (equations), nnodes (mortar_l2)},
96+ uEltype, 2 ,
9797 nvariables (equations) * nnodes (mortar_l2)}
9898 fstar_primary_upper_threaded = MA2d[MA2d (undef) for _ in 1 : Threads. nthreads ()]
9999 fstar_primary_lower_threaded = MA2d[MA2d (undef) for _ in 1 : Threads. nthreads ()]
@@ -104,8 +104,10 @@ function create_cache(mesh::Union{TreeMesh{2}, StructuredMesh{2}, UnstructuredMe
104104 # fstar_upper_threaded = [A2d(undef, nvariables(equations), nnodes(mortar_l2)) for _ in 1:Threads.nthreads()]
105105 # fstar_lower_threaded = [A2d(undef, nvariables(equations), nnodes(mortar_l2)) for _ in 1:Threads.nthreads()]
106106
107- (; fstar_primary_upper_threaded, fstar_primary_lower_threaded,
108- fstar_secondary_upper_threaded, fstar_secondary_lower_threaded)
107+ cache = (; fstar_primary_upper_threaded, fstar_primary_lower_threaded,
108+ fstar_secondary_upper_threaded, fstar_secondary_lower_threaded)
109+
110+ return cache
109111end
110112
111113# TODO : Taal discuss/refactor timer, allowing users to pass a custom timer?
0 commit comments