diff options
author | Cedric Nugteren <web@cedricnugteren.nl> | 2016-06-17 14:30:37 +0200 |
---|---|---|
committer | Cedric Nugteren <web@cedricnugteren.nl> | 2016-06-17 14:30:37 +0200 |
commit | f9947b4d7ffedcf98cdb128de835422f647e7f15 (patch) | |
tree | c42d427a23de5d14b3407943d529d18cd9e516f0 /src/routines/level3/xsyr2k.cc | |
parent | 536b7fe4bce4b183cb060a1b9045752ae39d842f (diff) |
Removed the precision argument from the routines in favor of a single templated function
Diffstat (limited to 'src/routines/level3/xsyr2k.cc')
-rw-r--r-- | src/routines/level3/xsyr2k.cc | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/src/routines/level3/xsyr2k.cc b/src/routines/level3/xsyr2k.cc index 88bb5387..b517520c 100644 --- a/src/routines/level3/xsyr2k.cc +++ b/src/routines/level3/xsyr2k.cc @@ -19,19 +19,10 @@ namespace clblast { // ================================================================================================= -// Specific implementations to get the memory-type based on a template argument -template <> const Precision Xsyr2k<half>::precision_ = Precision::kHalf; -template <> const Precision Xsyr2k<float>::precision_ = Precision::kSingle; -template <> const Precision Xsyr2k<double>::precision_ = Precision::kDouble; -template <> const Precision Xsyr2k<float2>::precision_ = Precision::kComplexSingle; -template <> const Precision Xsyr2k<double2>::precision_ = Precision::kComplexDouble; - -// ================================================================================================= - // Constructor: forwards to base class constructor template <typename T> Xsyr2k<T>::Xsyr2k(Queue &queue, EventPointer event, const std::string &name): - Routine<T>(queue, event, name, {"Copy","Pad","Transpose","Padtranspose","Xgemm"}, precision_) { + Routine<T>(queue, event, name, {"Copy","Pad","Transpose","Padtranspose","Xgemm"}, PrecisionValue<T>()) { source_string_ = #include "../../kernels/level3/level3.opencl" #include "../../kernels/level3/copy_fast.opencl" @@ -93,7 +84,7 @@ StatusCode Xsyr2k<T>::DoSyr2k(const Layout layout, const Triangle triangle, cons try { // Loads the program from the database - const auto program = GetProgramFromCache(context_, precision_, routine_name_); + const auto program = GetProgramFromCache(context_, PrecisionValue<T>(), routine_name_); // Determines whether or not temporary matrices are needed auto a_no_temp = ab_one == n_ceiled && ab_two == k_ceiled && a_ld == n_ceiled && a_offset == 0 && |