aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJianzhong Xu2016-05-25 10:35:09 -0500
committerJianzhong Xu2016-05-25 10:35:09 -0500
commitd374425fdc610f7a1c5468ff60fbff619048d68c (patch)
tree8a69ec0f68811ae772c4d3944e748e8d9cdbc09e
parent206ede2f1d2b8e3f49069882362a03f0e2bc3f1b (diff)
downloadlinalg-d374425fdc610f7a1c5468ff60fbff619048d68c.tar.gz
linalg-d374425fdc610f7a1c5468ff60fbff619048d68c.tar.xz
linalg-d374425fdc610f7a1c5468ff60fbff619048d68c.zip
Code clean up and documentation.
-rw-r--r--src/ti/linalg/blasblisacc/src/facade.c24
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_acc.h224
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_caxpy.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ccopy.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cdotc_sub.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cdotu_sub.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgemm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgemv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgerc.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgeru.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chemm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chemv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher2k.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cherk.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpr.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpr2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_crotg.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cscal.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csscal.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cswap.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csymm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csyr2k.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csyrk.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctbsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctpmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctpsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrmm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrsm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dasum.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_daxpy.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dcopy.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ddot.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgemm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgemv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dger.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dnrm2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drot.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotg.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotmg.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dscal.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsdot.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspr.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspr2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dswap.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsymm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsymv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr2k.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyrk.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtbsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtpmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtpsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrmm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrsm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dzasum.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dznrm2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_icamax.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_idamax.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_isamax.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_izamax.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sasum.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_saxpy.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scasum.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scnrm2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scopy.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sdot.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sdsdot.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgemm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgemv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sger.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_snrm2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srot.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotg.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotmg.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sscal.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspr.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspr2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sswap.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssymm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssymv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr2k.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyrk.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stbsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stpmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stpsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strmm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strsm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_xerbla.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zaxpy.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zcopy.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdotc_sub.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdotu_sub.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdscal.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgemm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgemv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgerc.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgeru.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhemm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhemv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher2k.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zherk.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpr.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpr2.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zrotg.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zscal.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zswap.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsymm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsyr2k.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsyrk.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztbmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztbsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztpmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztpsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrmm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrmv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrsm.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrsv.c2
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_initfini.c501
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_kernel.cl13
-rw-r--r--src/ti/linalg/blasblisacc/src/ti_cblas_mem_config.c94
-rwxr-xr-xsrc/ti/linalg/blasblisacc/src/wrap_gen/oclgen.pl8
-rw-r--r--src/ti/linalg/blis/frame/base/bli_mem.c104
-rw-r--r--src/ti/linalg/blis/frame/base/bli_mem.h7
-rw-r--r--src/ti/linalg/ticblas/src/ticblas.c120
-rw-r--r--src/ti/linalg/ticblas/ticblas.h55
155 files changed, 635 insertions, 805 deletions
diff --git a/src/ti/linalg/blasblisacc/src/facade.c b/src/ti/linalg/blasblisacc/src/facade.c
index 547d983..8f896ea 100644
--- a/src/ti/linalg/blasblisacc/src/facade.c
+++ b/src/ti/linalg/blasblisacc/src/facade.c
@@ -24,26 +24,16 @@
24 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 24 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
25 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 25 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
26 * THE POSSIBILITY OF SUCH DAMAGE. 26 * THE POSSIBILITY OF SUCH DAMAGE.
27 *****************************************************************************/ 27 *****************************************************************************/
28
29#include "../../cblas/include/cblas.h" 28#include "../../cblas/include/cblas.h"
30#include "../../ticblas/ticblas.h" 29#include "../../ticblas/ticblas.h"
31 30
32#ifdef TI_CBLAS_DEBUG 31/*==============================================================================
33#include "stdio.h" 32 * This file contains functions of the DSP OpenCL layer of ARM+DSP CBLAS library.
34 33 *============================================================================*/
35extern char *pool_mk_mem_L1; 34
36extern char *pool_kn_mem_L1; 35extern int bli_l3_mem_config(void *msmc_buf, size_t msmc_buf_size, void *ddr_buf, size_t ddr_buf_size,
37extern char *pool_mn_mem_L1; 36 size_t *l1D_SRAM_size_orig, size_t *l2_SRAM_size_orig);
38extern char *pool_mk_mem_L2;
39extern char *pool_kn_mem_L2;
40extern char *pool_mn_mem_L2;
41extern char *pool_mk_mem_L3;
42extern char *pool_kn_mem_L3;
43extern char *pool_mn_mem_L3;
44#endif
45
46extern int bli_l3_mem_config(void *msmc_buf, size_t msmc_buf_size, void *ddr_buf, size_t ddr_buf_size, size_t *l1D_SRAM_size_orig, size_t *l2_SRAM_size_orig);
47extern int bli_l3_mem_reconfig(size_t l1D_SRAM_size_orig, size_t l2_SRAM_size_orig); 37extern int bli_l3_mem_reconfig(size_t l1D_SRAM_size_orig, size_t l2_SRAM_size_orig);
48 38
49 39
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_acc.h b/src/ti/linalg/blasblisacc/src/ti_cblas_acc.h
index 77d8a47..907391b 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_acc.h
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_acc.h
@@ -1,4 +1,3 @@
1
2/****************************************************************************** 1/******************************************************************************
3 * Copyright (c) 2013-2015, Texas Instruments Incorporated - http://www.ti.com/ 2 * Copyright (c) 2013-2015, Texas Instruments Incorporated - http://www.ti.com/
4 * All rights reserved. 3 * All rights reserved.
@@ -26,10 +25,8 @@
26 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 25 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
27 * THE POSSIBILITY OF SUCH DAMAGE. 26 * THE POSSIBILITY OF SUCH DAMAGE.
28 *****************************************************************************/ 27 *****************************************************************************/
29 28#ifndef TI_CBLAS_ACC_H
30 29#define TI_CBLAS_ACC_H
31#ifndef TI_CBLAS_H
32#define TI_CBLAS_H
33 30
34#ifdef __cplusplus 31#ifdef __cplusplus
35#include <cstdlib> 32#include <cstdlib>
@@ -125,19 +122,6 @@ extern void ti_cblas_init(void);
125extern err_t bli_finalize(); 122extern err_t bli_finalize();
126extern err_t bli_init(); 123extern err_t bli_init();
127 124
128
129#ifdef _cplusplus
130extern "C" { int ti_cblas_finalize(); }
131else
132 int ti_cblas_finalize(void);
133#endif
134
135#ifdef _cplusplus
136extern "C" { int ti_blis_init(); }
137else
138 int ti_blis_init(void);
139#endif
140
141void ti_cblas_auto_finalize(void); 125void ti_cblas_auto_finalize(void);
142 126
143void ti_cblas_mem_free(void *ptr); 127void ti_cblas_mem_free(void *ptr);
@@ -147,183 +131,17 @@ extern pthread_cond_t CV;
147extern pthread_mutex_t MUTEX; 131extern pthread_mutex_t MUTEX;
148 132
149 133
150#ifdef __cplusplus 134extern Kernel* ti_cblas_get_kernel(const char *fname);
151extern Kernel* ti_cblas_get_kernel(int idx, const char *fname); 135int ti_cblas_delete_kernel(Kernel* K);
152int ti_cblas_delete_kernel(Kernel* K); 136extern Context* ti_cblas_ocl_context;
153#if 0 137extern std::vector<Device>* ti_cblas_ocl_devices;
154extern Context ti_cblas_ocl_context; 138extern CommandQueue* ti_cblas_ocl_Q;
155extern std::vector<Device> ti_cblas_ocl_devices; 139extern Program::Binaries* ti_cblas_ocl_binary;
156extern CommandQueue ti_cblas_ocl_Q; 140extern Program* ti_cblas_ocl_program;
157extern Program::Binaries ti_cblas_ocl_binary;
158extern Program ti_cblas_ocl_program;
159extern Kernel* ti_cblas_ocl_kernels[];
160#else
161extern Context* ti_cblas_ocl_context;
162extern std::vector<Device>* ti_cblas_ocl_devices;
163extern CommandQueue* ti_cblas_ocl_Q;
164extern Program::Binaries* ti_cblas_ocl_binary;
165extern Program* ti_cblas_ocl_program;
166#endif
167#else
168extern cl_kernel ti_cblas_get_kernel(int idx, const char *fname);
169int ti_cblas_delete_kernel(cl_kernel K);
170extern cl_context ti_cblas_ocl_context;
171extern cl_command_queue ti_cblas_ocl_Q;
172extern cl_program ti_cblas_ocl_program;
173extern cl_kernel ti_cblas_ocl_kernels[];
174#endif
175 141
176extern int ti_cblas_init_done; 142extern int ti_cblas_init_done;
177extern int ti_cblas_kernel_valid[];
178extern int ti_cblas_offload; 143extern int ti_cblas_offload;
179 144
180#define TI_CBLAS_CBLAS_CAXPY_IDX 0
181#define TI_CBLAS_CBLAS_CCOPY_IDX 1
182#define TI_CBLAS_CBLAS_CDOTC_SUB_IDX 2
183#define TI_CBLAS_CBLAS_CDOTU_SUB_IDX 3
184#define TI_CBLAS_CBLAS_CGBMV_IDX 4
185#define TI_CBLAS_CBLAS_CGEMM_IDX 5
186#define TI_CBLAS_CBLAS_CGEMV_IDX 6
187#define TI_CBLAS_CBLAS_CGERC_IDX 7
188#define TI_CBLAS_CBLAS_CGERU_IDX 8
189#define TI_CBLAS_CBLAS_CHBMV_IDX 9
190#define TI_CBLAS_CBLAS_CHEMM_IDX 10
191#define TI_CBLAS_CBLAS_CHEMV_IDX 11
192#define TI_CBLAS_CBLAS_CHER_IDX 12
193#define TI_CBLAS_CBLAS_CHER2_IDX 13
194#define TI_CBLAS_CBLAS_CHER2K_IDX 14
195#define TI_CBLAS_CBLAS_CHERK_IDX 15
196#define TI_CBLAS_CBLAS_CHPMV_IDX 16
197#define TI_CBLAS_CBLAS_CHPR_IDX 17
198#define TI_CBLAS_CBLAS_CHPR2_IDX 18
199#define TI_CBLAS_CBLAS_CROTG_IDX 19
200#define TI_CBLAS_CBLAS_CSCAL_IDX 20
201#define TI_CBLAS_CBLAS_CSSCAL_IDX 21
202#define TI_CBLAS_CBLAS_CSWAP_IDX 22
203#define TI_CBLAS_CBLAS_CSYMM_IDX 23
204#define TI_CBLAS_CBLAS_CSYR2K_IDX 24
205#define TI_CBLAS_CBLAS_CSYRK_IDX 25
206#define TI_CBLAS_CBLAS_CTBMV_IDX 26
207#define TI_CBLAS_CBLAS_CTBSV_IDX 27
208#define TI_CBLAS_CBLAS_CTPMV_IDX 28
209#define TI_CBLAS_CBLAS_CTPSV_IDX 29
210#define TI_CBLAS_CBLAS_CTRMM_IDX 30
211#define TI_CBLAS_CBLAS_CTRMV_IDX 31
212#define TI_CBLAS_CBLAS_CTRSM_IDX 32
213#define TI_CBLAS_CBLAS_CTRSV_IDX 33
214#define TI_CBLAS_CBLAS_DASUM_IDX 34
215#define TI_CBLAS_CBLAS_DAXPY_IDX 35
216#define TI_CBLAS_CBLAS_DCOPY_IDX 36
217#define TI_CBLAS_CBLAS_DDOT_IDX 37
218#define TI_CBLAS_CBLAS_DGBMV_IDX 38
219#define TI_CBLAS_CBLAS_DGEMM_IDX 39
220#define TI_CBLAS_CBLAS_DGEMV_IDX 40
221#define TI_CBLAS_CBLAS_DGER_IDX 41
222#define TI_CBLAS_CBLAS_DNRM2_IDX 42
223#define TI_CBLAS_CBLAS_DROT_IDX 43
224#define TI_CBLAS_CBLAS_DROTG_IDX 44
225#define TI_CBLAS_CBLAS_DROTM_IDX 45
226#define TI_CBLAS_CBLAS_DROTMG_IDX 46
227#define TI_CBLAS_CBLAS_DSBMV_IDX 47
228#define TI_CBLAS_CBLAS_DSCAL_IDX 48
229#define TI_CBLAS_CBLAS_DSDOT_IDX 49
230#define TI_CBLAS_CBLAS_DSPMV_IDX 50
231#define TI_CBLAS_CBLAS_DSPR_IDX 51
232#define TI_CBLAS_CBLAS_DSPR2_IDX 52
233#define TI_CBLAS_CBLAS_DSWAP_IDX 53
234#define TI_CBLAS_CBLAS_DSYMM_IDX 54
235#define TI_CBLAS_CBLAS_DSYMV_IDX 55
236#define TI_CBLAS_CBLAS_DSYR_IDX 56
237#define TI_CBLAS_CBLAS_DSYR2_IDX 57
238#define TI_CBLAS_CBLAS_DSYR2K_IDX 58
239#define TI_CBLAS_CBLAS_DSYRK_IDX 59
240#define TI_CBLAS_CBLAS_DTBMV_IDX 60
241#define TI_CBLAS_CBLAS_DTBSV_IDX 61
242#define TI_CBLAS_CBLAS_DTPMV_IDX 62
243#define TI_CBLAS_CBLAS_DTPSV_IDX 63
244#define TI_CBLAS_CBLAS_DTRMM_IDX 64
245#define TI_CBLAS_CBLAS_DTRMV_IDX 65
246#define TI_CBLAS_CBLAS_DTRSM_IDX 66
247#define TI_CBLAS_CBLAS_DTRSV_IDX 67
248#define TI_CBLAS_CBLAS_DZASUM_IDX 68
249#define TI_CBLAS_CBLAS_DZNRM2_IDX 69
250#define TI_CBLAS_CBLAS_ICAMAX_IDX 70
251#define TI_CBLAS_CBLAS_IDAMAX_IDX 71
252#define TI_CBLAS_CBLAS_ISAMAX_IDX 72
253#define TI_CBLAS_CBLAS_IZAMAX_IDX 73
254#define TI_CBLAS_CBLAS_SASUM_IDX 74
255#define TI_CBLAS_CBLAS_SAXPY_IDX 75
256#define TI_CBLAS_CBLAS_SCASUM_IDX 76
257#define TI_CBLAS_CBLAS_SCNRM2_IDX 77
258#define TI_CBLAS_CBLAS_SCOPY_IDX 78
259#define TI_CBLAS_CBLAS_SDOT_IDX 79
260#define TI_CBLAS_CBLAS_SDSDOT_IDX 80
261#define TI_CBLAS_CBLAS_SGBMV_IDX 81
262#define TI_CBLAS_CBLAS_SGEMM_IDX 82
263#define TI_CBLAS_CBLAS_SGEMV_IDX 83
264#define TI_CBLAS_CBLAS_SGER_IDX 84
265#define TI_CBLAS_CBLAS_SNRM2_IDX 85
266#define TI_CBLAS_CBLAS_SROT_IDX 86
267#define TI_CBLAS_CBLAS_SROTG_IDX 87
268#define TI_CBLAS_CBLAS_SROTM_IDX 88
269#define TI_CBLAS_CBLAS_SROTMG_IDX 89
270#define TI_CBLAS_CBLAS_SSBMV_IDX 90
271#define TI_CBLAS_CBLAS_SSCAL_IDX 91
272#define TI_CBLAS_CBLAS_SSPMV_IDX 92
273#define TI_CBLAS_CBLAS_SSPR_IDX 93
274#define TI_CBLAS_CBLAS_SSPR2_IDX 94
275#define TI_CBLAS_CBLAS_SSWAP_IDX 95
276#define TI_CBLAS_CBLAS_SSYMM_IDX 96
277#define TI_CBLAS_CBLAS_SSYMV_IDX 97
278#define TI_CBLAS_CBLAS_SSYR_IDX 98
279#define TI_CBLAS_CBLAS_SSYR2_IDX 99
280#define TI_CBLAS_CBLAS_SSYR2K_IDX 100
281#define TI_CBLAS_CBLAS_SSYRK_IDX 101
282#define TI_CBLAS_CBLAS_STBMV_IDX 102
283#define TI_CBLAS_CBLAS_STBSV_IDX 103
284#define TI_CBLAS_CBLAS_STPMV_IDX 104
285#define TI_CBLAS_CBLAS_STPSV_IDX 105
286#define TI_CBLAS_CBLAS_STRMM_IDX 106
287#define TI_CBLAS_CBLAS_STRMV_IDX 107
288#define TI_CBLAS_CBLAS_STRSM_IDX 108
289#define TI_CBLAS_CBLAS_STRSV_IDX 109
290#define TI_CBLAS_CBLAS_XERBLA_IDX 110
291#define TI_CBLAS_CBLAS_ZAXPY_IDX 111
292#define TI_CBLAS_CBLAS_ZCOPY_IDX 112
293#define TI_CBLAS_CBLAS_ZDOTC_SUB_IDX 113
294#define TI_CBLAS_CBLAS_ZDOTU_SUB_IDX 114
295#define TI_CBLAS_CBLAS_ZDSCAL_IDX 115
296#define TI_CBLAS_CBLAS_ZGBMV_IDX 116
297#define TI_CBLAS_CBLAS_ZGEMM_IDX 117
298#define TI_CBLAS_CBLAS_ZGEMV_IDX 118
299#define TI_CBLAS_CBLAS_ZGERC_IDX 119
300#define TI_CBLAS_CBLAS_ZGERU_IDX 120
301#define TI_CBLAS_CBLAS_ZHBMV_IDX 121
302#define TI_CBLAS_CBLAS_ZHEMM_IDX 122
303#define TI_CBLAS_CBLAS_ZHEMV_IDX 123
304#define TI_CBLAS_CBLAS_ZHER_IDX 124
305#define TI_CBLAS_CBLAS_ZHER2_IDX 125
306#define TI_CBLAS_CBLAS_ZHER2K_IDX 126
307#define TI_CBLAS_CBLAS_ZHERK_IDX 127
308#define TI_CBLAS_CBLAS_ZHPMV_IDX 128
309#define TI_CBLAS_CBLAS_ZHPR_IDX 129
310#define TI_CBLAS_CBLAS_ZHPR2_IDX 130
311#define TI_CBLAS_CBLAS_ZROTG_IDX 131
312#define TI_CBLAS_CBLAS_ZSCAL_IDX 132
313#define TI_CBLAS_CBLAS_ZSWAP_IDX 133
314#define TI_CBLAS_CBLAS_ZSYMM_IDX 134
315#define TI_CBLAS_CBLAS_ZSYR2K_IDX 135
316#define TI_CBLAS_CBLAS_ZSYRK_IDX 136
317#define TI_CBLAS_CBLAS_ZTBMV_IDX 137
318#define TI_CBLAS_CBLAS_ZTBSV_IDX 138
319#define TI_CBLAS_CBLAS_ZTPMV_IDX 139
320#define TI_CBLAS_CBLAS_ZTPSV_IDX 140
321#define TI_CBLAS_CBLAS_ZTRMM_IDX 141
322#define TI_CBLAS_CBLAS_ZTRMV_IDX 142
323#define TI_CBLAS_CBLAS_ZTRSM_IDX 143
324#define TI_CBLAS_CBLAS_ZTRSV_IDX 144
325#define TI_CBLAS_NUM_KERNELS 145
326
327/* Level 3 kernels offload table */ 145/* Level 3 kernels offload table */
328/* Number of points in each dimension. ARM processing and DSP processing time 146/* Number of points in each dimension. ARM processing and DSP processing time
329 are measured for each point to determine offload or not. */ 147 are measured for each point to determine offload or not. */
@@ -336,8 +154,8 @@ extern int ti_cblas_offload;
336#define TRSM_OFFLOAD_TBL_SIZE (NUM_PNT_EACH_DIM*NUM_PNT_EACH_DIM) 154#define TRSM_OFFLOAD_TBL_SIZE (NUM_PNT_EACH_DIM*NUM_PNT_EACH_DIM)
337 155
338/* compile time defaults */ 156/* compile time defaults */
339#ifndef TI_CBLAS_OFFLOAD 157#ifndef TI_CBLAS_OFFLOAD_DEF
340#define TI_CBLAS_OFFLOAD "002" 158#define TI_CBLAS_OFFLOAD_DEF "002"
341#endif 159#endif
342 160
343/* macros used for BLAS/LAPACK buffer size calculations */ 161/* macros used for BLAS/LAPACK buffer size calculations */
@@ -396,9 +214,9 @@ extern int csymm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE
396extern int zsymm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, 214extern int zsymm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
397 int M, int N); 215 int M, int N);
398extern int chemm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, 216extern int chemm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
399 int M, int N); 217 int M, int N);
400extern int zhemm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, 218extern int zhemm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
401 int M, int N); 219 int M, int N);
402extern int ssyrk_offload_dsp(const enum CBLAS_ORDER Order, int N, int K); 220extern int ssyrk_offload_dsp(const enum CBLAS_ORDER Order, int N, int K);
403extern int dsyrk_offload_dsp(const enum CBLAS_ORDER Order, int N, int K); 221extern int dsyrk_offload_dsp(const enum CBLAS_ORDER Order, int N, int K);
404extern int csyrk_offload_dsp(const enum CBLAS_ORDER Order, int N, int K); 222extern int csyrk_offload_dsp(const enum CBLAS_ORDER Order, int N, int K);
@@ -412,21 +230,21 @@ extern int zsyr2k_offload_dsp(const enum CBLAS_ORDER Order, int N, int K);
412extern int cher2k_offload_dsp(const enum CBLAS_ORDER Order, int N, int K); 230extern int cher2k_offload_dsp(const enum CBLAS_ORDER Order, int N, int K);
413extern int zher2k_offload_dsp(const enum CBLAS_ORDER Order, int N, int K); 231extern int zher2k_offload_dsp(const enum CBLAS_ORDER Order, int N, int K);
414extern int strmm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, 232extern int strmm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
415 int M, int N); 233 int M, int N);
416extern int dtrmm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, 234extern int dtrmm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
417 int M, int N); 235 int M, int N);
418extern int ctrmm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, 236extern int ctrmm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
419 int M, int N); 237 int M, int N);
420extern int ztrmm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, 238extern int ztrmm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
421 int M, int N); 239 int M, int N);
422extern int strsm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, 240extern int strsm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
423 int M, int N); 241 int M, int N);
424extern int dtrsm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, 242extern int dtrsm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
425 int M, int N); 243 int M, int N);
426extern int ctrsm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, 244extern int ctrsm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
427 int M, int N); 245 int M, int N);
428extern int ztrsm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, 246extern int ztrsm_offload_dsp(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side,
429 int M, int N); 247 int M, int N);
430 248
431#endif 249#endif
432 250
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_caxpy.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_caxpy.c
index 233c69b..cfc47c7 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_caxpy.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_caxpy.c
@@ -66,7 +66,7 @@ void cblas_caxpy(const int N, const void *alpha, const void *X, const int incX,
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CAXPY_IDX, "ocl_cblas_caxpy"); 69 __K = ti_cblas_get_kernel("ocl_cblas_caxpy");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ccopy.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ccopy.c
index 2a5fa6b..88373f1 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ccopy.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ccopy.c
@@ -66,7 +66,7 @@ void cblas_ccopy(const int N, const void *X, const int incX, void *Y, const int
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CCOPY_IDX, "ocl_cblas_ccopy"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ccopy");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cdotc_sub.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cdotc_sub.c
index bb8fd34..5a24501 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cdotc_sub.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cdotc_sub.c
@@ -66,7 +66,7 @@ void cblas_cdotc_sub(const int N, const void *X, const int incX, const void *Y,
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CDOTC_SUB_IDX, "ocl_cblas_cdotc_sub"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cdotc_sub");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cdotu_sub.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cdotu_sub.c
index 2ba9005..95473b1 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cdotu_sub.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cdotu_sub.c
@@ -66,7 +66,7 @@ void cblas_cdotu_sub(const int N, const void *X, const int incX, const void *Y,
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CDOTU_SUB_IDX, "ocl_cblas_cdotu_sub"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cdotu_sub");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgbmv.c
index 4a04d07..cc9dd91 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgbmv.c
@@ -66,7 +66,7 @@ void cblas_cgbmv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CGBMV_IDX, "ocl_cblas_cgbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cgbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgemm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgemm.c
index 9880b6d..38bc67c 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgemm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgemm.c
@@ -66,7 +66,7 @@ void cblas_cgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CGEMM_IDX, "ocl_cblas_cgemm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cgemm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgemv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgemv.c
index c4d35c8..18e9c5c 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgemv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgemv.c
@@ -66,7 +66,7 @@ void cblas_cgemv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CGEMV_IDX, "ocl_cblas_cgemv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cgemv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgerc.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgerc.c
index 3c89112..5f4cfc5 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgerc.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgerc.c
@@ -66,7 +66,7 @@ void cblas_cgerc(const enum CBLAS_ORDER order, const int M, const int N, const v
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CGERC_IDX, "ocl_cblas_cgerc"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cgerc");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgeru.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgeru.c
index 3e951aa..1bcc580 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgeru.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cgeru.c
@@ -66,7 +66,7 @@ void cblas_cgeru(const enum CBLAS_ORDER order, const int M, const int N, const v
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CGERU_IDX, "ocl_cblas_cgeru"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cgeru");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chbmv.c
index cfdb1f1..05c77a8 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chbmv.c
@@ -66,7 +66,7 @@ void cblas_chbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CHBMV_IDX, "ocl_cblas_chbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_chbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chemm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chemm.c
index 0e8eb77..c02e2db 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chemm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chemm.c
@@ -66,7 +66,7 @@ void cblas_chemm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CHEMM_IDX, "ocl_cblas_chemm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_chemm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chemv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chemv.c
index 7421539..7e72a78 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chemv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chemv.c
@@ -66,7 +66,7 @@ void cblas_chemv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CHEMV_IDX, "ocl_cblas_chemv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_chemv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher.c
index fb566fd..73075de 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher.c
@@ -66,7 +66,7 @@ void cblas_cher(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CHER_IDX, "ocl_cblas_cher"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cher");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher2.c
index f65b307..3240ed2 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher2.c
@@ -66,7 +66,7 @@ void cblas_cher2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CHER2_IDX, "ocl_cblas_cher2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cher2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher2k.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher2k.c
index 51ed406..f119c3b 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher2k.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cher2k.c
@@ -66,7 +66,7 @@ void cblas_cher2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, cons
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CHER2K_IDX, "ocl_cblas_cher2k"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cher2k");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cherk.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cherk.c
index 5e45c12..5b3dab3 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cherk.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cherk.c
@@ -66,7 +66,7 @@ void cblas_cherk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CHERK_IDX, "ocl_cblas_cherk"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cherk");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpmv.c
index 03e14dd..bdbe0cf 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpmv.c
@@ -66,7 +66,7 @@ void cblas_chpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CHPMV_IDX, "ocl_cblas_chpmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_chpmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpr.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpr.c
index 315d80d..c68c478 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpr.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpr.c
@@ -66,7 +66,7 @@ void cblas_chpr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CHPR_IDX, "ocl_cblas_chpr"); 69 __K = ti_cblas_get_kernel("ocl_cblas_chpr");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpr2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpr2.c
index 7f0f765..ca0ce5c 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpr2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_chpr2.c
@@ -66,7 +66,7 @@ void cblas_chpr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CHPR2_IDX, "ocl_cblas_chpr2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_chpr2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_crotg.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_crotg.c
index 8eb77ee..492e279 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_crotg.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_crotg.c
@@ -66,7 +66,7 @@ void cblas_crotg( void *a, void *b, float *c, void *s)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CROTG_IDX, "ocl_cblas_crotg"); 69 __K = ti_cblas_get_kernel("ocl_cblas_crotg");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cscal.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cscal.c
index 7933cba..0d0d659 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cscal.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cscal.c
@@ -66,7 +66,7 @@ void cblas_cscal(const int N, const void *alpha, void *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CSCAL_IDX, "ocl_cblas_cscal"); 69 __K = ti_cblas_get_kernel("ocl_cblas_cscal");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csscal.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csscal.c
index 161b6d5..f18b209 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csscal.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csscal.c
@@ -66,7 +66,7 @@ void cblas_csscal(const int N, const float alpha, void *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CSSCAL_IDX, "ocl_cblas_csscal"); 69 __K = ti_cblas_get_kernel("ocl_cblas_csscal");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cswap.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cswap.c
index 1dac9fe..c29f25c 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cswap.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_cswap.c
@@ -78,7 +78,7 @@ void cblas_cswap(const int N, void *X, const int incX, void *Y, const int incY)
78#else 78#else
79 cl_kernel __K; 79 cl_kernel __K;
80#endif 80#endif
81 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CSWAP_IDX, "ocl_cblas_cswap"); 81 __K = ti_cblas_get_kernel("ocl_cblas_cswap");
82 82
83#ifdef __cplusplus 83#ifdef __cplusplus
84 try 84 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csymm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csymm.c
index 41558f8..5117b67 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csymm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csymm.c
@@ -66,7 +66,7 @@ void cblas_csymm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CSYMM_IDX, "ocl_cblas_csymm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_csymm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csyr2k.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csyr2k.c
index 3a3611f..0ca1f1d 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csyr2k.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csyr2k.c
@@ -66,7 +66,7 @@ void cblas_csyr2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, cons
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CSYR2K_IDX, "ocl_cblas_csyr2k"); 69 __K = ti_cblas_get_kernel("ocl_cblas_csyr2k");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csyrk.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csyrk.c
index 8a0a4a4..d57db3a 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csyrk.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_csyrk.c
@@ -66,7 +66,7 @@ void cblas_csyrk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CSYRK_IDX, "ocl_cblas_csyrk"); 69 __K = ti_cblas_get_kernel("ocl_cblas_csyrk");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctbmv.c
index 237b7fe..493897d 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctbmv.c
@@ -66,7 +66,7 @@ void cblas_ctbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CTBMV_IDX, "ocl_cblas_ctbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ctbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctbsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctbsv.c
index b03c316..d12a66b 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctbsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctbsv.c
@@ -66,7 +66,7 @@ void cblas_ctbsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CTBSV_IDX, "ocl_cblas_ctbsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ctbsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctpmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctpmv.c
index 816fed2..c5ef3a6 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctpmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctpmv.c
@@ -66,7 +66,7 @@ void cblas_ctpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CTPMV_IDX, "ocl_cblas_ctpmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ctpmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctpsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctpsv.c
index 44d25ed..c554877 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctpsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctpsv.c
@@ -66,7 +66,7 @@ void cblas_ctpsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CTPSV_IDX, "ocl_cblas_ctpsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ctpsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrmm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrmm.c
index 17713af..6740788 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrmm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrmm.c
@@ -66,7 +66,7 @@ void cblas_ctrmm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CTRMM_IDX, "ocl_cblas_ctrmm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ctrmm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrmv.c
index e2461a5..890bbd2 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrmv.c
@@ -66,7 +66,7 @@ void cblas_ctrmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CTRMV_IDX, "ocl_cblas_ctrmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ctrmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrsm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrsm.c
index 7279d08..1a104b8 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrsm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrsm.c
@@ -66,7 +66,7 @@ void cblas_ctrsm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CTRSM_IDX, "ocl_cblas_ctrsm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ctrsm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrsv.c
index 2ecf168..1969368 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ctrsv.c
@@ -66,7 +66,7 @@ void cblas_ctrsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CTRSV_IDX, "ocl_cblas_ctrsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ctrsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dasum.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dasum.c
index 3425c22..466478a 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dasum.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dasum.c
@@ -66,7 +66,7 @@ double cblas_dasum(const int N, const double *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DASUM_IDX, "ocl_cblas_dasum"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dasum");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_daxpy.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_daxpy.c
index 64a6824..62fea45 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_daxpy.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_daxpy.c
@@ -66,7 +66,7 @@ void cblas_daxpy(const int N, const double alpha, const double *X, const int inc
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DAXPY_IDX, "ocl_cblas_daxpy"); 69 __K = ti_cblas_get_kernel("ocl_cblas_daxpy");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dcopy.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dcopy.c
index c145e2d..52ab3c7 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dcopy.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dcopy.c
@@ -66,7 +66,7 @@ void cblas_dcopy(const int N, const double *X, const int incX, double *Y, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DCOPY_IDX, "ocl_cblas_dcopy"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dcopy");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ddot.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ddot.c
index aa1f769..1717502 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ddot.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ddot.c
@@ -66,7 +66,7 @@ double cblas_ddot(const int N, const double *X, const int incX, const double *Y,
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DDOT_IDX, "ocl_cblas_ddot"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ddot");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgbmv.c
index 1ce1c80..15f41c9 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgbmv.c
@@ -66,7 +66,7 @@ void cblas_dgbmv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DGBMV_IDX, "ocl_cblas_dgbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dgbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgemm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgemm.c
index 92ecb14..58f6abc 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgemm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgemm.c
@@ -66,7 +66,7 @@ void cblas_dgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DGEMM_IDX, "ocl_cblas_dgemm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dgemm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgemv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgemv.c
index 2c3a5e2..ba2fefb 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgemv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dgemv.c
@@ -66,7 +66,7 @@ void cblas_dgemv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DGEMV_IDX, "ocl_cblas_dgemv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dgemv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dger.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dger.c
index 1c911e7..c30dede 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dger.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dger.c
@@ -66,7 +66,7 @@ void cblas_dger(const enum CBLAS_ORDER order, const int M, const int N, const do
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DGER_IDX, "ocl_cblas_dger"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dger");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dnrm2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dnrm2.c
index a3c14c6..3b92435 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dnrm2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dnrm2.c
@@ -66,7 +66,7 @@ double cblas_dnrm2(const int N, const double *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DNRM2_IDX, "ocl_cblas_dnrm2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dnrm2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drot.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drot.c
index dd86c24..dfc2b82 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drot.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drot.c
@@ -66,7 +66,7 @@ void cblas_drot(const int N, double *X, const int incX, double *Y, const int inc
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DROT_IDX, "ocl_cblas_drot"); 69 __K = ti_cblas_get_kernel("ocl_cblas_drot");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotg.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotg.c
index 5b3732c..a09995b 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotg.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotg.c
@@ -66,7 +66,7 @@ void cblas_drotg(double *a, double *b, double *c, double *s)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DROTG_IDX, "ocl_cblas_drotg"); 69 __K = ti_cblas_get_kernel("ocl_cblas_drotg");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotm.c
index 0ba101a..30fd5d0 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotm.c
@@ -66,7 +66,7 @@ void cblas_drotm(const int N, double *X, const int incX, double *Y, const int in
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DROTM_IDX, "ocl_cblas_drotm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_drotm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotmg.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotmg.c
index efbcc94..921ece4 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotmg.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_drotmg.c
@@ -66,7 +66,7 @@ void cblas_drotmg(double *d1, double *d2, double *b1, const double b2, double *P
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DROTMG_IDX, "ocl_cblas_drotmg"); 69 __K = ti_cblas_get_kernel("ocl_cblas_drotmg");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsbmv.c
index b826766..7532d48 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsbmv.c
@@ -66,7 +66,7 @@ void cblas_dsbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSBMV_IDX, "ocl_cblas_dsbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dsbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dscal.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dscal.c
index 93d81f0..dd75f67 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dscal.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dscal.c
@@ -66,7 +66,7 @@ void cblas_dscal(const int N, const double alpha, double *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSCAL_IDX, "ocl_cblas_dscal"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dscal");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsdot.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsdot.c
index 8f02791..602414c 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsdot.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsdot.c
@@ -66,7 +66,7 @@ double cblas_dsdot(const int N, const float *X, const int incX, const float *Y,
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSDOT_IDX, "ocl_cblas_dsdot"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dsdot");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspmv.c
index 13b403b..0c24fee 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspmv.c
@@ -66,7 +66,7 @@ void cblas_dspmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSPMV_IDX, "ocl_cblas_dspmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dspmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspr.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspr.c
index c347969..2f75cf9 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspr.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspr.c
@@ -66,7 +66,7 @@ void cblas_dspr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSPR_IDX, "ocl_cblas_dspr"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dspr");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspr2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspr2.c
index 812bb3b..38620ae 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspr2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dspr2.c
@@ -66,7 +66,7 @@ void cblas_dspr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSPR2_IDX, "ocl_cblas_dspr2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dspr2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dswap.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dswap.c
index d17893d..9cd70b9 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dswap.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dswap.c
@@ -78,7 +78,7 @@ void cblas_dswap(const int N, double *X, const int incX, double *Y, const int in
78#else 78#else
79 cl_kernel __K; 79 cl_kernel __K;
80#endif 80#endif
81 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSWAP_IDX, "ocl_cblas_dswap"); 81 __K = ti_cblas_get_kernel("ocl_cblas_dswap");
82 82
83#ifdef __cplusplus 83#ifdef __cplusplus
84 try 84 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsymm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsymm.c
index d5c28bc..4136f9e 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsymm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsymm.c
@@ -66,7 +66,7 @@ void cblas_dsymm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSYMM_IDX, "ocl_cblas_dsymm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dsymm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsymv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsymv.c
index 80eb1a6..5a5d1c5 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsymv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsymv.c
@@ -66,7 +66,7 @@ void cblas_dsymv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSYMV_IDX, "ocl_cblas_dsymv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dsymv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr.c
index 6b05e31..6df6638 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr.c
@@ -66,7 +66,7 @@ void cblas_dsyr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSYR_IDX, "ocl_cblas_dsyr"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dsyr");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr2.c
index 86a5a48..384c68f 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr2.c
@@ -66,7 +66,7 @@ void cblas_dsyr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSYR2_IDX, "ocl_cblas_dsyr2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dsyr2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr2k.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr2k.c
index 4caffb7..3546475 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr2k.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyr2k.c
@@ -66,7 +66,7 @@ void cblas_dsyr2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, cons
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSYR2K_IDX, "ocl_cblas_dsyr2k"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dsyr2k");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyrk.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyrk.c
index 341ff82..923a66a 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyrk.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dsyrk.c
@@ -66,7 +66,7 @@ void cblas_dsyrk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DSYRK_IDX, "ocl_cblas_dsyrk"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dsyrk");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtbmv.c
index d95c34f..102b842 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtbmv.c
@@ -66,7 +66,7 @@ void cblas_dtbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DTBMV_IDX, "ocl_cblas_dtbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dtbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtbsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtbsv.c
index c375c4e..dde82ef 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtbsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtbsv.c
@@ -66,7 +66,7 @@ void cblas_dtbsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DTBSV_IDX, "ocl_cblas_dtbsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dtbsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtpmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtpmv.c
index 105c178..0a5da49 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtpmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtpmv.c
@@ -66,7 +66,7 @@ void cblas_dtpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DTPMV_IDX, "ocl_cblas_dtpmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dtpmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtpsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtpsv.c
index 32311ab..0f2abb2 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtpsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtpsv.c
@@ -66,7 +66,7 @@ void cblas_dtpsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DTPSV_IDX, "ocl_cblas_dtpsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dtpsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrmm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrmm.c
index cac7e27..28537a3 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrmm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrmm.c
@@ -66,7 +66,7 @@ void cblas_dtrmm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DTRMM_IDX, "ocl_cblas_dtrmm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dtrmm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrmv.c
index d281310..14d2000 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrmv.c
@@ -66,7 +66,7 @@ void cblas_dtrmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DTRMV_IDX, "ocl_cblas_dtrmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dtrmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrsm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrsm.c
index a3bbc06..e53f21f 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrsm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrsm.c
@@ -66,7 +66,7 @@ void cblas_dtrsm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DTRSM_IDX, "ocl_cblas_dtrsm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dtrsm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrsv.c
index 4001c3f..4d77335 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dtrsv.c
@@ -66,7 +66,7 @@ void cblas_dtrsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DTRSV_IDX, "ocl_cblas_dtrsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dtrsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dzasum.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dzasum.c
index 5b79f68..a1bb3d9 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dzasum.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dzasum.c
@@ -66,7 +66,7 @@ double cblas_dzasum(const int N, const void *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DZASUM_IDX, "ocl_cblas_dzasum"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dzasum");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dznrm2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dznrm2.c
index 81d7e53..265d6f9 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dznrm2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_dznrm2.c
@@ -66,7 +66,7 @@ double cblas_dznrm2(const int N, const void *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_DZNRM2_IDX, "ocl_cblas_dznrm2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_dznrm2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_icamax.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_icamax.c
index 7cbcfc3..860f4d7 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_icamax.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_icamax.c
@@ -66,7 +66,7 @@ CBLAS_INDEX cblas_icamax(const int N, const void *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ICAMAX_IDX, "ocl_cblas_icamax"); 69 __K = ti_cblas_get_kernel("ocl_cblas_icamax");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_idamax.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_idamax.c
index d393ea2..9aab317 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_idamax.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_idamax.c
@@ -66,7 +66,7 @@ CBLAS_INDEX cblas_idamax(const int N, const double *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_IDAMAX_IDX, "ocl_cblas_idamax"); 69 __K = ti_cblas_get_kernel("ocl_cblas_idamax");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_isamax.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_isamax.c
index 35d6aa6..b15a9e6 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_isamax.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_isamax.c
@@ -66,7 +66,7 @@ CBLAS_INDEX cblas_isamax(const int N, const float *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ISAMAX_IDX, "ocl_cblas_isamax"); 69 __K = ti_cblas_get_kernel("ocl_cblas_isamax");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_izamax.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_izamax.c
index f235319..7fc6d66 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_izamax.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_izamax.c
@@ -66,7 +66,7 @@ CBLAS_INDEX cblas_izamax(const int N, const void *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_IZAMAX_IDX, "ocl_cblas_izamax"); 69 __K = ti_cblas_get_kernel("ocl_cblas_izamax");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sasum.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sasum.c
index 60b0b88..dd46358 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sasum.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sasum.c
@@ -66,7 +66,7 @@ float cblas_sasum(const int N, const float *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SASUM_IDX, "ocl_cblas_sasum"); 69 __K = ti_cblas_get_kernel("ocl_cblas_sasum");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_saxpy.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_saxpy.c
index 2caee52..cb61305 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_saxpy.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_saxpy.c
@@ -66,7 +66,7 @@ void cblas_saxpy(const int N, const float alpha, const float *X, const int incX,
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SAXPY_IDX, "ocl_cblas_saxpy"); 69 __K = ti_cblas_get_kernel("ocl_cblas_saxpy");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scasum.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scasum.c
index 67c18ea..3845b05 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scasum.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scasum.c
@@ -66,7 +66,7 @@ float cblas_scasum(const int N, const void *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SCASUM_IDX, "ocl_cblas_scasum"); 69 __K = ti_cblas_get_kernel("ocl_cblas_scasum");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scnrm2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scnrm2.c
index a9e2713..733a4e2 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scnrm2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scnrm2.c
@@ -66,7 +66,7 @@ float cblas_scnrm2(const int N, const void *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SCNRM2_IDX, "ocl_cblas_scnrm2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_scnrm2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scopy.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scopy.c
index 2c3a8f3..c3d12fb 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scopy.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_scopy.c
@@ -66,7 +66,7 @@ void cblas_scopy(const int N, const float *X, const int incX, float *Y, const in
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SCOPY_IDX, "ocl_cblas_scopy"); 69 __K = ti_cblas_get_kernel("ocl_cblas_scopy");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sdot.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sdot.c
index ab7d8d0..636464d 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sdot.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sdot.c
@@ -66,7 +66,7 @@ float cblas_sdot(const int N, const float *X, const int incX, const float *Y, co
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SDOT_IDX, "ocl_cblas_sdot"); 69 __K = ti_cblas_get_kernel("ocl_cblas_sdot");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sdsdot.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sdsdot.c
index fd5adb9..ed4822a 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sdsdot.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sdsdot.c
@@ -66,7 +66,7 @@ float cblas_sdsdot(const int N, const float alpha, const float *X, const int inc
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SDSDOT_IDX, "ocl_cblas_sdsdot"); 69 __K = ti_cblas_get_kernel("ocl_cblas_sdsdot");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgbmv.c
index 32d800a..c7f4895 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgbmv.c
@@ -66,7 +66,7 @@ void cblas_sgbmv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SGBMV_IDX, "ocl_cblas_sgbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_sgbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgemm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgemm.c
index 9599e84..ecd1885 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgemm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgemm.c
@@ -66,7 +66,7 @@ void cblas_sgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SGEMM_IDX, "ocl_cblas_sgemm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_sgemm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgemv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgemv.c
index 48a3de6..ad3adaf 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgemv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sgemv.c
@@ -66,7 +66,7 @@ void cblas_sgemv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SGEMV_IDX, "ocl_cblas_sgemv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_sgemv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sger.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sger.c
index 6780fa9..b6b3680 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sger.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sger.c
@@ -66,7 +66,7 @@ void cblas_sger(const enum CBLAS_ORDER order, const int M, const int N, const fl
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SGER_IDX, "ocl_cblas_sger"); 69 __K = ti_cblas_get_kernel("ocl_cblas_sger");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_snrm2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_snrm2.c
index ba378a3..92c0a3a 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_snrm2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_snrm2.c
@@ -66,7 +66,7 @@ float cblas_snrm2(const int N, const float *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SNRM2_IDX, "ocl_cblas_snrm2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_snrm2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srot.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srot.c
index a7c6bbc..0a02021 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srot.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srot.c
@@ -66,7 +66,7 @@ void cblas_srot(const int N, float *X, const int incX, float *Y, const int incY,
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SROT_IDX, "ocl_cblas_srot"); 69 __K = ti_cblas_get_kernel("ocl_cblas_srot");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotg.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotg.c
index f399acc..38a5d5a 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotg.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotg.c
@@ -66,7 +66,7 @@ void cblas_srotg(float *a, float *b, float *c, float *s)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SROTG_IDX, "ocl_cblas_srotg"); 69 __K = ti_cblas_get_kernel("ocl_cblas_srotg");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotm.c
index 845a954..c823cd2 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotm.c
@@ -66,7 +66,7 @@ void cblas_srotm(const int N, float *X, const int incX, float *Y, const int incY
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SROTM_IDX, "ocl_cblas_srotm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_srotm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotmg.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotmg.c
index 8a03f42..68f02d6 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotmg.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_srotmg.c
@@ -66,7 +66,7 @@ void cblas_srotmg(float *d1, float *d2, float *b1, const float b2, float *P)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SROTMG_IDX, "ocl_cblas_srotmg"); 69 __K = ti_cblas_get_kernel("ocl_cblas_srotmg");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssbmv.c
index 24f9925..6ca7edd 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssbmv.c
@@ -66,7 +66,7 @@ void cblas_ssbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSBMV_IDX, "ocl_cblas_ssbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ssbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sscal.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sscal.c
index df05602..7a84815 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sscal.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sscal.c
@@ -66,7 +66,7 @@ void cblas_sscal(const int N, const float alpha, float *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSCAL_IDX, "ocl_cblas_sscal"); 69 __K = ti_cblas_get_kernel("ocl_cblas_sscal");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspmv.c
index 562ccec..41c8ef5 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspmv.c
@@ -66,7 +66,7 @@ void cblas_sspmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSPMV_IDX, "ocl_cblas_sspmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_sspmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspr.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspr.c
index b2e9342..bae0371 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspr.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspr.c
@@ -66,7 +66,7 @@ void cblas_sspr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSPR_IDX, "ocl_cblas_sspr"); 69 __K = ti_cblas_get_kernel("ocl_cblas_sspr");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspr2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspr2.c
index 7b82e54..2156d5f 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspr2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sspr2.c
@@ -66,7 +66,7 @@ void cblas_sspr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSPR2_IDX, "ocl_cblas_sspr2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_sspr2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sswap.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sswap.c
index d7590dd..19e5d38 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sswap.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_sswap.c
@@ -78,7 +78,7 @@ void cblas_sswap(const int N, float *X, const int incX, float *Y, const int incY
78#else 78#else
79 cl_kernel __K; 79 cl_kernel __K;
80#endif 80#endif
81 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSWAP_IDX, "ocl_cblas_sswap"); 81 __K = ti_cblas_get_kernel("ocl_cblas_sswap");
82 82
83#ifdef __cplusplus 83#ifdef __cplusplus
84 try 84 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssymm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssymm.c
index bc86c8e..d62b2ec 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssymm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssymm.c
@@ -66,7 +66,7 @@ void cblas_ssymm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSYMM_IDX, "ocl_cblas_ssymm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ssymm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssymv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssymv.c
index bfe09ac..2a8d6cf 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssymv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssymv.c
@@ -66,7 +66,7 @@ void cblas_ssymv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSYMV_IDX, "ocl_cblas_ssymv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ssymv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr.c
index e6c30c8..ac1b3ca 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr.c
@@ -66,7 +66,7 @@ void cblas_ssyr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSYR_IDX, "ocl_cblas_ssyr"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ssyr");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr2.c
index fa56ed3..895d1a5 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr2.c
@@ -66,7 +66,7 @@ void cblas_ssyr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSYR2_IDX, "ocl_cblas_ssyr2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ssyr2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr2k.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr2k.c
index 40d8503..66ff101 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr2k.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyr2k.c
@@ -66,7 +66,7 @@ void cblas_ssyr2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, cons
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSYR2K_IDX, "ocl_cblas_ssyr2k"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ssyr2k");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyrk.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyrk.c
index f9c0f31..c407e97 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyrk.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ssyrk.c
@@ -66,7 +66,7 @@ void cblas_ssyrk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_SSYRK_IDX, "ocl_cblas_ssyrk"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ssyrk");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stbmv.c
index 607394c..50fd50d 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stbmv.c
@@ -66,7 +66,7 @@ void cblas_stbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_STBMV_IDX, "ocl_cblas_stbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_stbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stbsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stbsv.c
index 96e6cab..c6d92a9 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stbsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stbsv.c
@@ -66,7 +66,7 @@ void cblas_stbsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_STBSV_IDX, "ocl_cblas_stbsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_stbsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stpmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stpmv.c
index b45b877..950497c 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stpmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stpmv.c
@@ -66,7 +66,7 @@ void cblas_stpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_STPMV_IDX, "ocl_cblas_stpmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_stpmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stpsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stpsv.c
index 0681ed8..0b7aa2d 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stpsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_stpsv.c
@@ -66,7 +66,7 @@ void cblas_stpsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_STPSV_IDX, "ocl_cblas_stpsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_stpsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strmm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strmm.c
index 3839c8e..e818b22 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strmm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strmm.c
@@ -66,7 +66,7 @@ void cblas_strmm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_STRMM_IDX, "ocl_cblas_strmm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_strmm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strmv.c
index 40ddbc3..e2b1c0d 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strmv.c
@@ -66,7 +66,7 @@ void cblas_strmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_STRMV_IDX, "ocl_cblas_strmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_strmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strsm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strsm.c
index 18e329e..a44e53d 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strsm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strsm.c
@@ -66,7 +66,7 @@ void cblas_strsm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_STRSM_IDX, "ocl_cblas_strsm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_strsm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strsv.c
index 26b9a3c..42689ee 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_strsv.c
@@ -66,7 +66,7 @@ void cblas_strsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_STRSV_IDX, "ocl_cblas_strsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_strsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_xerbla.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_xerbla.c
index 23efb90..b24f239 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_xerbla.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_xerbla.c
@@ -66,7 +66,7 @@ void cblas_xerbla(int p, const char *rout, const char *form, ...)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_XERBLA_IDX, "ocl_cblas_xerbla"); 69 __K = ti_cblas_get_kernel("ocl_cblas_xerbla");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zaxpy.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zaxpy.c
index fdbd907..f17a820 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zaxpy.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zaxpy.c
@@ -66,7 +66,7 @@ void cblas_zaxpy(const int N, const void *alpha, const void *X, const int incX,
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZAXPY_IDX, "ocl_cblas_zaxpy"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zaxpy");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zcopy.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zcopy.c
index da878b5..a070a59 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zcopy.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zcopy.c
@@ -66,7 +66,7 @@ void cblas_zcopy(const int N, const void *X, const int incX, void *Y, const int
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZCOPY_IDX, "ocl_cblas_zcopy"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zcopy");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdotc_sub.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdotc_sub.c
index 4a97d0b..aa1459c 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdotc_sub.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdotc_sub.c
@@ -66,7 +66,7 @@ void cblas_zdotc_sub(const int N, const void *X, const int incX, const void *Y,
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZDOTC_SUB_IDX, "ocl_cblas_zdotc_sub"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zdotc_sub");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdotu_sub.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdotu_sub.c
index 7d7f3e1..2f22cb1 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdotu_sub.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdotu_sub.c
@@ -66,7 +66,7 @@ void cblas_zdotu_sub(const int N, const void *X, const int incX, const void *Y,
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZDOTU_SUB_IDX, "ocl_cblas_zdotu_sub"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zdotu_sub");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdscal.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdscal.c
index 7294884..db77056 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdscal.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zdscal.c
@@ -66,7 +66,7 @@ void cblas_zdscal(const int N, const double alpha, void *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZDSCAL_IDX, "ocl_cblas_zdscal"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zdscal");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgbmv.c
index 3eb8471..09ebd59 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgbmv.c
@@ -66,7 +66,7 @@ void cblas_zgbmv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZGBMV_IDX, "ocl_cblas_zgbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zgbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgemm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgemm.c
index ac457bd..d4b3fcc 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgemm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgemm.c
@@ -66,7 +66,7 @@ void cblas_zgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZGEMM_IDX, "ocl_cblas_zgemm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zgemm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgemv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgemv.c
index b4767f5..02591ee 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgemv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgemv.c
@@ -66,7 +66,7 @@ void cblas_zgemv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZGEMV_IDX, "ocl_cblas_zgemv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zgemv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgerc.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgerc.c
index 58eb984..8153ca5 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgerc.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgerc.c
@@ -66,7 +66,7 @@ void cblas_zgerc(const enum CBLAS_ORDER order, const int M, const int N, const v
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZGERC_IDX, "ocl_cblas_zgerc"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zgerc");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgeru.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgeru.c
index 23d4c07..7e28de2 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgeru.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zgeru.c
@@ -66,7 +66,7 @@ void cblas_zgeru(const enum CBLAS_ORDER order, const int M, const int N, const v
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZGERU_IDX, "ocl_cblas_zgeru"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zgeru");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhbmv.c
index 67779e4..31a34de 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhbmv.c
@@ -66,7 +66,7 @@ void cblas_zhbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZHBMV_IDX, "ocl_cblas_zhbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zhbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhemm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhemm.c
index 7e94b80..2492139 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhemm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhemm.c
@@ -66,7 +66,7 @@ void cblas_zhemm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZHEMM_IDX, "ocl_cblas_zhemm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zhemm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhemv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhemv.c
index c6a4cbe..a63a2f9 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhemv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhemv.c
@@ -66,7 +66,7 @@ void cblas_zhemv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZHEMV_IDX, "ocl_cblas_zhemv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zhemv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher.c
index 3fdd79e..79f2599 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher.c
@@ -66,7 +66,7 @@ void cblas_zher(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZHER_IDX, "ocl_cblas_zher"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zher");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher2.c
index 0cdf1ab..aefd5d6 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher2.c
@@ -66,7 +66,7 @@ void cblas_zher2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZHER2_IDX, "ocl_cblas_zher2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zher2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher2k.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher2k.c
index e15a8ea..55aca4e 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher2k.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zher2k.c
@@ -66,7 +66,7 @@ void cblas_zher2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, cons
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZHER2K_IDX, "ocl_cblas_zher2k"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zher2k");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zherk.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zherk.c
index 5eb89b4..f3f8664 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zherk.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zherk.c
@@ -66,7 +66,7 @@ void cblas_zherk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZHERK_IDX, "ocl_cblas_zherk"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zherk");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpmv.c
index bc9cdf9..d28b866 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpmv.c
@@ -66,7 +66,7 @@ void cblas_zhpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZHPMV_IDX, "ocl_cblas_zhpmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zhpmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpr.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpr.c
index 1b25b51..d02acb3 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpr.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpr.c
@@ -66,7 +66,7 @@ void cblas_zhpr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZHPR_IDX, "ocl_cblas_zhpr"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zhpr");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpr2.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpr2.c
index a1aeaae..95e2e76 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpr2.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zhpr2.c
@@ -66,7 +66,7 @@ void cblas_zhpr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZHPR2_IDX, "ocl_cblas_zhpr2"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zhpr2");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zrotg.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zrotg.c
index f1e437c..29e2707 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zrotg.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zrotg.c
@@ -66,7 +66,7 @@ void cblas_zrotg( void *a, void *b, double *c, void *s)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZROTG_IDX, "ocl_cblas_zrotg"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zrotg");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zscal.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zscal.c
index 0169b07..b9912f7 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zscal.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zscal.c
@@ -66,7 +66,7 @@ void cblas_zscal(const int N, const void *alpha, void *X, const int incX)
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZSCAL_IDX, "ocl_cblas_zscal"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zscal");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zswap.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zswap.c
index 70a29e9..f96688e 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zswap.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zswap.c
@@ -78,7 +78,7 @@ void cblas_zswap(const int N, void *X, const int incX, void *Y, const int incY)
78#else 78#else
79 cl_kernel __K; 79 cl_kernel __K;
80#endif 80#endif
81 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZSWAP_IDX, "ocl_cblas_zswap"); 81 __K = ti_cblas_get_kernel("ocl_cblas_zswap");
82 82
83#ifdef __cplusplus 83#ifdef __cplusplus
84 try 84 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsymm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsymm.c
index 9175e0e..4239501 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsymm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsymm.c
@@ -66,7 +66,7 @@ void cblas_zsymm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZSYMM_IDX, "ocl_cblas_zsymm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zsymm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsyr2k.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsyr2k.c
index 53b7044..1e54fdf 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsyr2k.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsyr2k.c
@@ -66,7 +66,7 @@ void cblas_zsyr2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, cons
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZSYR2K_IDX, "ocl_cblas_zsyr2k"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zsyr2k");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsyrk.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsyrk.c
index f705eb6..e75b9bd 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsyrk.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_zsyrk.c
@@ -66,7 +66,7 @@ void cblas_zsyrk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZSYRK_IDX, "ocl_cblas_zsyrk"); 69 __K = ti_cblas_get_kernel("ocl_cblas_zsyrk");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztbmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztbmv.c
index c026942..063f939 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztbmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztbmv.c
@@ -66,7 +66,7 @@ void cblas_ztbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZTBMV_IDX, "ocl_cblas_ztbmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ztbmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztbsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztbsv.c
index 754eca7..f9644c4 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztbsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztbsv.c
@@ -66,7 +66,7 @@ void cblas_ztbsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZTBSV_IDX, "ocl_cblas_ztbsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ztbsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztpmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztpmv.c
index 6fd2dd0..5361390 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztpmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztpmv.c
@@ -66,7 +66,7 @@ void cblas_ztpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZTPMV_IDX, "ocl_cblas_ztpmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ztpmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztpsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztpsv.c
index dcf6100..c68987d 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztpsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztpsv.c
@@ -66,7 +66,7 @@ void cblas_ztpsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZTPSV_IDX, "ocl_cblas_ztpsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ztpsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrmm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrmm.c
index c010d89..51a4a53 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrmm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrmm.c
@@ -66,7 +66,7 @@ void cblas_ztrmm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZTRMM_IDX, "ocl_cblas_ztrmm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ztrmm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrmv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrmv.c
index 1cbe9e0..244a5f9 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrmv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrmv.c
@@ -66,7 +66,7 @@ void cblas_ztrmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZTRMV_IDX, "ocl_cblas_ztrmv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ztrmv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrsm.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrsm.c
index 4cca728..d3583e8 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrsm.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrsm.c
@@ -66,7 +66,7 @@ void cblas_ztrsm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZTRSM_IDX, "ocl_cblas_ztrsm"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ztrsm");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrsv.c b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrsv.c
index 044c64e..f7b533c 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrsv.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_cblas_ztrsv.c
@@ -66,7 +66,7 @@ void cblas_ztrsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const
66#else 66#else
67 cl_kernel __K; 67 cl_kernel __K;
68#endif 68#endif
69 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_ZTRSV_IDX, "ocl_cblas_ztrsv"); 69 __K = ti_cblas_get_kernel("ocl_cblas_ztrsv");
70 70
71#ifdef __cplusplus 71#ifdef __cplusplus
72 try 72 try
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_initfini.c b/src/ti/linalg/blasblisacc/src/ti_cblas_initfini.c
index 65963d3..4ac5ddf 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_initfini.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_initfini.c
@@ -24,8 +24,7 @@
24 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 24 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
25 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 25 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
26 * THE POSSIBILITY OF SUCH DAMAGE. 26 * THE POSSIBILITY OF SUCH DAMAGE.
27 *****************************************************************************/ 27 *****************************************************************************/
28
29#include "ti_cblas_acc.h" 28#include "ti_cblas_acc.h"
30#include "../../ticblas/ticblas.h" 29#include "../../ticblas/ticblas.h"
31#include <pthread.h> 30#include <pthread.h>
@@ -34,21 +33,28 @@
34#include "ti_cblas_kernel.dsp_h" 33#include "ti_cblas_kernel.dsp_h"
35#endif 34#endif
36 35
36/*==============================================================================
37 * This file contains functions of the ARM wrapper of ARM+DSP CBLAS library.
38 * It has the initialization and finalization routines.
39 *
40 * The standard CBLAS API for each BLAS function can be found in file
41 * ti_cblas_cblas_<func_name>.c, such as ti_cblas_cblas_dgemm.c for DGEMM.
42 *============================================================================*/
43
37#define TI_CBLAS_INITFINI_SUCCESS 0 44#define TI_CBLAS_INITFINI_SUCCESS 0
38#define TI_CBLAS_INITFINI_OCL_ERR 1 45#define TI_CBLAS_INITFINI_OCL_ERR 1
39#define TI_CBLAS_INITFINI_BLI_ERR 2 46#define TI_CBLAS_INITFINI_BLI_ERR 2
40 47
41/* Global variables */ 48/* Global variables */
42Context* ti_cblas_ocl_context = NULL; 49Context* ti_cblas_ocl_context = NULL;
43std::vector<Device>* ti_cblas_ocl_devices = NULL; 50std::vector<Device>* ti_cblas_ocl_devices = NULL;
44CommandQueue* ti_cblas_ocl_Q = NULL; 51CommandQueue* ti_cblas_ocl_Q = NULL;
45Program::Binaries* ti_cblas_ocl_binary = NULL; 52Program::Binaries* ti_cblas_ocl_binary = NULL;
46Program* ti_cblas_ocl_program = NULL; 53Program* ti_cblas_ocl_program = NULL;
47 54
48int ti_cblas_init_done = 0; /* flag to check if init is complete */ 55int ti_cblas_init_done = 0; /* flag to check if init is complete */
49int ti_cblas_disable_debug = 0; /* runtime toggle to disable debug */ 56int ti_cblas_disable_debug = 0; /* runtime toggle to disable debug */
50int ti_cblas_offload = TI_CBLAS_OFFLOAD_SIZE; 57int ti_cblas_offload = TI_CBLAS_OFFLOAD_SIZE;
51int ti_cblas_kernel_valid[TI_CBLAS_NUM_KERNELS];
52int TI_CBLAS_L1_OFFLOAD = TI_CBLAS_OFFLOAD_NONE; 58int TI_CBLAS_L1_OFFLOAD = TI_CBLAS_OFFLOAD_NONE;
53int TI_CBLAS_L2_OFFLOAD = TI_CBLAS_OFFLOAD_NONE; 59int TI_CBLAS_L2_OFFLOAD = TI_CBLAS_OFFLOAD_NONE;
54int TI_CBLAS_L3_OFFLOAD = TI_CBLAS_OFFLOAD_NONE; 60int TI_CBLAS_L3_OFFLOAD = TI_CBLAS_OFFLOAD_NONE;
@@ -56,172 +62,75 @@ int TI_CBLAS_L3_OFFLOAD = TI_CBLAS_OFFLOAD_NONE;
56pthread_cond_t CV; 62pthread_cond_t CV;
57pthread_mutex_t MUTEX; 63pthread_mutex_t MUTEX;
58 64
65/*============================================================================
66 * Function purpose: report error encoutered in ARM wrapper code.
67 *============================================================================*/
59void ti_cblas_error(const char* msg, int code) 68void ti_cblas_error(const char* msg, int code)
60{ 69{
61 fprintf(stderr, "ERROR: (%s,%d)\n", msg, code); 70 fprintf(stderr, "TI CBLAS wrapper ERROR: (%s,%d)\n", msg, code);
62} 71}
63 72
64extern "C" 73/*============================================================================
74 * Function purpose: initialize BLIS on both ARM and DSP
75 *============================================================================*/
65int ti_blis_init(void) 76int ti_blis_init(void)
66{ 77{
67 int r_val = TI_CBLAS_INITFINI_SUCCESS; 78 int r_val = TI_CBLAS_INITFINI_SUCCESS;
68 79
69 TI_CBLAS_DEBUG_PRINT("Initializing BLIS on ARM...\n");
70 /* Initialize BLIS on ARM */ 80 /* Initialize BLIS on ARM */
71 bli_init(); 81 TI_CBLAS_DEBUG_PRINT("Initializing BLIS on ARM...\n");
72 TI_CBLAS_DEBUG_PRINT("BLIS initialized on ARM.\n"); 82 bli_init();
73 83 TI_CBLAS_DEBUG_PRINT("BLIS initialized on ARM.\n");
74 /* Initialize BLIS on DSP */
75 TI_CBLAS_DEBUG_PRINT("Initializing BLIS on DSP...\n");
76 Event e;
77 Kernel* __K;
78
79 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CGEMM_IDX, "ocl_bli_init");
80 try
81 {
82 TI_CBLAS_DEBUG_PRINT("Initializing BLIS on DSP...\n");
83
84 int err_code;
85 Buffer buf_err(*ti_cblas_ocl_context, CL_MEM_READ_WRITE|CL_MEM_USE_HOST_PTR, sizeof(int), &err_code);
86 __K->setArg(0, buf_err);
87
88 ti_cblas_ocl_Q->enqueueTask(*__K, 0, &e);
89 e.wait();
90
91 if(err_code != TICBLAS_SUCCESS) {
92 TI_CBLAS_DEBUG_PRINT("Error in offloaded ocl_bli_init with error code %d!\n", err_code);
93 r_val = TI_CBLAS_INITFINI_BLI_ERR;
94 }
95
96 ti_cblas_delete_kernel(__K);
97 TI_CBLAS_DEBUG_PRINT("BLIS DSP initialization finished.\n");
98 }
99
100 catch (Error err)
101 {
102 ti_cblas_delete_kernel(__K);
103 ti_cblas_error(err.what(),err.err());
104 r_val = TI_CBLAS_INITFINI_OCL_ERR;
105 }
106
107 return r_val;
108}
109
110extern "C"
111int ti_blis_finalize(void)
112{
113 int r_val = TI_CBLAS_INITFINI_SUCCESS;
114
115 TI_CBLAS_DEBUG_PRINT("Finalizing BLIS on ARM...\n");
116 /* Finalize BLIS on ARM */
117 bli_finalize();
118 TI_CBLAS_DEBUG_PRINT("BLIS finalized on ARM.\n");
119 84
120 Event e; 85 /* Initialize BLIS on DSP by offloading bli_init() on DSP */
121 Kernel* __K; 86 TI_CBLAS_DEBUG_PRINT("Initializing BLIS on DSP...\n");
87 Event e;
88 Kernel* __K;
122 89
123 __K = ti_cblas_get_kernel(TI_CBLAS_CBLAS_CGEMM_IDX, "ocl_bli_finalize"); 90 __K = ti_cblas_get_kernel("ocl_bli_init");
91 try
92 {
93 int err_code;
94 Buffer buf_err(*ti_cblas_ocl_context, CL_MEM_READ_WRITE|CL_MEM_USE_HOST_PTR, sizeof(int), &err_code);
95 __K->setArg(0, buf_err);
124 96
125 /* Finalize BLIS on DSP */ 97 ti_cblas_ocl_Q->enqueueTask(*__K, 0, &e);
126 TI_CBLAS_DEBUG_PRINT("Finalizing BLIS on DSP...\n"); 98 e.wait();
127 int err_code;
128 Buffer buf_err(*ti_cblas_ocl_context, CL_MEM_READ_WRITE|CL_MEM_USE_HOST_PTR, sizeof(int), &err_code);
129 __K->setArg(0, buf_err);
130
131 try
132 {
133 ti_cblas_ocl_Q->enqueueTask(*__K, 0, &e);
134 e.wait();
135 99
136 if(err_code != TICBLAS_SUCCESS) { 100 if(err_code != TICBLAS_SUCCESS) {
137 TI_CBLAS_DEBUG_PRINT("Error in offloaded ocl_bli_finalize with error code %d!\n", err_code); 101 TI_CBLAS_DEBUG_PRINT("Error in offloaded ocl_bli_init with error code %d!\n", err_code);
138 r_val = TI_CBLAS_INITFINI_BLI_ERR; 102 r_val = TI_CBLAS_INITFINI_BLI_ERR;
139 } 103 }
140 104
141 ti_cblas_delete_kernel(__K); 105 ti_cblas_delete_kernel(__K);
142 } 106 TI_CBLAS_DEBUG_PRINT("BLIS DSP initialization finished.\n");
143
144 catch (Error err)
145 {
146 ti_cblas_error(err.what(),err.err());
147 r_val = TI_CBLAS_INITFINI_OCL_ERR;
148 }
149
150 return r_val;
151}
152
153#ifdef __cplusplus
154extern "C"
155#endif
156int ti_cblas_finalize(void)
157{
158 /* If ti_cblas_init_done is equal to 0,
159 * then we know that ti_cblas_init was not called,
160 * and so we can return early.
161 */
162 if(ti_cblas_init_done == 0) {
163 return TI_CBLAS_INITFINI_SUCCESS;
164 } 107 }
165 108
166 int r_val = ti_blis_finalize(); 109 catch (Error err)
167 /*Using same name as ti_cblas_init critical region. See notes in bli_init*/
168#pragma omp critical (ti_cblas_init_critical)
169 {
170 // Destroy Pthread
171 pthread_mutex_destroy(&MUTEX);
172 pthread_cond_destroy (&CV);
173
174 //destroy Command queue, program, devices and context.
175 if(ti_cblas_ocl_Q != NULL)
176 {
177 delete(ti_cblas_ocl_Q);
178 ti_cblas_ocl_Q = NULL;
179 }
180 if(ti_cblas_ocl_program != NULL)
181 {
182 delete(ti_cblas_ocl_program);
183 ti_cblas_ocl_program = NULL;
184 }
185 if(ti_cblas_ocl_binary != NULL)
186 {
187 delete(ti_cblas_ocl_binary);
188 ti_cblas_ocl_binary = NULL;
189 }
190 if(ti_cblas_ocl_devices != NULL)
191 {
192 delete(ti_cblas_ocl_devices);
193 ti_cblas_ocl_devices = NULL;
194 }
195 if(ti_cblas_ocl_context != NULL)
196 {
197 delete(ti_cblas_ocl_context);
198 ti_cblas_ocl_context = NULL;
199 }
200 }
201
202 return r_val;
203}
204
205void ti_cblas_auto_finalize(void)
206{
207 int r_val;
208
209 r_val = ti_cblas_finalize();
210 if (r_val != TI_CBLAS_INITFINI_SUCCESS)
211 { 110 {
212 fprintf(stderr, "Error: ti_cblas_finalize failed with error code %d!\n", r_val); 111 ti_cblas_delete_kernel(__K);
112 ti_cblas_error(err.what(),err.err());
113 r_val = TI_CBLAS_INITFINI_OCL_ERR;
213 } 114 }
214}
215 115
216/* This function is invoked exactly once on startup */ 116 return r_val;
217/* Its purpose is to parse the environment variables and do OpenCL init */ 117} // ti_blis_init
118
119
120/*============================================================================
121 * Function purpose: initialize and prepare for CBLAS calls:
122 * - parse the environment variables
123 * - initialize OpenCL
124 * - initialize BLIS
125 *
126 * Note: this function is invoked exactly once on startup, when any CBLAS function
127 * is called the first time.
128 *============================================================================*/
218void ti_cblas_init(void) 129void ti_cblas_init(void)
219{ 130{
220#pragma omp critical (ti_cblas_init_critical) 131#pragma omp critical (ti_cblas_init_critical)
221 { 132 {
222 /* Add code for interception */ 133 /* Add code for interception */
223 if (!ti_cblas_init_done)
224 {
225#ifdef TI_CBLAS_DEBUG 134#ifdef TI_CBLAS_DEBUG
226 char *no_debug_env = getenv("TI_CBLAS_NO_DEBUG"); 135 char *no_debug_env = getenv("TI_CBLAS_NO_DEBUG");
227 if (no_debug_env) { 136 if (no_debug_env) {
@@ -238,8 +147,8 @@ void ti_cblas_init(void)
238 /* check environment variables */ 147 /* check environment variables */
239 const char *offload_env = getenv("TI_CBLAS_OFFLOAD"); 148 const char *offload_env = getenv("TI_CBLAS_OFFLOAD");
240 if (!offload_env) { 149 if (!offload_env) {
241 TI_CBLAS_DEBUG_PRINT("Using build time default for offload: TI_CBLAS_OFFLOAD=%s\n", TI_CBLAS_OFFLOAD); 150 TI_CBLAS_DEBUG_PRINT("Using build time default for offload: TI_CBLAS_OFFLOAD=%s\n", TI_CBLAS_OFFLOAD_DEF);
242 offload_env = TI_CBLAS_OFFLOAD; 151 offload_env = TI_CBLAS_OFFLOAD_DEF;
243 } 152 }
244 else { 153 else {
245 TI_CBLAS_DEBUG_PRINT("Using runtime override for offloads: TI_CBLAS_OFFLOAD=%s\n", offload_env); 154 TI_CBLAS_DEBUG_PRINT("Using runtime override for offloads: TI_CBLAS_OFFLOAD=%s\n", offload_env);
@@ -280,166 +189,224 @@ void ti_cblas_init(void)
280#else 189#else
281 const char binary[] = "./ti_cblas_kernel.out"; 190 const char binary[] = "./ti_cblas_kernel.out";
282 unsigned int bin_length; 191 unsigned int bin_length;
283#ifdef __cplusplus
284 bin_length = ocl_read_binary(binary, (char*&)bin); 192 bin_length = ocl_read_binary(binary, (char*&)bin);
285#else
286 FILE *fp = fopen(binary, "r");
287 if (!fp) {
288 TI_CBLAS_ERROR_EXIT("Could not open OpenCL pre-compiled binary %s for reading\n", binary);
289 }
290 struct stat fileinfo;
291 stat(binary, &fileinfo);
292 bin_length = fileinfo.st_size;
293 bin = (char *)malloc(bin_length);
294 if (!bin) {
295 TI_CBLAS_ERROR_EXIT("Could not malloc of size %d for reading OpenCL binary\n", bin_length);
296 }
297 if (fread((char *)bin, bin_length, 1, fp) != 1) {
298 TI_CBLAS_ERROR_EXIT("Could not read %d bytes of OpenCL binary\n", bin_length);
299 }
300 fclose(fp);
301#endif /* cplusplus */
302#endif /* FAT_BINARY */ 193#endif /* FAT_BINARY */
303 194
304 /* OpenCL init */ 195 /* OpenCL init */
305 TI_CBLAS_DEBUG_PRINT("Initializing OpenCL\n"); 196 TI_CBLAS_DEBUG_PRINT("Initializing OpenCL\n");
306#ifdef __cplusplus 197 ti_cblas_ocl_context = new Context(CL_DEVICE_TYPE_ACCELERATOR);
307 ti_cblas_ocl_context = new Context(CL_DEVICE_TYPE_ACCELERATOR); 198 ti_cblas_ocl_devices = new std::vector<Device> (ti_cblas_ocl_context->getInfo<CL_CONTEXT_DEVICES>());
308 ti_cblas_ocl_devices = new std::vector<Device> (ti_cblas_ocl_context->getInfo<CL_CONTEXT_DEVICES>()); 199 ti_cblas_ocl_binary = new Program::Binaries(1, std::make_pair(bin, bin_length));
309 ti_cblas_ocl_binary = new Program::Binaries(1, std::make_pair(bin, bin_length)); 200 ti_cblas_ocl_program = new Program(*ti_cblas_ocl_context, *ti_cblas_ocl_devices, *ti_cblas_ocl_binary);
310 ti_cblas_ocl_program = new Program(*ti_cblas_ocl_context, *ti_cblas_ocl_devices, *ti_cblas_ocl_binary); 201 ti_cblas_ocl_program->build(*ti_cblas_ocl_devices);
311 ti_cblas_ocl_program->build(*ti_cblas_ocl_devices); 202 ti_cblas_ocl_Q = new CommandQueue(*ti_cblas_ocl_context, ti_cblas_ocl_devices[0][0], CL_QUEUE_PROFILING_ENABLE);
312 ti_cblas_ocl_Q = new CommandQueue(*ti_cblas_ocl_context, ti_cblas_ocl_devices[0][0], CL_QUEUE_PROFILING_ENABLE);
313#else
314 cl_int err;
315 cl_device_id device;
316 /* Create an in-order command queue by default*/
317 int queue_flags = 0;
318#ifdef TI_CBLAS_PROFILE
319 queue_flags |= CL_QUEUE_PROFILING_ENABLE;
320#endif
321
322 ti_cblas_ocl_context = clCreateContextFromType(0,CL_DEVICE_TYPE_ACCELERATOR,0,0,&err);
323 TI_CBLAS_OCL_CHKERROR("clCreateContextFromType",err);
324 err = clGetDeviceIDs(0,CL_DEVICE_TYPE_ACCELERATOR,1,&device,0);
325 TI_CBLAS_OCL_CHKERROR("clGetDeviceIDs",err);
326 ti_cblas_ocl_Q = clCreateCommandQueue(ti_cblas_ocl_context, device, queue_flags, &err);
327 TI_CBLAS_OCL_CHKERROR("clCreateCommandQueue",err);
328 ti_cblas_ocl_program = clCreateProgramWithBinary(ti_cblas_ocl_context, 1, &device, &bin_length, &bin, NULL, &err);
329 TI_CBLAS_OCL_CHKERROR("clCreateProgramWithBinary",err);
330 const char *compile_options = "";
331 err = clBuildProgram(ti_cblas_ocl_program, 1, &device, compile_options, 0, 0);
332 TI_CBLAS_OCL_CHKERROR("clBuildProgram",err);
333
334#endif
335 203
336#ifndef TI_CBLAS_FAT_BINARY 204#ifndef TI_CBLAS_FAT_BINARY
337#ifdef __cplusplus
338 delete [] bin; 205 delete [] bin;
339#else
340 free((char*)bin);
341#endif
342#endif /* FAT_BINARY */ 206#endif /* FAT_BINARY */
207
343 TI_CBLAS_DEBUG_PRINT("OpenCL initialized\n"); 208 TI_CBLAS_DEBUG_PRINT("OpenCL initialized\n");
344 209
210 /* Initializing pthreads */
345 TI_CBLAS_DEBUG_PRINT("Initializing Pthreads\n"); 211 TI_CBLAS_DEBUG_PRINT("Initializing Pthreads\n");
346 /* Initializing pthreads */ 212 pthread_cond_init (&CV, 0);
347 pthread_cond_init (&CV, 0); 213 pthread_mutex_init(&MUTEX, 0);
348 pthread_mutex_init(&MUTEX, 0); 214 TI_CBLAS_DEBUG_PRINT("Pthreads initialized\n");
349 TI_CBLAS_DEBUG_PRINT("Pthreads initialized\n"); 215 TI_CBLAS_DEBUG_PRINT("Initializing BLIS\n");
350 TI_CBLAS_DEBUG_PRINT("Initializing BLIS\n"); 216 if(ti_blis_init() == TI_CBLAS_INITFINI_SUCCESS) {
351 if(ti_blis_init() == TI_CBLAS_INITFINI_SUCCESS) {
352 TI_CBLAS_DEBUG_PRINT("BLIS initialized\n");\ 217 TI_CBLAS_DEBUG_PRINT("BLIS initialized\n");\
353 } 218 }
354 else { 219 else {
355 TI_CBLAS_DEBUG_PRINT("BLIS NOT initialized!\n");\ 220 TI_CBLAS_DEBUG_PRINT("BLIS NOT initialized!\n");\
356 } 221 }
357 222
358 atexit(ti_cblas_auto_finalize); 223 /* Register auto finalization to be called when program exits */
224 atexit(ti_cblas_auto_finalize);
359 225
360 TI_CBLAS_PROFILE_REPORT(" Initialization took %8.2f us\n", (float) clock_diff); 226 TI_CBLAS_PROFILE_REPORT("Initialization took %8.2f us\n", (float) clock_diff);
361 ti_cblas_init_done = 1; 227 ti_cblas_init_done = 1;
362 TI_CBLAS_DEBUG_PRINT("ti_cblas_init: Finished OpenCL initialization\n"); 228 TI_CBLAS_DEBUG_PRINT("ti_cblas_init: Finished initialization\n");
363 } //end of !ti_cblas_init_done
364 229
365 } // End of critical section 230 } // End of critical section
366 231
367 return; 232 return;
368} 233} //ti_cblas_init
369 234
235/*============================================================================
236 * Function purpose: finalize BLIS on both ARM and DSP
237 *============================================================================*/
238int ti_blis_finalize(void)
239{
240 int r_val = TI_CBLAS_INITFINI_SUCCESS;
241
242 /* Finalize BLIS on ARM */
243 TI_CBLAS_DEBUG_PRINT("Finalizing BLIS on ARM...\n");
244 bli_finalize();
245 TI_CBLAS_DEBUG_PRINT("BLIS finalized on ARM.\n");
370 246
247 /* Finalize BLIS on DSP */
248 Event e;
249 Kernel* __K;
371 250
372void ti_cblas_mem_free(void *ptr) 251 __K = ti_cblas_get_kernel("ocl_bli_finalize");
252
253 TI_CBLAS_DEBUG_PRINT("Finalizing BLIS on DSP...\n");
254 int err_code;
255 Buffer buf_err(*ti_cblas_ocl_context, CL_MEM_READ_WRITE|CL_MEM_USE_HOST_PTR, sizeof(int), &err_code);
256 __K->setArg(0, buf_err);
257
258 try
259 {
260 ti_cblas_ocl_Q->enqueueTask(*__K, 0, &e);
261 e.wait();
262
263 if(err_code != TICBLAS_SUCCESS) {
264 TI_CBLAS_DEBUG_PRINT("Error in offloaded ocl_bli_finalize with error code %d!\n", err_code);
265 r_val = TI_CBLAS_INITFINI_BLI_ERR;
266 }
267
268 ti_cblas_delete_kernel(__K);
269 }
270
271 catch (Error err)
272 {
273 ti_cblas_error(err.what(),err.err());
274 r_val = TI_CBLAS_INITFINI_OCL_ERR;
275 }
276
277 return r_val;
278} // ti_blis_finalize
279
280/*============================================================================
281 * Function purpose: finalize after all CBLAS calls:
282 * - finalize BLIS
283 * - delete OpenCL context
284 *
285 * Note: this function is invoked exactly once on program exit.
286 *============================================================================*/
287int ti_cblas_finalize(void)
373{ 288{
374 pthread_mutex_lock(&MUTEX); 289 /* If ti_cblas_init_done is equal to 0,
375 __free_msmc(ptr); 290 * then we know that ti_cblas_init was not called,
376 pthread_cond_broadcast(&CV); 291 * and so we can return early.
377 pthread_mutex_unlock(&MUTEX); 292 */
293 if(ti_cblas_init_done == 0) {
294 return TI_CBLAS_INITFINI_SUCCESS;
295 }
378 296
379} 297 int r_val = ti_blis_finalize();
298 /*Using same name as ti_cblas_init critical region. See notes in bli_init*/
299#pragma omp critical (ti_cblas_init_critical)
300 {
301 // Destroy Pthread
302 pthread_mutex_destroy(&MUTEX);
303 pthread_cond_destroy (&CV);
304
305 //destroy Command queue, program, devices and context.
306 if(ti_cblas_ocl_Q != NULL)
307 {
308 delete(ti_cblas_ocl_Q);
309 ti_cblas_ocl_Q = NULL;
310 }
311 if(ti_cblas_ocl_program != NULL)
312 {
313 delete(ti_cblas_ocl_program);
314 ti_cblas_ocl_program = NULL;
315 }
316 if(ti_cblas_ocl_binary != NULL)
317 {
318 delete(ti_cblas_ocl_binary);
319 ti_cblas_ocl_binary = NULL;
320 }
321 if(ti_cblas_ocl_devices != NULL)
322 {
323 delete(ti_cblas_ocl_devices);
324 ti_cblas_ocl_devices = NULL;
325 }
326 if(ti_cblas_ocl_context != NULL)
327 {
328 delete(ti_cblas_ocl_context);
329 ti_cblas_ocl_context = NULL;
330 }
331 }
332
333 return r_val;
334} // ti_cblas_finalize
380 335
381void *ti_cblas_mem_alloc(size_t size) 336
337/*============================================================================
338 * Function purpose: auto-finalize on program exit.
339 *============================================================================*/
340void ti_cblas_auto_finalize(void)
382{ 341{
383 void *ptr; 342 int r_val;
384 pthread_mutex_lock(&MUTEX);
385 /*-------------------------------------------------------------------------
386 343
387 * Loop in case of false signal after broadcast. 344 r_val = ti_cblas_finalize();
345 if (r_val != TI_CBLAS_INITFINI_SUCCESS)
346 {
347 fprintf(stderr, "Error: ti_cblas_finalize failed with error code %d!\n", r_val);
348 }
349} //ti_cblas_auto_finalize
388 350
389 *------------------------------------------------------------------------*/
390 while ((ptr = __malloc_msmc(size)) == 0)
391 351
392 pthread_cond_wait(&CV, &MUTEX); 352/*============================================================================
393 pthread_mutex_unlock(&MUTEX); 353 * Function purpose: free previously allocated MSMC memory
394 return ptr; 354 *============================================================================*/
355void ti_cblas_mem_free(void *ptr)
356{
357 pthread_mutex_lock(&MUTEX);
358 __free_msmc(ptr);
359 pthread_cond_broadcast(&CV);
360 pthread_mutex_unlock(&MUTEX);
395 361
396} 362}
397 363
364/*============================================================================
365 * Function purpose: allocate MSMC memory
366 *============================================================================*/
367void *ti_cblas_mem_alloc(size_t size)
368{
369 void *ptr;
370 pthread_mutex_lock(&MUTEX);
371
372 /*-------------------------------------------------------------------------
373 * Loop in case of false signal after broadcast.
374 *------------------------------------------------------------------------*/
375 while ((ptr = __malloc_msmc(size)) == 0)
376 {
377 pthread_cond_wait(&CV, &MUTEX);
378 }
398 379
399/* Returns a handle to the kernel for the specified 380 pthread_mutex_unlock(&MUTEX);
400 * function with index 'idx'. Initializes the handle if it's 381
401 * not been used before, otherwise returns earlier handle 382 return ptr;
402 */ 383} //ti_cblas_mem_alloc
403#ifdef __cplusplus 384
404Kernel* 385
405#else 386/*============================================================================
406cl_kernel 387 * Function purpose: create an OpenCL kernel
407#endif 388 *============================================================================*/
408ti_cblas_get_kernel(int idx, const char *fname) 389Kernel *ti_cblas_get_kernel(const char *fname)
409{ 390{
410#ifdef __cplusplus 391 Kernel* __K;
411 Kernel* __K;
412#else
413 cl_kernel __K;
414#endif
415 392
416#ifdef __cplusplus
417 __K = new Kernel(*ti_cblas_ocl_program, fname); 393 __K = new Kernel(*ti_cblas_ocl_program, fname);
418#else
419 cl_int err;
420 __K = clCreateKernel(ti_cblas_ocl_program,fname,&err);
421 TI_CBLAS_OCL_CHKERROR("clCreateKernel",err);
422#endif
423 394
424 return __K; 395 return __K;
425} 396}
426 397
427#ifdef __cplusplus 398/*============================================================================
399 * Function purpose: delete an OpenCL kernel
400 *============================================================================*/
428int ti_cblas_delete_kernel(Kernel* K) 401int ti_cblas_delete_kernel(Kernel* K)
429#else
430int ti_cblas_delete_kernel(cl_kernel K)
431#endif
432{ 402{
433#ifdef __cplusplus 403 if(K != NULL)
434 if(K != NULL) 404 {
435 { 405 delete(K);
436 delete(K); 406 K=NULL;
437 K=NULL; 407 }
438 } 408
439#else 409 return 0;
440 clReleaseKernel(K);
441#endif
442 return 0;
443} 410}
444 411
445 412/* Nothing after this line */
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_kernel.cl b/src/ti/linalg/blasblisacc/src/ti_cblas_kernel.cl
index 8fa16d0..b4368eb 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_kernel.cl
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_kernel.cl
@@ -25,6 +25,9 @@
25 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 25 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
26 * THE POSSIBILITY OF SUCH DAMAGE. 26 * THE POSSIBILITY OF SUCH DAMAGE.
27 *****************************************************************************/ 27 *****************************************************************************/
28/*==============================================================================
29 * This file contains the OpenCL kernels of ARM+DSP CBLAS library.
30 *============================================================================*/
28 31
29#define CBLAS_H 32#define CBLAS_H
30#define CBLAS_INDEX size_t /* this may vary between platforms */ 33#define CBLAS_INDEX size_t /* this may vary between platforms */
@@ -34,16 +37,16 @@ enum CBLAS_UPLO {CblasUpper=121, CblasLower=122};
34enum CBLAS_DIAG {CblasNonUnit=131, CblasUnit=132}; 37enum CBLAS_DIAG {CblasNonUnit=131, CblasUnit=132};
35enum CBLAS_SIDE {CblasLeft=141, CblasRight=142}; 38enum CBLAS_SIDE {CblasLeft=141, CblasRight=142};
36 39
37 40int tiCblasNew(void);
38int ti_bli_init_dsp(void);
39kernel void ocl_bli_init(global int *err_code) 41kernel void ocl_bli_init(global int *err_code)
40{ 42{
41 *err_code = ti_bli_init_dsp(); 43 *err_code = tiCblasNew();
42} 44}
43int ti_bli_finalize_dsp(void); 45
46int tiCblasDelete(void);
44kernel void ocl_bli_finalize(global int *err_code) 47kernel void ocl_bli_finalize(global int *err_code)
45{ 48{
46 *err_code = ti_bli_finalize_dsp(); 49 *err_code = tiCblasDelete();
47} 50}
48 51
49void cblas_caxpy_facade(const int N, global const void *alpha, global const void *X, const int incX, global void *Y, const int incY); 52void cblas_caxpy_facade(const int N, global const void *alpha, global const void *X, const int incX, global void *Y, const int incY);
diff --git a/src/ti/linalg/blasblisacc/src/ti_cblas_mem_config.c b/src/ti/linalg/blasblisacc/src/ti_cblas_mem_config.c
index a506ece..54d6e27 100644
--- a/src/ti/linalg/blasblisacc/src/ti_cblas_mem_config.c
+++ b/src/ti/linalg/blasblisacc/src/ti_cblas_mem_config.c
@@ -33,6 +33,13 @@
33#include "../../ticblas/ticblas.h" 33#include "../../ticblas/ticblas.h"
34#include <ti/libarch/libarch.h> 34#include <ti/libarch/libarch.h>
35 35
36/*==============================================================================
37 * This file contains functions of the DSP OpenCL layer of ARM+DSP CBLAS library.
38 *============================================================================*/
39
40#define TICBLAS_ERROR_MEMCFG (-1) /* L1D/L2 config error. */
41#define TICBLAS_ERROR_MEMRECFG (-2) /* /L2 reconfig error. */
42
36extern void bli_init(); 43extern void bli_init();
37extern void bli_finalize(); 44extern void bli_finalize();
38 45
@@ -41,23 +48,39 @@ int malloc_size;
41extern lib_memdscr_t * blas_memdscr_tab[4]; 48extern lib_memdscr_t * blas_memdscr_tab[4];
42#endif 49#endif
43 50
44int bli_l3_mem_config(void *msmc_buf, size_t msmc_buf_size, void *ddr_buf, size_t ddr_buf_size, size_t *l1D_SRAM_size_orig, size_t *l2_SRAM_size_orig) 51/*==============================================================================
52 * This function configures L1D and L2 and initializes heap for BLIS.
53 *
54 * Input:
55 * msmc_buf - base address of MSMC/L3 buffer
56 * msmc_buf_size - size of MSMC/L3 buffer
57 * ddr_buf - base address of DDR buffer
58 * ddr_buf_size - size of DDR buffer
59 * Output:
60 * l1D_SRAM_size_orig - original L1D SRAM size
61 * l2_SRAM_size_orig - original L2 SRAM size
62 *============================================================================*/
63int bli_l3_mem_config(void *msmc_buf, size_t msmc_buf_size,
64 void *ddr_buf, size_t ddr_buf_size,
65 size_t *l1D_SRAM_size_orig, size_t *l2_SRAM_size_orig)
45{ 66{
46 size_t smem_size_vfast, smem_size_fast, smem_size_med, smem_size_slow; 67 size_t smem_size_vfast, smem_size_fast, smem_size_med, smem_size_slow;
47 void *l1d_SRAM_ptr, *l2_SRAM_ptr; 68 void *l1d_SRAM_ptr, *l2_SRAM_ptr;
48 int l1d_cfg_err, l2_cfg_err, blas_ret_err_code; 69 int l1d_cfg_err, l2_cfg_err, blas_ret_err_code;
49 70
50#ifdef TI_CBLAS_DEBUG 71#ifdef TI_CBLAS_DEBUG
51 malloc_size = 0; 72 malloc_size = 0;
52 printf("Memory buffers passed to bli_l3_mem_config are: MSMC base 0x%x, size %d, DDR base 0x%x, size%d.\n", (unsigned int)msmc_buf, msmc_buf_size, (unsigned int) ddr_buf, ddr_buf_size); 73 printf("Memory buffers passed to bli_l3_mem_config are: MSMC base 0x%x, size %d, DDR base 0x%x, size%d.\n",
53 printf("Before calling BLIS, malloc_size is %d.\n", malloc_size); 74 (unsigned int)msmc_buf, msmc_buf_size, (unsigned int) ddr_buf, ddr_buf_size);
75 printf("Before calling BLIS, malloc_size is %d.\n", malloc_size);
54#endif 76#endif
55 77
56 /* First, verify the provided/available memory meet requirements */ 78 /* First, verify the provided and available memory meet requirements */
57 tiCblasGetSizes(&smem_size_vfast, &smem_size_fast, &smem_size_med, &smem_size_slow); 79 tiCblasGetSizes(&smem_size_vfast, &smem_size_fast, &smem_size_med, &smem_size_slow);
58 80
59#ifdef TI_CBLAS_DEBUG 81#ifdef TI_CBLAS_DEBUG
60 printf("Very fast mem size is %d, fast mem size is %d, medium mem size is %d, slow mem size is %d.\n", smem_size_vfast, smem_size_fast, smem_size_med, smem_size_slow); 82 printf("Very fast mem size is %d, fast mem size is %d, medium mem size is %d, slow mem size is %d.\n",
83 smem_size_vfast, smem_size_fast, smem_size_med, smem_size_slow);
61 printf("Total L1D size is: %d\n", lib_get_L1D_total_size()); 84 printf("Total L1D size is: %d\n", lib_get_L1D_total_size());
62 printf("Total L2 size is: %d\n", lib_get_L2_total_size()); 85 printf("Total L2 size is: %d\n", lib_get_L2_total_size());
63#endif 86#endif
@@ -83,7 +106,6 @@ int bli_l3_mem_config(void *msmc_buf, size_t msmc_buf_size, void *ddr_buf, size_
83#endif 106#endif
84 107
85 if(*l1D_SRAM_size_orig < smem_size_vfast) { /* configure L1D if needs more SRAM */ 108 if(*l1D_SRAM_size_orig < smem_size_vfast) { /* configure L1D if needs more SRAM */
86 /*printf("Configuring L1D SRAM on all cores.\n");*/
87 #pragma omp parallel 109 #pragma omp parallel
88 { 110 {
89 l1d_cfg_err = lib_L1D_config_SRAM(smem_size_vfast); 111 l1d_cfg_err = lib_L1D_config_SRAM(smem_size_vfast);
@@ -98,13 +120,6 @@ int bli_l3_mem_config(void *msmc_buf, size_t msmc_buf_size, void *ddr_buf, size_
98 } 120 }
99 } 121 }
100 122
101#ifdef TI_CBLAS_DEBUG
102 #pragma omp parallel
103 {
104 int core_id = lib_get_coreID();
105 }
106#endif
107
108 /* Configure L2 if necessary */ 123 /* Configure L2 if necessary */
109 *l2_SRAM_size_orig = lib_get_L2_SRAM_size(); /* get current L2 SRAM size */ 124 *l2_SRAM_size_orig = lib_get_L2_SRAM_size(); /* get current L2 SRAM size */
110 l2_cfg_err = LIB_CACHE_SUCCESS; 125 l2_cfg_err = LIB_CACHE_SUCCESS;
@@ -118,7 +133,6 @@ int bli_l3_mem_config(void *msmc_buf, size_t msmc_buf_size, void *ddr_buf, size_
118 #pragma omp parallel 133 #pragma omp parallel
119 { 134 {
120 l2_cfg_err = lib_L2_config_SRAM(smem_size_fast); 135 l2_cfg_err = lib_L2_config_SRAM(smem_size_fast);
121 }
122#ifdef TI_CBLAS_DEBUG 136#ifdef TI_CBLAS_DEBUG
123 if(l2_cfg_err != LIB_CACHE_SUCCESS) { 137 if(l2_cfg_err != LIB_CACHE_SUCCESS) {
124 printf("Error in configuring L2 on core %d!\n", lib_get_coreID()); 138 printf("Error in configuring L2 on core %d!\n", lib_get_coreID());
@@ -127,6 +141,7 @@ int bli_l3_mem_config(void *msmc_buf, size_t msmc_buf_size, void *ddr_buf, size_
127 printf("On core %d, new L2 SRAM size is %d.\n", lib_get_coreID(), lib_get_L2_SRAM_size()); 141 printf("On core %d, new L2 SRAM size is %d.\n", lib_get_coreID(), lib_get_L2_SRAM_size());
128 } 142 }
129#endif 143#endif
144 }
130 } 145 }
131 146
132 if(l1d_cfg_err || l2_cfg_err) { 147 if(l1d_cfg_err || l2_cfg_err) {
@@ -137,8 +152,8 @@ int bli_l3_mem_config(void *msmc_buf, size_t msmc_buf_size, void *ddr_buf, size_
137 } 152 }
138 153
139#ifdef TI_CBLAS_DEBUG 154#ifdef TI_CBLAS_DEBUG
140 printf("New L1D SRAM size is: %d\n", lib_get_L1D_SRAM_size()); 155 printf("New L1D SRAM size is: %d\n", lib_get_L1D_SRAM_size());
141 printf("New L2 SRAM size is: %d\n", lib_get_L2_SRAM_size()); 156 printf("New L2 SRAM size is: %d\n", lib_get_L2_SRAM_size());
142#endif 157#endif
143 158
144 /* get L1D and L2 SRAM base address */ 159 /* get L1D and L2 SRAM base address */
@@ -158,15 +173,16 @@ int bli_l3_mem_config(void *msmc_buf, size_t msmc_buf_size, void *ddr_buf, size_
158 ddr_buf, ddr_buf_size); 173 ddr_buf, ddr_buf_size);
159 174
160#ifdef TI_CBLAS_DEBUG 175#ifdef TI_CBLAS_DEBUG
161 if(blas_ret_err_code == TICBLAS_SUCCESS) { 176 if(blas_ret_err_code == TICBLAS_SUCCESS) {
162 printf("Before calling BLIS, memory descriptor base is 0x%x, used is %d.\n", blas_memdscr_tab[3]->base, blas_memdscr_tab[3]->used); 177 printf("Before calling BLIS, memory descriptor base is 0x%x, used is %d.\n",
163 } 178 blas_memdscr_tab[3]->base, blas_memdscr_tab[3]->used);
164 else { 179 }
165 printf("BLAS init error with code %d.\n ", blas_ret_err_code); 180 else {
166 } 181 printf("BLAS init error with code %d.\n ", blas_ret_err_code);
182 }
167#endif 183#endif
168 184
169 return(blas_ret_err_code); 185 return(blas_ret_err_code);
170} /* bli_l3_mem_config */ 186} /* bli_l3_mem_config */
171 187
172/*============================================================================== 188/*==============================================================================
@@ -177,11 +193,13 @@ int bli_l3_mem_reconfig(size_t l1D_SRAM_size_orig, size_t l2_SRAM_size_orig)
177 int l1d_cfg_err, l2_cfg_err; 193 int l1d_cfg_err, l2_cfg_err;
178 194
179#ifdef TI_CBLAS_DEBUG 195#ifdef TI_CBLAS_DEBUG
180 printf("After calling BLIS, malloc_size is %d.\n", malloc_size); 196 printf("After calling BLIS, malloc_size is %d.\n", malloc_size);
181 printf("After calling BLIS, used_size in memory descriptor is %d.\n", blas_memdscr_tab[3]->used); 197 printf("After calling BLIS, used_size in memory descriptor is %d.\n",
182 printf("Configuring L1D SRAM and L2 SRAM back to %d and %d.\n", l1D_SRAM_size_orig, l2_SRAM_size_orig); 198 blas_memdscr_tab[3]->used);
199 printf("Configuring L1D SRAM and L2 SRAM back to %d and %d.\n",
200 l1D_SRAM_size_orig, l2_SRAM_size_orig);
183#endif 201#endif
184 202
185 /* configure L1D back if necessary */ 203 /* configure L1D back if necessary */
186 l1d_cfg_err = LIB_CACHE_SUCCESS; 204 l1d_cfg_err = LIB_CACHE_SUCCESS;
187 if(l1D_SRAM_size_orig!=lib_get_L1D_SRAM_size()) { 205 if(l1D_SRAM_size_orig!=lib_get_L1D_SRAM_size()) {
@@ -214,20 +232,4 @@ int bli_l3_mem_reconfig(size_t l1D_SRAM_size_orig, size_t l2_SRAM_size_orig)
214 return(TICBLAS_SUCCESS); 232 return(TICBLAS_SUCCESS);
215} /* bli_l3_mem_reconfig */ 233} /* bli_l3_mem_reconfig */
216 234
217/*==============================================================================
218 * This function initializes BLIS before first CBLAS call is made.
219 *============================================================================*/
220int ti_bli_init_dsp(void)
221{
222 return tiCblasNew();
223}
224
225/*==============================================================================
226 * This function frees all memories allocated by ti_bli_init_dsp.
227 *============================================================================*/
228int ti_bli_finalize_dsp(void)
229{
230 return tiCblasDelete();
231}
232
233/* Nothing after this line */ 235/* Nothing after this line */
diff --git a/src/ti/linalg/blasblisacc/src/wrap_gen/oclgen.pl b/src/ti/linalg/blasblisacc/src/wrap_gen/oclgen.pl
index 77a49a4..7c5fe27 100755
--- a/src/ti/linalg/blasblisacc/src/wrap_gen/oclgen.pl
+++ b/src/ti/linalg/blasblisacc/src/wrap_gen/oclgen.pl
@@ -395,7 +395,7 @@ Kernel*
395#else 395#else
396cl_kernel 396cl_kernel
397#endif 397#endif
398${namespace}_get_kernel(int idx, const char *fname) 398${namespace}_get_kernel(const char *fname)
399{ 399{
400 if (!${namespace}_kernel_valid[idx]) { 400 if (!${namespace}_kernel_valid[idx]) {
401#ifdef __cplusplus 401#ifdef __cplusplus
@@ -2204,7 +2204,7 @@ ARM_FROM_PROTO
2204#else 2204#else
2205 cl_kernel __K; 2205 cl_kernel __K;
2206#endif 2206#endif
2207 __K = ${namespace}_get_kernel($trampdef, \"ocl_$trampname\"); 2207 __K = ${namespace}_get_kernel(\"ocl_$trampname\");
2208 2208
2209#ifdef __cplusplus 2209#ifdef __cplusplus
2210 try 2210 try
@@ -2771,7 +2771,7 @@ $::dep
2771extern void ${namespace}_error(const char* msg, int code); 2771extern void ${namespace}_error(const char* msg, int code);
2772extern void ${namespace}_init(void); 2772extern void ${namespace}_init(void);
2773#ifdef __cplusplus 2773#ifdef __cplusplus
2774extern Kernel* ${namespace}_get_kernel(int idx, const char *fname); 2774extern Kernel* ${namespace}_get_kernel(const char *fname);
2775extern Context ${namespace}_ocl_context; 2775extern Context ${namespace}_ocl_context;
2776extern std::vector<Device> ${namespace}_ocl_devices; 2776extern std::vector<Device> ${namespace}_ocl_devices;
2777extern CommandQueue ${namespace}_ocl_Q; 2777extern CommandQueue ${namespace}_ocl_Q;
@@ -2779,7 +2779,7 @@ extern Program::Binaries ${namespace}_ocl_binary;
2779extern Program ${namespace}_ocl_program; 2779extern Program ${namespace}_ocl_program;
2780extern Kernel* ${namespace}_ocl_kernels[]; 2780extern Kernel* ${namespace}_ocl_kernels[];
2781#else 2781#else
2782extern cl_kernel ${namespace}_get_kernel(int idx, const char *fname); 2782extern cl_kernel ${namespace}_get_kernelconst char *fname);
2783extern cl_context ${namespace}_ocl_context; 2783extern cl_context ${namespace}_ocl_context;
2784extern cl_command_queue ${namespace}_ocl_Q; 2784extern cl_command_queue ${namespace}_ocl_Q;
2785extern cl_program ${namespace}_ocl_program; 2785extern cl_program ${namespace}_ocl_program;
diff --git a/src/ti/linalg/blis/frame/base/bli_mem.c b/src/ti/linalg/blis/frame/base/bli_mem.c
index 4303217..275ff4f 100644
--- a/src/ti/linalg/blis/frame/base/bli_mem.c
+++ b/src/ti/linalg/blis/frame/base/bli_mem.c
@@ -72,37 +72,37 @@ static char pool_mn_mem[ BLIS_MN_POOL_SIZE ];
72 72
73//L1 73//L1
74static void* pool_mk_blk_ptrs_L1[ BLIS_NUM_MR_X_KC_BLOCKS_L1 ]; 74static void* pool_mk_blk_ptrs_L1[ BLIS_NUM_MR_X_KC_BLOCKS_L1 ];
75extern char *pool_mk_mem_L1; 75char *pool_mk_mem_L1;
76 76
77static void* pool_kn_blk_ptrs_L1[ BLIS_NUM_KC_X_NR_BLOCKS_L1 ]; 77static void* pool_kn_blk_ptrs_L1[ BLIS_NUM_KC_X_NR_BLOCKS_L1 ];
78extern char *pool_kn_mem_L1; 78char *pool_kn_mem_L1;
79 79
80static void* pool_mn_blk_ptrs_L1[ BLIS_NUM_MR_X_NR_BLOCKS_L1 ]; 80static void* pool_mn_blk_ptrs_L1[ BLIS_NUM_MR_X_NR_BLOCKS_L1 ];
81extern char *pool_mn_mem_L1; 81char *pool_mn_mem_L1;
82 82
83// 83//
84//L2 Pools 84//L2 Pools
85// 85//
86static void* pool_mk_blk_ptrs_L2[ BLIS_NUM_MC_X_KC_BLOCKS_L2 ]; 86static void* pool_mk_blk_ptrs_L2[ BLIS_NUM_MC_X_KC_BLOCKS_L2 ];
87extern char *pool_mk_mem_L2; 87char *pool_mk_mem_L2;
88 88
89static void* pool_kn_blk_ptrs_L2[ BLIS_NUM_KC_X_NC_BLOCKS_L2 ]; 89static void* pool_kn_blk_ptrs_L2[ BLIS_NUM_KC_X_NC_BLOCKS_L2 ];
90extern char *pool_kn_mem_L2; 90char *pool_kn_mem_L2;
91 91
92static void* pool_mn_blk_ptrs_L2[ BLIS_NUM_MC_X_NR_BLOCKS_L2 ]; 92static void* pool_mn_blk_ptrs_L2[ BLIS_NUM_MC_X_NR_BLOCKS_L2 ];
93extern char *pool_mn_mem_L2; 93char *pool_mn_mem_L2;
94 94
95// 95//
96//L3 Pools 96//L3 Pools
97// 97//
98static void* pool_mk_blk_ptrs_L3[ BLIS_NUM_MC_X_KC_BLOCKS_L3 ]; 98static void* pool_mk_blk_ptrs_L3[ BLIS_NUM_MC_X_KC_BLOCKS_L3 ];
99extern char *pool_mk_mem_L3; 99char *pool_mk_mem_L3;
100 100
101static void* pool_kn_blk_ptrs_L3[ BLIS_NUM_KC_X_NC_BLOCKS_L3 ]; 101static void* pool_kn_blk_ptrs_L3[ BLIS_NUM_KC_X_NC_BLOCKS_L3 ];
102extern char *pool_kn_mem_L3; 102char *pool_kn_mem_L3;
103 103
104static void* pool_mn_blk_ptrs_L3[ BLIS_NUM_MC_X_NC_BLOCKS_L3 ]; 104static void* pool_mn_blk_ptrs_L3[ BLIS_NUM_MC_X_NC_BLOCKS_L3 ];
105extern char *pool_mn_mem_L3; 105char *pool_mn_mem_L3;
106 106
107#else 107#else
108static pool_t pools[3]; 108static pool_t pools[3];
@@ -119,9 +119,6 @@ static char pool_mn_mem[ BLIS_MN_POOL_SIZE ];
119 119
120 120
121 121
122
123
124
125void bli_mem_acquire_m( siz_t req_size, 122void bli_mem_acquire_m( siz_t req_size,
126 packbuf_t buf_type, 123 packbuf_t buf_type,
127 mem_t* mem ) 124 mem_t* mem )
@@ -348,7 +345,90 @@ void bli_mem_acquire_v( siz_t req_size,
348 mem ); 345 mem );
349} 346}
350 347
348#ifdef BLIS_ENABLE_C66X_MEM_POOLS
349/*==============================================================================
350 * Functions bli_get_mem_sizes() and bli_scratch_mem_alloc() are only used for
351 * C66x implementation.
352 *
353 * BLIS memories are allocated in 3 different ways:
354 * 1. persistent memory: allocated by lib_pmem_salloc() which calls malloc() for now.
355 * 2. very fast, fast, and medium speed scratch memory: allocated by
356 * bli_scratch_mem_alloc().
357 * - This may be done just once at boot time if the provided memory address
358 * stay the same. This may be the case for DSP-only application where the
359 * memories for BLIS are statically allocated.
360 * - This can also be done before every level 3 BLAS function call. This
361 * may be the case when memories for BLIS are dynamically allocated in
362 * ARM+DSP applications.
363 * - Heaps need to be initialized by tiCblas API before allocation.
364 * 3. slow scratch memory: allocated by lib_smem_salloc() inside BLIS computation.
365 * The heap (slow scratch) needs to be initialized the same as above and reset
366 * whenever a level 3 BLIS function is called.
367 *
368 *============================================================================*/
369#define getNextMultiple(x, y) ( ( ((x)+(y)-1)/(y) )* (y) )
370
371#define BLAS_MEM_SIZE_VFAST ( getNextMultiple(BLIS_MK_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE) \
372 + getNextMultiple(BLIS_KN_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE) \
373 + getNextMultiple(BLIS_MN_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE) )
374#define BLAS_MEM_SIZE_FAST ( getNextMultiple(BLIS_MK_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE) \
375 + getNextMultiple(BLIS_KN_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE) \
376 + getNextMultiple(BLIS_MN_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE) )
377#define BLAS_MEM_SIZE_MEDIUM ( getNextMultiple(BLIS_MK_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE) \
378 + getNextMultiple(BLIS_KN_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE) \
379 + getNextMultiple(BLIS_MN_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE) )
380#define BLAS_MEM_SIZE_SLOW (4804)
381
382/*==============================================================================
383 * Purpose: returns the sizes of the non-persistent memories used by BLIS.
384 *============================================================================*/
385void bli_get_mem_sizes(size_t *smem_size_vfast, size_t *smem_size_fast,
386 size_t *smem_size_medium, size_t *smem_size_slow)
387{
388 *smem_size_vfast = BLAS_MEM_SIZE_VFAST; /* very fast scratch memory */
389 *smem_size_fast = BLAS_MEM_SIZE_FAST; /* fast scratch memory */
390 *smem_size_medium = BLAS_MEM_SIZE_MEDIUM; /* medium speed scratch memory */
391 *smem_size_slow = BLAS_MEM_SIZE_SLOW; /* slow scratch memory */
392}
351 393
394/*==============================================================================
395 * Purpose: allocates very fast, fast, and medium speed scratch memories from
396 * initialized heaps.
397 * Note: slow memoris are allocated during BLIS compuation.
398 *============================================================================*/
399int bli_scratch_mem_alloc()
400{
401 lib_memdscr_t **blas_mem_handle = blasGetMemHandle();
402
403 pool_mk_mem_L1 = lib_smem_valloc(blas_mem_handle, BLIS_MK_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE);
404 pool_kn_mem_L1 = lib_smem_valloc(blas_mem_handle, BLIS_KN_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE);
405 pool_mn_mem_L1 = lib_smem_valloc(blas_mem_handle, BLIS_MN_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE);
406
407 pool_mk_mem_L2 = lib_smem_falloc(blas_mem_handle, BLIS_MK_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE);
408 pool_kn_mem_L2 = lib_smem_falloc(blas_mem_handle, BLIS_KN_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE);
409 pool_mn_mem_L2 = lib_smem_falloc(blas_mem_handle, BLIS_MN_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE);
410
411 pool_mk_mem_L3 = lib_smem_malloc(blas_mem_handle, BLIS_MK_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE);
412 pool_kn_mem_L3 = lib_smem_malloc(blas_mem_handle, BLIS_KN_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE);
413 pool_mn_mem_L3 = lib_smem_malloc(blas_mem_handle, BLIS_MN_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE);
414
415 if( (pool_mk_mem_L1 == NULL)
416 ||(pool_kn_mem_L1 == NULL)
417 ||(pool_mn_mem_L1 == NULL)
418 ||(pool_mk_mem_L2 == NULL)
419 ||(pool_kn_mem_L2 == NULL)
420 ||(pool_mn_mem_L2 == NULL)
421 ||(pool_mk_mem_L3 == NULL)
422 ||(pool_kn_mem_L3 == NULL)
423 ||(pool_mn_mem_L3 == NULL) ) {
424 return(BLI_MEM_ALLOC_ERROR);
425 }
426 else {
427 bli_mem_init();
428 return(BLI_MEM_ALLOC_SUCCESS);
429 }
430}
431#endif /* BLIS_ENABLE_C66X_MEM_POOLS */
352 432
353void bli_mem_init() 433void bli_mem_init()
354{ 434{
diff --git a/src/ti/linalg/blis/frame/base/bli_mem.h b/src/ti/linalg/blis/frame/base/bli_mem.h
index b015f1d..1ea3e16 100644
--- a/src/ti/linalg/blis/frame/base/bli_mem.h
+++ b/src/ti/linalg/blis/frame/base/bli_mem.h
@@ -51,6 +51,13 @@ void bli_mem_init_pool( char* pool_mem,
51 void** block_ptrs, 51 void** block_ptrs,
52 pool_t* pool, 52 pool_t* pool,
53 membuf_t buf_type); 53 membuf_t buf_type);
54void bli_get_mem_sizes(size_t *smem_size_vfast, size_t *smem_size_fast,
55 size_t *smem_size_medium, size_t *smem_size_slow);
56int bli_scratch_mem_alloc();
57
58#define BLI_MEM_ALLOC_SUCCESS 0
59#define BLI_MEM_ALLOC_ERROR 1
60
54#else 61#else
55void bli_mem_init_pool( char* pool_mem, 62void bli_mem_init_pool( char* pool_mem,
56 siz_t block_size, 63 siz_t block_size,
diff --git a/src/ti/linalg/ticblas/src/ticblas.c b/src/ti/linalg/ticblas/src/ticblas.c
index 3e45b5f..d7795d5 100644
--- a/src/ti/linalg/ticblas/src/ticblas.c
+++ b/src/ti/linalg/ticblas/src/ticblas.c
@@ -29,18 +29,11 @@
29#include "../ticblas.h" 29#include "../ticblas.h"
30#include "blis.h" 30#include "blis.h"
31 31
32#define getNextMultiple(x, y) ( ( ((x)+(y)-1)/(y) )* (y) ) 32/*=============================================================================
33 33 * This file contains the CBLAS API Extension for TI-DSP. This extension is used
34#define BLAS_MEM_SIZE_VFAST ( getNextMultiple(BLIS_MK_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE) \ 34 * in the OpenCL DSP layer for ARM+DSP CBLAS library. It may also be used directly
35 + getNextMultiple(BLIS_KN_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE) \ 35 * by the user for DSP-only applications.
36 + getNextMultiple(BLIS_MN_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE) ) 36 *===========================================================================*/
37#define BLAS_MEM_SIZE_FAST ( getNextMultiple(BLIS_MK_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE) \
38 + getNextMultiple(BLIS_KN_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE) \
39 + getNextMultiple(BLIS_MN_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE) )
40#define BLAS_MEM_SIZE_MEDIUM ( getNextMultiple(BLIS_MK_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE) \
41 + getNextMultiple(BLIS_KN_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE) \
42 + getNextMultiple(BLIS_MN_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE) )
43#define BLAS_MEM_SIZE_SLOW (4804)
44 37
45/* Define memory descriptors for memory management */ 38/* Define memory descriptors for memory management */
46lib_memdscr_t blas_mem_vfast; 39lib_memdscr_t blas_mem_vfast;
@@ -56,23 +49,8 @@ lib_memdscr_t * blas_memdscr_tab[LIB_MEMTYPE_N] = {
56 &blas_mem_slow 49 &blas_mem_slow
57}; 50};
58 51
59// note these pointers must be filled if used functions
60char *pool_mk_mem_L1;
61char *pool_kn_mem_L1;
62char *pool_mn_mem_L1;
63
64char *pool_mk_mem_L2;
65char *pool_kn_mem_L2;
66char *pool_mn_mem_L2;
67
68char *pool_mk_mem_L3;
69char *pool_kn_mem_L3;
70char *pool_mn_mem_L3;
71
72extern void bli_mem_init();
73
74/*============================================================================== 52/*==============================================================================
75 * This function returns the address of the memory descriptor array 53 * This internal function returns the address of the memory descriptor array.
76 *============================================================================*/ 54 *============================================================================*/
77void * blasGetMemHandle() 55void * blasGetMemHandle()
78{ 56{
@@ -80,94 +58,61 @@ void * blasGetMemHandle()
80} /* blasGetMemHandle */ 58} /* blasGetMemHandle */
81 59
82/*============================================================================== 60/*==============================================================================
83 * It returns the size requirement of each of the 4 memory types defined in 61 * External API. Refer to ticblas.h for detailed documentation.
84 * the library framework.
85 *============================================================================*/ 62 *============================================================================*/
86void tiCblasGetSizes(size_t *smem_size_vfast, size_t *smem_size_fast, 63void tiCblasGetSizes(size_t *smem_size_vfast, size_t *smem_size_fast,
87 size_t *smem_size_medium, size_t *smem_size_slow) 64 size_t *smem_size_medium, size_t *smem_size_slow)
88{ 65{
89 *smem_size_vfast = BLAS_MEM_SIZE_VFAST; /* very fast scratch memory */ 66 /* get memory requirement information from BLIS */
90 *smem_size_fast = BLAS_MEM_SIZE_FAST; /* fast scratch memory */ 67 bli_get_mem_sizes(smem_size_vfast, smem_size_fast, smem_size_medium, smem_size_slow);
91 *smem_size_medium = BLAS_MEM_SIZE_MEDIUM; /* medium speed scratch memory */
92 *smem_size_slow = BLAS_MEM_SIZE_SLOW; /* slow scratch memory */
93/*
94 printf("BLIS_MK_POOL_SIZE_L1 is %d.\n", BLIS_MK_POOL_SIZE_L1);
95 printf("BLIS_KN_POOL_SIZE_L1 is %d.\n", BLIS_KN_POOL_SIZE_L1);
96 printf("BLIS_MN_POOL_SIZE_L1 is %d.\n", BLIS_MN_POOL_SIZE_L1);
97 printf("BLIS_MK_POOL_SIZE_L2 is %d.\n", BLIS_MK_POOL_SIZE_L2);
98 printf("BLIS_KN_POOL_SIZE_L2 is %d.\n", BLIS_KN_POOL_SIZE_L2);
99 printf("BLIS_MN_POOL_SIZE_L2 is %d.\n", BLIS_MN_POOL_SIZE_L2);
100 printf("BLIS_MK_POOL_SIZE_L3 is %d.\n", BLIS_MK_POOL_SIZE_L3);
101 printf("BLIS_KN_POOL_SIZE_L3 is %d.\n", BLIS_KN_POOL_SIZE_L3);
102 printf("BLIS_MN_POOL_SIZE_L3 is %d.\n", BLIS_MN_POOL_SIZE_L3);
103*/
104} /* tiCblasGetSizes */ 68} /* tiCblasGetSizes */
105 69
106/*============================================================================== 70/*==============================================================================
107 * It performs necessary initialization through library framework API in order 71 * External API. Refer to ticblas.h for detailed documentation.
108 * to do memory allocations.
109 *============================================================================*/ 72 *============================================================================*/
110int tiCblasInit(void * mem_vfast_base, size_t mem_vfast_size, 73int tiCblasInit(void * mem_vfast_base, size_t mem_vfast_size,
111 void * mem_fast_base, size_t mem_fast_size, 74 void * mem_fast_base, size_t mem_fast_size,
112 void * mem_medium_base, size_t mem_medium_size, 75 void * mem_medium_base, size_t mem_medium_size,
113 void * mem_slow_base, size_t mem_slow_size) 76 void * mem_slow_base, size_t mem_slow_size)
114{ 77{
78 size_t mem_vfast_size_req, mem_fast_size_req, mem_medium_size_req, mem_slow_size_req;
115 lib_memdscr_t **blas_mem_handle = blasGetMemHandle(); 79 lib_memdscr_t **blas_mem_handle = blasGetMemHandle();
116 80
81 /* Get the memory size requirements by BLIS */
82 bli_get_mem_sizes(&mem_vfast_size_req, &mem_fast_size_req,
83 &mem_medium_size_req, &mem_slow_size_req);
84
117 /* Verify supplied memories meet requirements */ 85 /* Verify supplied memories meet requirements */
118 if( ((mem_vfast_base == NULL) || (mem_vfast_size < BLAS_MEM_SIZE_VFAST) ) 86 if( ( (mem_vfast_base == NULL) || (mem_vfast_size < mem_vfast_size_req) )
119 ||((mem_fast_base == NULL) || (mem_fast_size < BLAS_MEM_SIZE_FAST) ) 87 ||( (mem_fast_base == NULL) || (mem_fast_size < mem_fast_size_req) )
120 ||((mem_medium_base == NULL) || (mem_medium_size < BLAS_MEM_SIZE_MEDIUM) ) 88 ||( (mem_medium_base == NULL) || (mem_medium_size < mem_medium_size_req) )
121 ||((mem_slow_base == NULL) || (mem_slow_size < BLAS_MEM_SIZE_SLOW) ) 89 ||( (mem_slow_base == NULL) || (mem_slow_size < mem_slow_size_req) )
122 ) { 90 ) {
123 return(TICBLAS_ERROR_NOMEM); 91 return(TICBLAS_ERROR_NOMEM);
124 } 92 }
125 else { 93 else {
94 /* Initialize all 4 types of scratch heaps */
126 lib_smem_vinit(blas_mem_handle, mem_vfast_base, mem_vfast_size); 95 lib_smem_vinit(blas_mem_handle, mem_vfast_base, mem_vfast_size);
127 lib_smem_finit(blas_mem_handle, mem_fast_base, mem_fast_size); 96 lib_smem_finit(blas_mem_handle, mem_fast_base, mem_fast_size);
128 lib_smem_minit(blas_mem_handle, mem_medium_base, mem_medium_size); 97 lib_smem_minit(blas_mem_handle, mem_medium_base, mem_medium_size);
129 lib_smem_sinit(blas_mem_handle, mem_slow_base, mem_slow_size); 98 lib_smem_sinit(blas_mem_handle, mem_slow_base, mem_slow_size);
130
131 pool_mk_mem_L1 = lib_smem_valloc(blas_mem_handle, BLIS_MK_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE);
132 pool_kn_mem_L1 = lib_smem_valloc(blas_mem_handle, BLIS_KN_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE);
133 pool_mn_mem_L1 = lib_smem_valloc(blas_mem_handle, BLIS_MN_POOL_SIZE_L1, BLIS_CACHE_LINE_SIZE);
134
135 pool_mk_mem_L2 = lib_smem_falloc(blas_mem_handle, BLIS_MK_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE);
136 pool_kn_mem_L2 = lib_smem_falloc(blas_mem_handle, BLIS_KN_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE);
137 pool_mn_mem_L2 = lib_smem_falloc(blas_mem_handle, BLIS_MN_POOL_SIZE_L2, BLIS_CACHE_LINE_SIZE);
138 99
139 pool_mk_mem_L3 = lib_smem_malloc(blas_mem_handle, BLIS_MK_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE); 100 /* Make a BLIS call to allocate scratch memory from very fast heap,
140 pool_kn_mem_L3 = lib_smem_malloc(blas_mem_handle, BLIS_KN_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE); 101 * fast heap and medium speed heap for BLIS. Slow memoris are allocated during
141 pool_mn_mem_L3 = lib_smem_malloc(blas_mem_handle, BLIS_MN_POOL_SIZE_L3, BLIS_CACHE_LINE_SIZE); 102 * BLIS compuation. Refer to blis/frame/base/bli_mem.c for detailed information.
142/* 103 */
143 printf("BLIS_MK_POOL_SIZE_L1 is %d, pool_mk_mem_L1 is 0x%x.\n", BLIS_MK_POOL_SIZE_L1, (unsigned int)pool_mk_mem_L1); 104 if(bli_scratch_mem_alloc() == BLI_MEM_ALLOC_ERROR) {
144 printf("BLIS_KN_POOL_SIZE_L1 is %d, pool_kn_mem_L1 is 0x%x.\n", BLIS_KN_POOL_SIZE_L1, (unsigned int)pool_kn_mem_L1); 105 return(TICBLAS_ERROR_MEMALLOC);
145 printf("BLIS_MN_POOL_SIZE_L1 is %d, pool_mn_mem_L1 is 0x%x.\n", BLIS_MN_POOL_SIZE_L1, (unsigned int)pool_mn_mem_L1); 106 }
146 printf("BLIS_MK_POOL_SIZE_L2 is %d, pool_mk_mem_L2 is 0x%x.\n", BLIS_MK_POOL_SIZE_L2, (unsigned int)pool_mk_mem_L2);
147 printf("BLIS_KN_POOL_SIZE_L2 is %d, pool_kn_mem_L2 is 0x%x.\n", BLIS_KN_POOL_SIZE_L2, (unsigned int)pool_kn_mem_L2);
148 printf("BLIS_MN_POOL_SIZE_L2 is %d, pool_mn_mem_L2 is 0x%x.\n", BLIS_MN_POOL_SIZE_L2, (unsigned int)pool_mn_mem_L2);
149 printf("BLIS_MK_POOL_SIZE_L3 is %d, pool_mk_mem_L3 is 0x%x.\n", BLIS_MK_POOL_SIZE_L3, (unsigned int)pool_mk_mem_L3);
150 printf("BLIS_KN_POOL_SIZE_L3 is %d, pool_kn_mem_L3 is 0x%x.\n", BLIS_KN_POOL_SIZE_L3, (unsigned int)pool_kn_mem_L3);
151 printf("BLIS_MN_POOL_SIZE_L3 is %d, pool_mn_mem_L3 is 0x%x.\n", BLIS_MN_POOL_SIZE_L3, (unsigned int)pool_mn_mem_L3);
152*/
153 if( (pool_mk_mem_L1 == NULL)
154 ||(pool_kn_mem_L1 == NULL)
155 ||(pool_mn_mem_L1 == NULL)
156 ||(pool_mk_mem_L2 == NULL)
157 ||(pool_kn_mem_L2 == NULL)
158 ||(pool_mn_mem_L2 == NULL)
159 ||(pool_mk_mem_L3 == NULL)
160 ||(pool_kn_mem_L3 == NULL)
161 ||(pool_mn_mem_L3 == NULL) ) {
162 return(TICBLAS_ERROR_MEMINIT);
163 }
164 else { 107 else {
165 bli_mem_init();
166 return(TICBLAS_SUCCESS); 108 return(TICBLAS_SUCCESS);
167 } 109 }
168 } 110 }
169} /* tiCblasInit */ 111} /* tiCblasInit */
170 112
113/*==============================================================================
114 * External API. Refer to ticblas.h for detailed documentation.
115 *============================================================================*/
171int tiCblasNew() 116int tiCblasNew()
172{ 117{
173 if(bli_init() == BLIS_SUCCESS) { 118 if(bli_init() == BLIS_SUCCESS) {
@@ -178,6 +123,9 @@ int tiCblasNew()
178 } 123 }
179} 124}
180 125
126/*==============================================================================
127 * External API. Refer to ticblas.h for detailed documentation.
128 *============================================================================*/
181int tiCblasDelete() 129int tiCblasDelete()
182{ 130{
183 if(bli_finalize() == BLIS_SUCCESS) { 131 if(bli_finalize() == BLIS_SUCCESS) {
diff --git a/src/ti/linalg/ticblas/ticblas.h b/src/ti/linalg/ticblas/ticblas.h
index 18b7a12..813da18 100644
--- a/src/ti/linalg/ticblas/ticblas.h
+++ b/src/ti/linalg/ticblas/ticblas.h
@@ -31,6 +31,13 @@
31#include <stddef.h> 31#include <stddef.h>
32 32
33/** @defgroup ti_cblas_api CBLAS API Extension for TI-DSP 33/** @defgroup ti_cblas_api CBLAS API Extension for TI-DSP
34 * @brief This extension contains the initialization and finalization APIs
35 * for proper usage of CBLAS optimized for TI's C66x DSP.
36 * - for ARM+DSP applications with CBLAS API on ARM (host), users
37 * do not need to use this extension.
38 * - for DSP-only applications, uers will need to use this extension
39 * to set up before making standard CBLAS calls in their programs
40 * running on the DSP, and to tear down before the program exits.
34 * @{ 41 * @{
35 */ 42 */
36/** @} */ 43/** @} */
@@ -42,11 +49,9 @@
42/*@{*/ 49/*@{*/
43#define TICBLAS_SUCCESS (0) /**< Success. No error. */ 50#define TICBLAS_SUCCESS (0) /**< Success. No error. */
44#define TICBLAS_ERROR_NOMEM (1) /**< Failure. Provided memory is not enough. */ 51#define TICBLAS_ERROR_NOMEM (1) /**< Failure. Provided memory is not enough. */
45#define TICBLAS_ERROR_MEMINIT (2) /**< Failure. Memory init error. */ 52#define TICBLAS_ERROR_MEMALLOC (2) /**< Failure. Memory allocation error. */
46#define TICBLAS_ERROR_MEMCFG (3) /**< Failure. L1D/L2 config error. */ 53#define TICBLAS_ERROR_NEW (3) /**< Failure. CBLAS creation error. */
47#define TICBLAS_ERROR_NEW (4) /**< Failure. tiCblasnew error. */ 54#define TICBLAS_ERROR_DELETE (4) /**< Failure. CBLAS deletion error. */
48#define TICBLAS_ERROR_DELETE (5) /**< Failure. tiCblasDelete error. */
49#define TICBLAS_ERROR_MEMRECFG (6) /**< Failure. L1D/L2 reconfig error. */
50/*@}*/ 55/*@}*/
51/** @} */ 56/** @} */
52 57
@@ -67,7 +72,7 @@
67 * based on speed: 72 * based on speed:
68 * - very fast memory, e.g. L1D; 73 * - very fast memory, e.g. L1D;
69 * - fast memory, e.g. L2; 74 * - fast memory, e.g. L2;
70 * - medium memory, e.g. L3/MSMC; 75 * - medium speed memory, e.g. L3/MSMC;
71 * - slow memory, e.g. DDR. 76 * - slow memory, e.g. DDR.
72 * 77 *
73 * @param[out] smem_size_vfast size of very fast shared memory 78 * @param[out] smem_size_vfast size of very fast shared memory
@@ -81,25 +86,34 @@ void tiCblasGetSizes(size_t *smem_size_vfast, size_t *smem_size_fast,
81 86
82/** 87/**
83 * @ingroup ti_cblas_api 88 * @ingroup ti_cblas_api
84 * @brief Function tiCblasNew() creates an instance for CBLAS. 89 * @brief Function tiCblasNew() creates and initializes global structures
90 * for CBLAS.
85 * 91 *
86 * @remarks tiCblasNew() MUST be called before tiCblasInit(). 92 * @remarks tiCblasNew() MUST be called before tiCblasInit().
87 * 93 *
88 * @retval TICBLAS_SUCCESS @copydoc TICBLAS_SUCCESS 94 * @retval TICBLAS_SUCCESS @copydoc TICBLAS_SUCCESS
89 * @retval TICBLAS_ERROR @copydoc TICBLAS_ERROR 95 * @retval TICBLAS_ERROR_NEW @copydoc TICBLAS_ERROR_NEW
90 */ 96 */
91int tiCblasNew(); 97int tiCblasNew();
92 98
93/** 99/**
94 * @ingroup ti_cblas_api 100 * @ingroup ti_cblas_api
95 * @brief Function tiCblasInit() performs heap initialization for CBLAS 101 * @brief Function tiCblasInit() performs heap initialization for TI CBLAS
96 * to do dynamic memory allocations. 102 * to do dynamic memory allocations.
97 * 103 *
98 * @remarks Users must allocate memories according to the requirements 104 * @remarks Users must allocate memories according to the requirements
99 * given by tiCblasGetSizes() and pass the base and size to this 105 * given by tiCblasGetSizes() and pass the bases and sizes to this
100 * function. 106 * function.
101 * 107 *
102 * @remarks tiCblasInit() must NOT be called before tiCblasNew(). 108 * @remarks tiCblasNew() MUST be called before tiCblasInit() can be called.
109 *
110 * @remarks The provided memory can be shared with other modules and thus its
111 * content do not need to be preserved from call to call. If the
112 * memory bases do not change from call to call, this function only
113 * needs to be called just once at boot time. However, if it cannot
114 * be guaranteed that memory bases stay the same, this function
115 * needs to be called every time a level 3 CBLAS function is called
116 * on DSP.
103 * 117 *
104 * @param[in] mem_vfast_base base of very fast shared memory 118 * @param[in] mem_vfast_base base of very fast shared memory
105 * @param[in] mem_vfast_size size of very fast shared memory 119 * @param[in] mem_vfast_size size of very fast shared memory
@@ -110,8 +124,9 @@ int tiCblasNew();
110 * @param[in] mem_slow_base base of slow shared memory 124 * @param[in] mem_slow_base base of slow shared memory
111 * @param[in] mem_slow_size size of slow shared memory 125 * @param[in] mem_slow_size size of slow shared memory
112 * 126 *
113 * @retval TICBLAS_SUCCESS @copydoc TICBLAS_SUCCESS 127 * @retval TICBLAS_SUCCESS @copydoc TICBLAS_SUCCESS
114 * @retval TICBLAS_ERROR @copydoc TICBLAS_ERROR 128 * @retval TICBLAS_ERROR_NOMEM @copydoc TICBLAS_ERROR_NOMEM
129 * @retval TICBLAS_ERROR_MEMALLOC @copydoc TICBLAS_ERROR_MEMALLOC
115 */ 130 */
116int tiCblasInit(void * mem_vfast_base, size_t mem_vfast_size, 131int tiCblasInit(void * mem_vfast_base, size_t mem_vfast_size,
117 void * mem_fast_base, size_t mem_fast_size, 132 void * mem_fast_base, size_t mem_fast_size,
@@ -120,11 +135,11 @@ int tiCblasInit(void * mem_vfast_base, size_t mem_vfast_size,
120 135
121/** 136/**
122 * @ingroup ti_cblas_api 137 * @ingroup ti_cblas_api
123 * @brief Function tiCblasDelete() deletes the instance of CBLAS created by 138 * @brief Function tiCblasDelete() deletes global structures and frees memories
124 * tiCblasNew(). 139 * of CBLAS created by tiCblasNew().
125 * 140 *
126 * @retval TICBLAS_SUCCESS @copydoc TICBLAS_SUCCESS 141 * @retval TICBLAS_SUCCESS @copydoc TICBLAS_SUCCESS
127 * @retval TICBLAS_ERROR @copydoc TICBLAS_ERROR 142 * @retval TICBLAS_ERROR_DELETE @copydoc TICBLAS_ERROR_DELETE
128 */ 143 */
129int tiCblasDelete(); 144int tiCblasDelete();
130 145