[PATCH] D124118: [Peephole-Opt] For one kind of test-after-add pattern, eliminates test if it's correct to do so.
Mingming Liu via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 28 14:25:54 PDT 2022
mingmingl updated this revision to Diff 425906.
mingmingl marked an inline comment as done.
mingmingl added a comment.
Correct the auto-format a little bit
Before
// The reason to poison SF bit is that SF bit value could be different
// in the `AND` and `TEST` operation
//
// dest_reg = AND32ri8 src_reg, #imm # signed bit is not known without
// peeking at #imm. extended_dest_reg = SUBREG_TO_REG 0, dest_reg, sub_32bit
After
// The reason to poison SF bit is that SF bit value could be different
// in the `AND` and `TEST` operation; signed bit is not known for `AND`
// without peeking at #imm, and is known to be 0 as a result of
// `TEST64rr`.
// dest_reg = AND32ri8 src_reg, #imm
// extended_dest_reg = SUBREG_TO_REG 0, dest_reg, sub_32bit
// TEST64rr extended_dest_reg, extended_dest_reg,
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D124118/new/
https://reviews.llvm.org/D124118
Files:
llvm/lib/Target/X86/X86InstrInfo.cpp
llvm/test/CodeGen/X86/peephole-test-after-add.mir
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D124118.425906.patch
Type: text/x-patch
Size: 11864 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220428/e557f557/attachment.bin>
More information about the llvm-commits
mailing list