This patch fixes logic error warnings of the type "called C++ object
pointer is null" that were emitted by Clang Static Analyzer on the
following files:
- lib/Transforms/Scalar/TailRecursionElimination.cpp,
- lib/Transforms/Scalar/StructurizeCFG.cpp,
- lib/Transforms/Scalar/ScalarReplAggregates.cpp,
- lib/Target/X86/AsmParser/X86AsmParser.cpp,
- lib/Target/Hexagon/RDFGraph.cpp,
- lib/Target/Hexagon/HexagonCFGOptimizer.cpp,
- lib/Target/ARM/Thumb2SizeReduction.cpp,
- lib/Target/ARM/MCTargetDesc/ARMMachObjectWriter.cpp,
- lib/Target/ARM/ARMFrameLowering.cpp,
- lib/CodeGen/ScheduleDAGInstrs.cpp,
- lib/Bitcode/Writer/BitcodeWriter.cpp.
Signed-off-by: Apelete Seketeli <apelete@seketeli.net>
I think this is so obvious that we don't even need the assert. We will get a crash in MI->isDebugValue() anyway when MI is nullptr.