diff options
| author | Dan Gohman <gohman@apple.com> | 2010-06-04 00:18:06 +0000 |
|---|---|---|
| committer | Dan Gohman <gohman@apple.com> | 2010-06-04 00:18:06 +0000 |
| commit | ef325d90a6e1032a2ec7950abfa0366d9ee66ef5 (patch) | |
| tree | 58deb35af71772736579323e0ec58d494daddfa3 | |
| parent | 2f61019ceb041eaef447b5b358a4c33aff89a48d (diff) | |
| download | external_llvm-ef325d90a6e1032a2ec7950abfa0366d9ee66ef5.zip external_llvm-ef325d90a6e1032a2ec7950abfa0366d9ee66ef5.tar.gz external_llvm-ef325d90a6e1032a2ec7950abfa0366d9ee66ef5.tar.bz2 | |
No need to special-case structs here; structs are first-class now.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@105442 91177308-0d34-0410-b5e6-96231b3b80d8
| -rw-r--r-- | tools/bugpoint/ExtractFunction.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/tools/bugpoint/ExtractFunction.cpp b/tools/bugpoint/ExtractFunction.cpp index 7808de5..e6a98d9 100644 --- a/tools/bugpoint/ExtractFunction.cpp +++ b/tools/bugpoint/ExtractFunction.cpp @@ -73,9 +73,7 @@ Module *BugDriver::deleteInstructionFromProgram(const Instruction *I, Instruction *TheInst = RI; // Got the corresponding instruction! // If this instruction produces a value, replace any users with null values - if (TheInst->getType()->isStructTy()) - TheInst->replaceAllUsesWith(UndefValue::get(TheInst->getType())); - else if (TheInst->getType() != Type::getVoidTy(I->getContext())) + if (TheInst->getType() != Type::getVoidTy(I->getContext())) TheInst->replaceAllUsesWith(Constant::getNullValue(TheInst->getType())); // Remove the instruction from the program. |
