Font Size: a A A

The Design And Implementation Of LLVM-based Backend For Model Machine

Posted on:2021-03-12Degree:MasterType:Thesis
Country:ChinaCandidate:Y L WangFull Text:PDF
GTID:2428330632962906Subject:Computer technology
Abstract/Summary:PDF Full Text Request
In the emerging fields such as machine learning and artificial intelligence,the customization of CPU,which design hardware and software in a collaborative demand-led way,can remarkably improve the performance,efficiency and security of the applications.However,if the customized CPU lacks the support of compilers,it will not be able to execute the application,which means the CPU has no "soul".Therefore,it is of great significance to develop the compiler for it quickly so as to open up the hardware and software facilities.Most of the current compiler research,however,only focus on optimization,while the backend area of generating code for a specific target has not received considerable attention.To this end,this paper explores and studies compiler backend porting technology comprehensively and thoroughly.This paper compares the advantages and disadvantages of two compiler frameworks which named GCC and LLVM in backend porting,and reviews the related work and worldwide research status.Under the background of outdated official documents and work,this paper analyzes the back-end code generation and porting mechanism of LLVM in detail based on the latest code branch which is LLVM 10.In this aspect,this paper is the most up-to-date and detailed research work at present.In order to limit the complexity of the back-end,so that the relevant developers won't be lost in the machine and protocol details.Under the premise of ensuring enough functionality to allow complex program execution,this paper first designs the CPU instruction set architecture and defines the corresponding application binary interface,then add support for UPT back-end based on LLVM.At last,this paper uses the test framework to verify the correctness of the compiler,which shows the standard development process and reference specifications in the backend porting.Source code can be found at https://github.com/Azurewyl/llvm_upt.
Keywords/Search Tags:back-end support, code generation, llvm, tablegen
PDF Full Text Request
Related items