[all-commits] [llvm/llvm-project] f35bce: [X86FixupLEAs] Sub register usage of LEA dest shou...

weiguozhi via All-commits all-commits at lists.llvm.org
Fri Jun 11 09:46:38 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: f35bcea1d4748889b8240defdf00cb7a71cbe070
      https://github.com/llvm/llvm-project/commit/f35bcea1d4748889b8240defdf00cb7a71cbe070
  Author: Guozhi Wei <carrot at google.com>
  Date:   2021-06-11 (Fri, 11 Jun 2021)

  Changed paths:
    M llvm/lib/Target/X86/X86FixupLEAs.cpp
    M llvm/test/CodeGen/X86/lea-opt2.ll

  Log Message:
  -----------
  [X86FixupLEAs] Sub register usage of LEA dest should block LEA/SUB optimization

In function searchALUInst, sub register usage of LEA dest should also block LEA/SUB optimization, otherwise the sub register usage gets an undefined value.

This patch fixes https://bugs.llvm.org/show_bug.cgi?id=50615.

Differential Revision: https://reviews.llvm.org/D103922




More information about the All-commits mailing list