Fix a couple of redundant conditional expressions (PR27283, PR28282)

llvm-svn: 265987
This commit is contained in:
Hans Wennborg 2016-04-11 20:35:01 +00:00
parent 8396f72f7b
commit e9134897f4
2 changed files with 3 additions and 3 deletions

View File

@ -520,9 +520,9 @@ void StackMaps::emitCallsiteEntries(MCStreamer &OS) {
void StackMaps::serializeToStackMapSection() {
(void)WSMP;
// Bail out if there's no stack map data.
assert((!CSInfos.empty() || (CSInfos.empty() && ConstPool.empty())) &&
assert((!CSInfos.empty() || ConstPool.empty()) &&
"Expected empty constant pool too!");
assert((!CSInfos.empty() || (CSInfos.empty() && FnStackSize.empty())) &&
assert((!CSInfos.empty() || FnStackSize.empty()) &&
"Expected empty function record too!");
if (CSInfos.empty())
return;

View File

@ -5076,7 +5076,7 @@ bool SimplifyCFGOpt::SimplifyUncondBranch(BranchInst *BI, IRBuilder<> &Builder){
// in the back-end.)
BasicBlock::iterator I = BB->getFirstNonPHIOrDbg()->getIterator();
if (I->isTerminator() && BB != &BB->getParent()->getEntryBlock() &&
(!LoopHeaders || (LoopHeaders && !LoopHeaders->count(BB))) &&
(!LoopHeaders || !LoopHeaders->count(BB)) &&
TryToSimplifyUncondBranchFromEmptyBlock(BB))
return true;