From 540d63cbc75fae1c6187e97b995e5a52e7d1ad50 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Wed, 8 May 2002 22:19:01 +0000 Subject: [PATCH] Add expr reassociation pass prototype git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2558 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/Transforms/Scalar.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/include/llvm/Transforms/Scalar.h b/include/llvm/Transforms/Scalar.h index 144db236709..ba8b90ca47d 100644 --- a/include/llvm/Transforms/Scalar.h +++ b/include/llvm/Transforms/Scalar.h @@ -110,6 +110,16 @@ Pass *createInstructionCombiningPass(); Pass *createPromoteMemoryToRegister(); +//===----------------------------------------------------------------------===// +// +// This pass reassociates commutative expressions in an order that is designed +// to promote better constant propogation, GCSE, LICM, PRE... +// +// For example: 4 + (x + 5) -> x + (4 + 5) +// +Pass *createReassociatePass(); + + //===----------------------------------------------------------------------===// // // These functions removes symbols from functions and modules.