2
2
# # Borrowed from Knet.jl, adapted for compile-time constants
3
3
4
4
using LinearAlgebra
5
- using LinearAlgebra. BLAS: libblas , BlasInt, @blasfunc
5
+ using LinearAlgebra. BLAS: libblastrampoline , BlasInt, @blasfunc
6
6
7
7
using Compat: get_num_threads, set_num_threads # needs Compat 3.13, for any Julia < 1.6
8
8
@@ -48,7 +48,7 @@ for (gemm, elt) in gemm_datatype_mappings
48
48
ldb = N
49
49
end
50
50
ldc = M
51
- ccall ((@blasfunc ($ (gemm)), libblas ), Nothing,
51
+ ccall ((@blasfunc ($ (gemm)), libblastrampoline ), Nothing,
52
52
(Ref{UInt8}, Ref{UInt8}, Ref{BlasInt}, Ref{BlasInt},
53
53
Ref{BlasInt}, Ref{$ elt}, Ptr{$ elt}, Ref{BlasInt},
54
54
Ptr{$ elt}, Ref{BlasInt}, Ref{$ elt}, Ptr{$ elt},
@@ -106,7 +106,7 @@ for (gemm, elt) in gemm_datatype_mappings
106
106
ptrBk = ptrB + (k- 1 ) * strB * sizeof ($ elt)
107
107
ptrCk = ptrC + (k- 1 ) * strC * sizeof ($ elt)
108
108
109
- ccall ((@blasfunc ($ (gemm)), libblas ), Nothing,
109
+ ccall ((@blasfunc ($ (gemm)), libblastrampoline ), Nothing,
110
110
(Ref{UInt8}, Ref{UInt8}, Ref{BlasInt}, Ref{BlasInt},
111
111
Ref{BlasInt}, Ref{$ elt}, Ptr{$ elt}, Ref{BlasInt},
112
112
Ptr{$ elt}, Ref{BlasInt}, Ref{$ elt}, Ptr{$ elt},
@@ -128,7 +128,7 @@ for (gemm, elt) in gemm_datatype_mappings
128
128
ptrBk = ptrB + (k- 1 ) * strB * sizeof ($ elt)
129
129
ptrCk = ptrC + (k- 1 ) * strC * sizeof ($ elt)
130
130
131
- ccall ((@blasfunc ($ (gemm)), libblas ), Nothing,
131
+ ccall ((@blasfunc ($ (gemm)), libblastrampoline ), Nothing,
132
132
(Ref{UInt8}, Ref{UInt8}, Ref{BlasInt}, Ref{BlasInt},
133
133
Ref{BlasInt}, Ref{$ elt}, Ptr{$ elt}, Ref{BlasInt},
134
134
Ptr{$ elt}, Ref{BlasInt}, Ref{$ elt}, Ptr{$ elt},
0 commit comments