[Peephole-opt][X86] Enhance peephole opt to see through SUBREG_TO_REG
authorMingming Liu <mingmingl@google.com>
Tue, 10 May 2022 21:23:40 +0000 (14:23 -0700)
committerMingming Liu <mingmingl@google.com>
Tue, 10 May 2022 22:56:20 +0000 (15:56 -0700)
commitfc58d7a3261dc168fc177e54722b5ade1bb8508b
tree614d183fa1ce147f0546b85de20ee92a57ff45e8
parent96e642652b9b7cfe5a50819a217b9994bdc219fd
[Peephole-opt][X86] Enhance peephole opt to see through SUBREG_TO_REG
(following AND) and eliminates redundant TEST instruction.

Differential Revision: https://reviews.llvm.org/D124118
llvm/lib/Target/X86/X86InstrInfo.cpp
llvm/test/CodeGen/X86/peephole-test-after-add.mir [new file with mode: 0644]