Posts

Reflection on the SPO600 Project

  Reflection: Hi everyone, I am writing a reflection on SPO600 project. This project was divided into three 3 stages. In these stages, we had to develop proof-of concept tool which is used to automate the process for setup and building function using ifunc capability to use best SIMD implementation for auto-vectorization. To learn about auto-vectorization, visit this link . Here are links to stage 1 , stage 2 and stage 3 . Throughout this whole project I learned a lots of things. First of all, I learned about auto-vectorization using each of SIMD implementation - Advance SIMD, SVE and SVE2. I learned about each of these in depth and how to use them and build function using these. Then another major thing I learned about was ifunc, I learned how to write a resolver function which can choose one version of function during the run time. I learned to update the ifunc in c language and working mechanism of this resolver function. Then by putting these pieces together, I came to know to use

Testing for stage III for project

Image
Hi Everyone, in this blog I am going to demonstrate how to use or test the final version of tool for stage III. To read about the stage III please visit this link . You can get the tool at  https://github.com/NishanSingh6/SPO600-Project To successfully run the final version of tool, both tool.py and template.txt must be present in the same directory. Do not change the content of template.txt. This tool have some permitted limitations: This tool only operates on aarch64 systems There are three targets of interest: machines with advanced SIMD, SVE, and SVE2 capabilities There are only two input source files, one containing main (and optionally other functions) (main.c) and one containing a function to be optimized (function.c) Only function.c is built multiple times for different SIMD implementations The file function.c may only contain one function How to use: Firstly use the following command to clone the tool. git clone https://github.com/NishanSingh6/SPO600-Project By using following

Final Implementation of SPO600 Project - Stage III

Introduction: Hi everyone, I am writing this blog about the stage III of my SPO600 Project. This project is about developing proof-of-concept tool to build the function using auto-vectorization. This is a follow up of stage II, in which I implemented initial version of the tool. The tool is written in python. In Stage II, I was able to develop the tool which was able to successfully produced the working output binary file. But stage II had many bugs and limitations, in this final stage of the project, I fixed those bugs and solved those limitations. This is the final version of the tool which successfully builds the function. To learn more about the project or about the stage II implementation, please revisit my previous blog on this link . Access to tool: I updated the final version of tool on my previous github repository, which previously hosted stage II implementation. You can get the tool at  https://github.com/NishanSingh6/SPO600-Project . The tool is released under GPL version 2

Testing for Stage II for Project

Image
Hi Everyone, I am writing this blog in continuity of my previous blog about Project Stage II. You can read my previous blog on this link . In this blog I am going to demonstrate how to use the tool and test it. You can get the tool from  https://github.com/NishanSingh6/SPO600-Project . But before using this tool please read the following conditions and limitations of using this tool at its current version which is v1.0. Limitations: This is initial implementation of the tool, due to which it have several bugs and limitations. I will fix these limitations and bugs in the final version of the tool in Stage III of project. Following are the limitations and conditions: The very first limitation of the tool is that is accepts only two arguments. First argument must be main.c file and second argument must be .c file which contains the  function  which needs to be vectorized. This tool  does not have proper exception handling  or any input data validation, due to which if any arguments are in

Initial Implementation of SPO600 Project - Stage II

Introduction:   Hello everyone, I am writing this blog about the stage II of my SPO600 Project. In this stage, I implemented a initial version of proof-of-concept tool to setup and build the function using auto-vectorization. This tool create three version of the function which is provided as second argument. Then this tool uses ifunc capability to choose the best method while building the main output file from these functions. To learn more about the purpose or concept of the tool please read my previous blog on this link .  I wrote the tool in python, while the ifunc resolver function itself is in the c language. I will explain the working mechanism and limitations of tool along with procedure to test the tool in this blog. Access to Tool: Tool is hosted at a github repository. You can get the tool at  https://github.com/NishanSingh6/SPO600-Project . Tool is licensed under the terms of the GPL version 2. There are two main files of the tool: tool.py: this is the main tool which is wr

Plan for the SP0600 Project - Stage 1

Introduction: Hello Everyone, In this blog I am going to discuss the stage 1 about my project for SP0600. The Stage 1 is about the planning of the project. In this project we have to create a proof-of-concept tool to build functions with the use of automatic vectorization. Automatic vectorization have three major implementation of SIMD instructions for AArch64, Advanced SIMD, SVE and SVE2. Some modern gcc compiler have option to choose from one of these implementations at runtime using the function ifunc . However, ifunc requires additional set up and configurations by software developer before use. To learn more about automatic vectorization please visit this link . To learn about ifunc please visit this link . For more brief detail about the ASIMD, SVE and SVE2 please read my previous blog on this link . The primary focus of this project is to eliminate all the setup done by software developer and automate the process by writing a tool. This tool will enable to developer to build thr