[all-commits] [llvm/llvm-project] 61225c: [ValueTracking][InstCombine] Introduce and use Com...

David Green via All-commits all-commits at lists.llvm.org
Fri Nov 5 07:41:49 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 61225c081858efe55dfc7051b338c797fab07cff
      https://github.com/llvm/llvm-project/commit/61225c081858efe55dfc7051b338c797fab07cff
  Author: David Green <david.green at arm.com>
  Date:   2021-11-05 (Fri, 05 Nov 2021)

  Changed paths:
    M llvm/include/llvm/Analysis/ValueTracking.h
    M llvm/include/llvm/Transforms/InstCombine/InstCombiner.h
    M llvm/lib/Analysis/ValueTracking.cpp
    M llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp

  Log Message:
  -----------
  [ValueTracking][InstCombine] Introduce and use ComputeMinSignedBits

This introduces a new ComputeMinSignedBits method for ValueTracking that
returns the BitWidth - SignBits + 1 from ComputeSignBits, and represents
the minimum bit size for the value as a signed integer.  Similar to the
existing APInt::getMinSignedBits method, this can make some of the
reasoning around ComputeSignBits more natural.

See https://reviews.llvm.org/D112298




More information about the All-commits mailing list