From: Dávid Bolvanský Date: Sun, 3 Nov 2019 19:31:05 +0000 (+0100) Subject: Revert "[InstructionCombining] Fixed null check after dereferencing warning. NFCI." X-Git-Tag: llvmorg-11-init~5122 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5b37c018d5c9add833f9a40b870345e2108614e6;p=platform%2Fupstream%2Fllvm.git Revert "[InstructionCombining] Fixed null check after dereferencing warning. NFCI." This reverts commit 8308187fd9bfa08ffad0a636d4dd1d25e7de5a76. This exposed a bug. --- diff --git a/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp b/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp index 897c29e..c4f9be0 100644 --- a/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp +++ b/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp @@ -1724,7 +1724,6 @@ Instruction *InstCombiner::visitGetElementPtrInst(GetElementPtrInst &GEP) { // The first two arguments can vary for any GEP, the rest have to be // static for struct slots - assert(CurTy && "No current type?"); if (J > 1 && CurTy->isStructTy()) return nullptr;