[PATCH] D54827: [simplifycfg] Handle 3 sequential branches while the first two can infer the third one.

luo xionghu via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Nov 25 22:34:56 PST 2018


yinyuefengyi updated this revision to Diff 175199.
yinyuefengyi added a comment.

use existing logic to implement 'AND' operation of two compare instruction.

getICmpCode in InstCombine already done this job, reuse this logic instead of adding redundant function.
add most test cases to cover.


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D54827/new/

https://reviews.llvm.org/D54827

Files:
  llvm/lib/Transforms/Utils/SimplifyCFG.cpp
  llvm/test/Transforms/SimplifyCFG/branch-fold-three.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D54827.175199.patch
Type: text/x-patch
Size: 11478 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181126/70ff8ca4/attachment.bin>


More information about the llvm-commits mailing list