Example #1
0
 static StatusCode RunReference2(const Arguments<U> &args, BuffersHost<T> &buffers_host, Queue&) {
   cblasXhpr(convertToCBLAS(args.layout),
             convertToCBLAS(args.triangle),
             args.n, args.alpha,
             buffers_host.x_vec, args.x_offset, args.x_inc,
             buffers_host.ap_mat, args.ap_offset);
   return StatusCode::kSuccess;
 }
Example #2
0
 static StatusCode RunReference2(const Arguments<T> &args, BuffersHost<T> &buffers_host, Queue &) {
   cblasXgbmv(convertToCBLAS(args.layout),
              convertToCBLAS(args.a_transpose),
              args.m, args.n, args.kl, args.ku, args.alpha,
              buffers_host.a_mat, args.a_offset, args.a_ld,
              buffers_host.x_vec, args.x_offset, args.x_inc, args.beta,
              buffers_host.y_vec, args.y_offset, args.y_inc);
   return StatusCode::kSuccess;
 }
Example #3
0
 static StatusCode RunReference2(const Arguments<T> &args, BuffersHost<T> &buffers_host, Queue &) {
   cblasXtrmv(convertToCBLAS(args.layout),
              convertToCBLAS(args.triangle),
              convertToCBLAS(args.a_transpose),
              convertToCBLAS(args.diagonal),
              args.n,
              buffers_host.a_mat, args.a_offset, args.a_ld,
              buffers_host.x_vec, args.x_offset, args.x_inc);
   return StatusCode::kSuccess;
 }
Example #4
0
File: xhpr.hpp Project: gcp/CLBlast
 static StatusCode RunReference2(const Arguments<U> &args, Buffers<T> &buffers, Queue &queue) {
   std::vector<T> ap_mat_cpu(args.ap_size, static_cast<T>(0));
   std::vector<T> x_vec_cpu(args.x_size, static_cast<T>(0));
   buffers.ap_mat.Read(queue, args.ap_size, ap_mat_cpu);
   buffers.x_vec.Read(queue, args.x_size, x_vec_cpu);
   cblasXhpr(convertToCBLAS(args.layout),
             convertToCBLAS(args.triangle),
             args.n, args.alpha,
             x_vec_cpu, args.x_offset, args.x_inc,
             ap_mat_cpu, args.ap_offset);
   buffers.ap_mat.Write(queue, args.ap_size, ap_mat_cpu);
   return StatusCode::kSuccess;
 }
Example #5
0
 static StatusCode RunReference2(const Arguments<T> &args, Buffers<T> &buffers, Queue &queue) {
   std::vector<T> a_mat_cpu(args.a_size, static_cast<T>(0));
   std::vector<T> x_vec_cpu(args.x_size, static_cast<T>(0));
   std::vector<T> y_vec_cpu(args.y_size, static_cast<T>(0));
   buffers.a_mat.Read(queue, args.a_size, a_mat_cpu);
   buffers.x_vec.Read(queue, args.x_size, x_vec_cpu);
   buffers.y_vec.Read(queue, args.y_size, y_vec_cpu);
   cblasXsbmv(convertToCBLAS(args.layout),
              convertToCBLAS(args.triangle),
              args.n, args.kl, args.alpha,
              a_mat_cpu, args.a_offset, args.a_ld,
              x_vec_cpu, args.x_offset, args.x_inc, args.beta,
              y_vec_cpu, args.y_offset, args.y_inc);
   buffers.y_vec.Write(queue, args.y_size, y_vec_cpu);
   return StatusCode::kSuccess;
 }
Example #6
0
 static StatusCode RunReference2(const Arguments<T> &args, Buffers<T> &buffers, Queue &queue) {
   std::vector<T> a_mat_cpu(args.a_size, static_cast<T>(0));
   std::vector<T> b_mat_cpu(args.b_size, static_cast<T>(0));
   std::vector<T> c_mat_cpu(args.c_size, static_cast<T>(0));
   buffers.a_mat.Read(queue, args.a_size, a_mat_cpu);
   buffers.b_mat.Read(queue, args.b_size, b_mat_cpu);
   buffers.c_mat.Read(queue, args.c_size, c_mat_cpu);
   cblasXhemm(convertToCBLAS(args.layout),
              convertToCBLAS(args.side),
              convertToCBLAS(args.triangle),
              args.m, args.n, args.alpha,
              a_mat_cpu, args.a_offset, args.a_ld,
              b_mat_cpu, args.b_offset, args.b_ld, args.beta,
              c_mat_cpu, args.c_offset, args.c_ld);
   buffers.c_mat.Write(queue, args.c_size, c_mat_cpu);
   return StatusCode::kSuccess;
 }