[all-commits] [llvm/llvm-project] 1eaf7b: APInt.h - return directly from clearUnusedBits in ...

Simon Pilgrim via All-commits all-commits at lists.llvm.org
Wed Sep 9 05:26:01 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 1eaf7babf2dcc3ab8fb429171c991556ffa98291
      https://github.com/llvm/llvm-project/commit/1eaf7babf2dcc3ab8fb429171c991556ffa98291
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2020-09-09 (Wed, 09 Sep 2020)

  Changed paths:
    M llvm/include/llvm/ADT/APInt.h

  Log Message:
  -----------
  APInt.h - return directly from clearUnusedBits in single word cases. NFCI.

Consistently use the same pattern of returning *this from the clearUnusedBits() call to allow us to early out from the isSingleWord() path and avoid an else statement.


  Commit: d816499f95d673bbad297d0231cbeaf5efbbc5de
      https://github.com/llvm/llvm-project/commit/d816499f95d673bbad297d0231cbeaf5efbbc5de
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2020-09-09 (Wed, 09 Sep 2020)

  Changed paths:
    M llvm/include/llvm/Support/KnownBits.h
    M llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
    M llvm/lib/Support/KnownBits.cpp

  Log Message:
  -----------
  [KnownBits] Move SelectionDAG::computeKnownBits ISD::ABS handling to KnownBits::abs

Move the ISD::ABS handling to a KnownBits::abs handler, to simplify future implementations in ValueTracking/GlobalISel.


Compare: https://github.com/llvm/llvm-project/compare/25f3cc0ced17...d816499f95d6


More information about the All-commits mailing list