[all-commits] [llvm/llvm-project] 88690a: [CodeGenPrepare] Fix zapping dead operands of assume

Yevgeny Rouban via All-commits all-commits at lists.llvm.org
Sun Sep 13 21:47:56 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 88690a965892e82cac05a162a9d10e2ce4e2355f
      https://github.com/llvm/llvm-project/commit/88690a965892e82cac05a162a9d10e2ce4e2355f
  Author: Yevgeny Rouban <yrouban at azul.com>
  Date:   2020-09-14 (Mon, 14 Sep 2020)

  Changed paths:
    M llvm/lib/CodeGen/CodeGenPrepare.cpp
    A llvm/test/Transforms/CodeGenPrepare/X86/recursively-delete-dead-instructions.ll

  Log Message:
  -----------
  [CodeGenPrepare] Fix zapping dead operands of assume

This patch fixes a problem of the commit 52cc97a0.
A test case is created to demonstrate the crash caused by
the instruction iterator invalidated by the recursive
removal of dead operands of assume. The solution restarts
from the blocks's first instruction in case CurInstIterator
is invalidated by RecursivelyDeleteTriviallyDeadInstructions().

Reviewed By: bkramer

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




More information about the All-commits mailing list