From 04f8e06696c40cadadb68248b320dec822eb5f7a Mon Sep 17 00:00:00 2001 From: Andrew Kaylor Date: Fri, 27 May 2016 22:56:49 +0000 Subject: Update the stack coloring pass to remove lifetime intrinsics in the optnone/opt-bisect skip case. Differential Revision: http://reviews.llvm.org/D20453 llvm-svn: 271068 --- llvm/lib/CodeGen/StackColoring.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'llvm/lib/CodeGen') diff --git a/llvm/lib/CodeGen/StackColoring.cpp b/llvm/lib/CodeGen/StackColoring.cpp index 281836e909d..17c01dc3c3f 100644 --- a/llvm/lib/CodeGen/StackColoring.cpp +++ b/llvm/lib/CodeGen/StackColoring.cpp @@ -963,9 +963,6 @@ void StackColoring::expungeSlotMap(DenseMap &SlotRemap, } bool StackColoring::runOnMachineFunction(MachineFunction &Func) { - if (skipFunction(*Func.getFunction())) - return false; - DEBUG(dbgs() << "********** Stack Coloring **********\n" << "********** Function: " << ((const Value*)Func.getFunction())->getName() << '\n'); @@ -1005,7 +1002,8 @@ bool StackColoring::runOnMachineFunction(MachineFunction &Func) { // Don't continue because there are not enough lifetime markers, or the // stack is too small, or we are told not to optimize the slots. - if (NumMarkers < 2 || TotalSize < 16 || DisableColoring) { + if (NumMarkers < 2 || TotalSize < 16 || DisableColoring || + skipFunction(*Func.getFunction())) { DEBUG(dbgs()<<"Will not try to merge slots.\n"); return removeAllMarkers(); } -- cgit v1.2.3