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