LLVM 3.9 发布,编译器架构

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了LLVM 3.9 发布,编译器架构相关的知识,希望对你有一定的参考价值。

LLVM 3.9 发布了,LLVM 是 Low Level Virtual Machine (低级虚拟机)的简称,这个库提供了与编译器相关的支持,可以作为多种语言编译器的后台来使用。能够进行程序语言的编译期优化、链接优化、在线编译优化、 代码生成。LLVM的项目是一个模块化和可重复使用的编译器和工具技术的集合(app开发ty300.com)。LLVM是伊利诺伊大学的一个研究项目,提供一个现代化的,基于SSA的编 译策略能够同时支持静态和动态的任意编程语言的编译目标(入门教程qkxue.net)。自那时以来,已经成长为LLVM的主干项目,由不同的子项目组成,其中许多正在生产中使用的各种 商业和开源的项目,以及被广泛用于学术研究。

该版本改进记录如下:

The LLVMContext gains a new runtime check (see LLVMContext::discardValueNames()) that can be set to discard Value names (other than GlobalValue). This is intended to be used in release builds by clients that are interested in saving CPU/memory as much as possible.
There is no longer a “global context” available in LLVM, except for the C API.
The autoconf build system has been removed in favor of CMake. LLVM 3.9 requires CMake 3.4.3 or later to build. For information about using CMake please see the documentation on Building LLVM with CMake. For information about the CMake language there is also a CMake Primer document available.
C API functions LLVMParseBitcode, LLVMParseBitcodeInContext, LLVMGetBitcodeModuleInContext and LLVMGetBitcodeModule having been removed. LLVMGetTargetMachineData has been removed (use LLVMGetDataLayout instead).
The C API function LLVMLinkModules has been removed.
The C API function LLVMAddTargetData has been removed.
The C API function LLVMGetDataLayout is deprecated in favor of LLVMGetDataLayoutStr.
The C API enum LLVMAttribute and associated API is deprecated in favor of the new LLVMAttributeRef API. The deprecated functions are LLVMAddFunctionAttr, LLVMAddTargetDependentFunctionAttr, LLVMRemoveFunctionAttr, LLVMGetFunctionAttr, LLVMAddAttribute, LLVMRemoveAttribute, LLVMGetAttribute, LLVMAddInstrAttribute, LLVMRemoveInstrAttribute and LLVMSetInstrParamAlignment.
TargetFrameLowering::eliminateCallFramePseudoInstr now returns an iterator to the next instruction instead of void. Targets that previously did MBB.erase(I); return; now probably want return MBB.erase(I);.
SelectionDAGISel::Select now returns void. Out-of-tree targets will need to be updated to replace the argument node and remove any dead nodes in cases where they currently return an SDNode * from this interface.
Added the MemorySSA analysis, which hopes to replace MemoryDependenceAnalysis. It should provide higher-quality results than MemDep, and be algorithmically faster than MemDep. Currently, GVNHoist (which is off by default) makes use of MemorySSA.
The minimum density for lowering switches with jump tables has been reduced from 40% to 10% for functions which are not marked optsize (that is, compiled with -Os).
了解更多改进信息,查看完整发布说明

以上是关于LLVM 3.9 发布,编译器架构的主要内容,如果未能解决你的问题,请参考以下文章

LLVM 5.0.1 发布,编译器架构

LLVM编译器基础 架构

IOS逆向-LLVM代码混淆

英特尔为其C/C++编译器全面采用LLVM

英特尔采用 LLVM 作为最新 C/C++ 编译器

英特尔为其 C/C++ 编译器全面采用 LLVM