[all-commits] [llvm/llvm-project] b22910: [InstCombine] erase instructions leading up to unr...

RotateRight via All-commits all-commits at lists.llvm.org
Mon Sep 7 07:44:30 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: b22910daab95be1ebc6ab8a74190e38130b0e6ef
      https://github.com/llvm/llvm-project/commit/b22910daab95be1ebc6ab8a74190e38130b0e6ef
  Author: Sanjay Patel <spatel at rotateright.com>
  Date:   2020-09-07 (Mon, 07 Sep 2020)

  Changed paths:
    M llvm/lib/Transforms/InstCombine/InstCombineInternal.h
    M llvm/lib/Transforms/InstCombine/InstructionCombining.cpp
    M llvm/test/Transforms/InstCombine/assume.ll
    M llvm/test/Transforms/InstCombine/pr33689_same_bitwidth.ll

  Log Message:
  -----------
  [InstCombine] erase instructions leading up to unreachable

Normal dead code elimination ignores assume intrinsics, so we fail to
delete assumes that are not meaningful (and potentially worse if they
cause conflicts with other assumptions).

The motivating example in https://llvm.org/PR47416 suggests that we
might have problems upstream from here (difference between C and C++),
but this should be a cheap way to make sure we remove more dead code.

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




More information about the All-commits mailing list