AIE Auto Vectorize Tool¶
VSI has an auto vectorizer to help optimize user code for running on the AIE processors.
Installing AIE Auto Vectorize Tool¶
- Download the AIE auto vectorize tool from Here
- Untar the vsi_llvm.tgz
tar -xvf vsi_llvm.tgz
- Open clang_cmd.sh, in the following path:
<VSI_LLVM Install Path>/llvm-project/vsi-aiebe/test/vectorize_tests/
and modify all the llvm-exec path to<VSI_LLVM Install Path>/llvm-exec
Running the Auto Vectorizer¶
- To run the auto vectorizer execute the following command:
./clang_cmd.sh -Os <<file>> <<func>>
where-Os
is the compiler flag for size optimization<<file>>
is the name of the c++ file without extension<<func>>
is the name of top level function in the c++ code
- AIE auto Vectorize tool will generate the vectorized code with “.cpp” extension.