[all-commits] [llvm/llvm-project] 3075e5: [X86][FastISel] Fix with.overflow + select eflags ...

Nikita Popov via All-commits all-commits at lists.llvm.org
Fri Apr 8 07:12:43 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 3075e5d2efd04dcd0add0e7f0a0d169fdc255f04
      https://github.com/llvm/llvm-project/commit/3075e5d2efd04dcd0add0e7f0a0d169fdc255f04
  Author: Nikita Popov <npopov at redhat.com>
  Date:   2022-04-08 (Fri, 08 Apr 2022)

  Changed paths:
    M llvm/lib/Target/X86/X86FastISel.cpp
    M llvm/test/CodeGen/X86/pr54369.ll

  Log Message:
  -----------
  [X86][FastISel] Fix with.overflow + select eflags clobber (PR54369)

Don't try to directly use the with.overflow flag result in a cmov
if we need to materialize constants between the instruction
producing the overflow flag and the cmov. The current code is
careful to check that there are no other instructions in between,
but misses the constant materialization case (which may clobber
eflags via xor or constant expression evaluation).

Fixes https://github.com/llvm/llvm-project/issues/54369.

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




More information about the All-commits mailing list