mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-11-23 13:50:11 +00:00
[analyzer][NFC] Merge similar conditional paths
Reviewed By: aaron.ballman, steakhal Differential Revision: https://reviews.llvm.org/D121045
This commit is contained in:
parent
2f80ea7f4f
commit
90a6e35478
@ -287,7 +287,7 @@ out = transfer(basic_block, join(in_1, in_2, ..., in_n))
|
||||
|
||||
(Note that there are other ways to write this equation that produce higher
|
||||
precision analysis results. The trick is to keep exploring the execution paths
|
||||
separately and delay joining until later. Hoowever, we won't discuss those
|
||||
separately and delay joining until later. However, we won't discuss those
|
||||
variations here.)
|
||||
|
||||
To make a conclusion about all paths through the program, we repeat this
|
||||
|
@ -107,11 +107,8 @@ LookThroughTransitiveAssignmentsAndCommaOperators(const Expr *Ex) {
|
||||
dyn_cast<BinaryOperator>(Ex->IgnoreParenCasts());
|
||||
if (!BO)
|
||||
break;
|
||||
if (BO->getOpcode() == BO_Assign) {
|
||||
Ex = BO->getRHS();
|
||||
continue;
|
||||
}
|
||||
if (BO->getOpcode() == BO_Comma) {
|
||||
BinaryOperatorKind Op = BO->getOpcode();
|
||||
if (Op == BO_Assign || Op == BO_Comma) {
|
||||
Ex = BO->getRHS();
|
||||
continue;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user