Skip to content

Commit

Permalink
[NFC][ObjectSizeOffsetVisitor] Remove redundant equality check
Browse files Browse the repository at this point in the history
Originally suggested in https://reviews.llvm.org/D131001 but I accidentally took only have of the suggestion.
  • Loading branch information
aeubanks committed Sep 22, 2023
1 parent 4b0df11 commit 0944eea
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion llvm/lib/Analysis/MemoryBuiltins.cpp
Expand Up @@ -988,7 +988,7 @@ SizeOffsetType ObjectSizeOffsetVisitor::combineSizeOffset(SizeOffsetType LHS,
return (getSizeWithOverflow(LHS).eq(getSizeWithOverflow(RHS))) ? LHS
: unknown();
case ObjectSizeOpts::Mode::ExactUnderlyingSizeAndOffset:
return LHS == RHS && LHS.second.eq(RHS.second) ? LHS : unknown();
return LHS == RHS ? LHS : unknown();
}
llvm_unreachable("missing an eval mode");
}
Expand Down

0 comments on commit 0944eea

Please sign in to comment.