[all-commits] [llvm/llvm-project] e529c0: [TargetLowering] Use ComputeMaxSignificantBits ins...

Craig Topper via All-commits all-commits at lists.llvm.org
Sun Sep 4 22:37:18 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: e529c0a2a03fb4eb0ddffafe0ddc7a02059f74cc
      https://github.com/llvm/llvm-project/commit/e529c0a2a03fb4eb0ddffafe0ddc7a02059f74cc
  Author: Craig Topper <craig.topper at sifive.com>
  Date:   2022-09-04 (Sun, 04 Sep 2022)

  Changed paths:
    M llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp

  Log Message:
  -----------
  [TargetLowering] Use ComputeMaxSignificantBits instead of ComputeNumSignBits in expandMUL_LOHI. NFC

The way ComputeNumSignBits was being used was only correct if
OuterBitSize is exactly 2x InnerBitSize. Which is always true,
but not obviously so. Comparing ComputeMaxSignificantBits to
InnerBitSize feels more correct.




More information about the All-commits mailing list