mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-21 18:24:23 +00:00
Expose new GCSE pass
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2339 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -24,6 +24,7 @@
|
|||||||
#include "llvm/Transforms/IPO/PoolAllocate.h"
|
#include "llvm/Transforms/IPO/PoolAllocate.h"
|
||||||
#include "llvm/Transforms/Scalar/DCE.h"
|
#include "llvm/Transforms/Scalar/DCE.h"
|
||||||
#include "llvm/Transforms/Scalar/ConstantProp.h"
|
#include "llvm/Transforms/Scalar/ConstantProp.h"
|
||||||
|
#include "llvm/Transforms/Scalar/GCSE.h"
|
||||||
#include "llvm/Transforms/Scalar/IndVarSimplify.h"
|
#include "llvm/Transforms/Scalar/IndVarSimplify.h"
|
||||||
#include "llvm/Transforms/Scalar/InstructionCombining.h"
|
#include "llvm/Transforms/Scalar/InstructionCombining.h"
|
||||||
#include "llvm/Transforms/Scalar/PromoteMemoryToRegister.h"
|
#include "llvm/Transforms/Scalar/PromoteMemoryToRegister.h"
|
||||||
@ -38,7 +39,7 @@
|
|||||||
// Opts enum - All of the transformations we can do...
|
// Opts enum - All of the transformations we can do...
|
||||||
enum Opts {
|
enum Opts {
|
||||||
// Basic optimizations
|
// Basic optimizations
|
||||||
dce, die, constprop, inlining, constmerge, strip, mstrip, mergereturn,
|
dce, die, constprop, gcse, inlining, constmerge, strip, mstrip, mergereturn,
|
||||||
|
|
||||||
// Miscellaneous Transformations
|
// Miscellaneous Transformations
|
||||||
raiseallocs, funcresolve, cleangcc, lowerrefs,
|
raiseallocs, funcresolve, cleangcc, lowerrefs,
|
||||||
@ -73,6 +74,7 @@ struct {
|
|||||||
{ dce , createDeadCodeEliminationPass },
|
{ dce , createDeadCodeEliminationPass },
|
||||||
{ die , createDeadInstEliminationPass },
|
{ die , createDeadInstEliminationPass },
|
||||||
{ constprop , createConstantPropogationPass },
|
{ constprop , createConstantPropogationPass },
|
||||||
|
{ gcse , createGCSEPass },
|
||||||
{ inlining , createFunctionInliningPass },
|
{ inlining , createFunctionInliningPass },
|
||||||
{ constmerge , createConstantMergePass },
|
{ constmerge , createConstantMergePass },
|
||||||
{ strip , createSymbolStrippingPass },
|
{ strip , createSymbolStrippingPass },
|
||||||
@ -117,6 +119,7 @@ cl::EnumList<enum Opts> OptimizationList(cl::NoFlags,
|
|||||||
clEnumVal(dce , "Dead Code Elimination"),
|
clEnumVal(dce , "Dead Code Elimination"),
|
||||||
clEnumVal(die , "Dead Instruction Elimination"),
|
clEnumVal(die , "Dead Instruction Elimination"),
|
||||||
clEnumVal(constprop , "Simple constant propogation"),
|
clEnumVal(constprop , "Simple constant propogation"),
|
||||||
|
clEnumVal(gcse , "Global Common Subexpression Elimination"),
|
||||||
clEnumValN(inlining , "inline", "Function integration"),
|
clEnumValN(inlining , "inline", "Function integration"),
|
||||||
clEnumVal(constmerge , "Merge identical global constants"),
|
clEnumVal(constmerge , "Merge identical global constants"),
|
||||||
clEnumVal(strip , "Strip symbols"),
|
clEnumVal(strip , "Strip symbols"),
|
||||||
|
Reference in New Issue
Block a user