소스 검색

Avoid spilling stack slots... to stack slots.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@23478 91177308-0d34-0410-b5e6-96231b3b80d8
Chris Lattner 20 년 전
부모
커밋
4531371960
1개의 변경된 파일6개의 추가작업 그리고 0개의 파일을 삭제
  1. 6 0
      lib/Transforms/Utils/LowerInvoke.cpp

+ 6 - 0
lib/Transforms/Utils/LowerInvoke.cpp

@@ -334,6 +334,12 @@ splitLiveRangesLiveAcrossInvokes(std::vector<InvokeInst*> &Invokes) {
           cast<Instruction>(Inst->use_back())->getParent() == BB &&
           !isa<PHINode>(Inst->use_back())) continue;
       
+      // If this is an alloca in the entry block, it's not a real register
+      // value.
+      if (AllocaInst *AI = dyn_cast<AllocaInst>(Inst))
+        if (isa<ConstantInt>(AI->getArraySize()) && BB == F->begin())
+          continue;
+      
       // Avoid iterator invalidation by copying users to a temporary vector.
       std::vector<Instruction*> Users;
       for (Value::use_iterator UI = Inst->use_begin(), E = Inst->use_end();