]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - dense-linear-algebra-libraries/linalg.git/blob - readme.txt
Addressing issues found by Klockwork
[dense-linear-algebra-libraries/linalg.git] / readme.txt
1 Build instructions of LINALG component:
3 1.--------- Set environment variables ---------
5 Following environment vaialbes must be set in order to build DSP-only LINALG (version numbers are used as examples):
7 export CGTROOT="<TI_CGT_INSTALLATION_ROOT>/cgt-c6x"
8 export PDK_DIR="<COMPONENTS_INSTALLATION_ROOT>/pdk_c667x_2_0_1"
9 export FC_DIR="<COMPONENTS_INSTALLATION_ROOT>/framework_components_3_40_01_04"
10 export XDAIS_DIR="<COMPONENTS_INSTALLATION_ROOT>/xdais_7_24_00_04"
11 export BIOS_DIR="<COMPONENTS_INSTALLATION_ROOT>/bios_6_45_01_29"
12 export OMP_DIR="<COMPONENTS_INSTALLATION_ROOT>/openmp_dsp_c667x_2_02_00_02"
13 export XDC_DIR="<COMPONENTS_INSTALLATION_ROOT>/xdctools_3_32_00_06_core"
14 export IPC_DIR="<COMPONENTS_INSTALLATION_ROOT>/ipc_3_42_00_02"
15 export EDMA3_DIR="<COMPONENTS_INSTALLATION_ROOT>/edma3_lld_02_12_01_23"
16 export LIBARCH_DIR="<COMPONENTS_INSTALLATION_ROOT>/libarch_1_0_0_0"
17 export PATH=<TI_CGT_INSTALLATION_ROOT>/cgt-c6x/bin:$PATH
19 Additional environment variables must be set to build ARM+DSP LINALG:
20 export TI_OCL_INSTALL_DIR="<PSDK_INSTALLATION_ROOT>/linux-devkit/sysroots/cortexa15hf-vfp-neon-linux-gnueabi/usr/share/ti/opencl"
21 export TI_OCL_CGT_INSTALL="<PSDK_INSTALLATION_ROOT>/linux-devkit/sysroots/x86_64-arago-linux/usr/share/ti/cgt-c6x"
22 export TARGET_ROOTDIR="<PSDK_INSTALLATION_ROOT>/linux-devkit/sysroots/cortexa15hf-vfp-neon-linux-gnueabi"
24 2.--------- Build LINALG source code and make it a RTSC package ---------
26 From the root folder of LINALG, the build command is:
27 make -f build/Makefile MEM_MODEL=<memory_model_name> TARGET=<target_name> LIBOS=<os_name>
29 where:
30    1) <memory_model_name> must be one of Large, Medium, or Small
31    2) <target_name> must be one of SOC_K2H, SOC_C6678, or SOC_AM572x
32    3) <os_name> must be one of LIB_OPENCL or LIB_RTOS
34 Examples:
35 1) to build LINALG Large memory model for K2H in OpenCL environment, type:
36 make -f build/Makefile MEM_MODEL=Large TARGET=SOC_K2H LIBOS=LIB_OPENCL
38 2) to build LINALG Medium memory model for C6678 in RTOS environment, type:
39 make -f build/Makefile MEM_MODEL=Medium TARGET=SOC_C6678 LIBOS=LIB_RTOS
41 3.--------- Build LINALG examples ---------
43 1) Install the LINALG package generated in previous step by unzipping the package file in folder ./exports:
44    - linalg_<version>.zip 
45    
46 2) Add one more environment variable to point to LINALG's path:
47 export LINALG_DIR="<LINALG installation folder>"
49 3) Go to examples folder and use build command:
50    1) For ARM+DSP: cd arm+dsp; make
51    1) For DSP-only: cd dsponly; make TARGET=<target_name> LIBOS=LIB_RTOS
52       where: <target_name> must be one of SOC_K2H, SOC_C6678, or SOC_AM572x
54 4.--------- Build BLIS test suite for ARM+DSP ---------
55 # BLIS ARM+DSP test suite Makefile links ARM+DSP lib and ARM BLIS lib from inside src folder
56 # BLIS_ARM_LIB_DIR = ../install/arm/lib
57 # BLIS_BLAS_ACC_LIB_DIR =  ../../blasblisacc/lib
58 # BLIS_LIB       := $(BLIS_BLAS_ACC_LIB_DIR)/libcblas_armplusdsp.a $(BLIS_ARM_LIB_DIR)/libblis.a -lOpenCL -locl_util -lstdc++ -lrt -lpthread 
59 # Use same environment variables as building the examles.
60 cd src/ti/linalg
61 make BLIStest       
63 5.--------- Build BLIS test suite for DSP-only ---------
64 # BLIS DSP test suite shares same make process defined in examples/dsponly/common/Makefile.common. It searches include path and lib path
65 # in RTSC packaging style: $(LINALG_DIR)/packages/ti/linalg. Therefore, to build BLIS test suite, LINALG needs to be installed first.
66 # Use same environment variables as building the examles.
67 cd src/ti/linalg
68 make cleanDSPlibs MEM_MODEL=Medium TARGET=SOC_C6678 LIBOS=LIB_RTOS
69 cd -
70 rm -r exports
71 make -f build/Makefile MEM_MODEL=Medium TARGET=SOC_C6678 LIBOS=LIB_RTOS
72 rm -r ~/ti/linalg_1_2_0_0_rtos/*
73 cp -r exports/linalg_1_2_0_0/* ~/ti/linalg_1_2_0_0_rtos
74 cd src/ti/linalg/blis/testsuite/dsponly
75 make TARGET=SOC_C6678