[PATCH] D110861: X86InstrInfo: Extend optimizeCompareInstr to look across basic blocks.

Matthias Braun via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 30 10:56:03 PDT 2021


MatzeB created this revision.
MatzeB added reviewers: RKSimon, craig.topper, nikic, manmanren.
Herald added subscribers: wenlei, pengfei, hiraditya, mcrosier.
MatzeB requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

This extends `optimizeCompareInstr` to continue the backwards search when it reached the beginning of a basic block. If there is a single predecessor block then we can just continue the search in that block and mark the EFLAGS register as live-in.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D110861

Files:
  llvm/lib/Target/X86/X86InstrInfo.cpp
  llvm/test/CodeGen/X86/optimize-compare.mir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D110861.376282.patch
Type: text/x-patch
Size: 11591 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210930/803f948e/attachment.bin>


More information about the llvm-commits mailing list