[all-commits] [llvm/llvm-project] 12bdd4: [APFloat] Improve asserts in isSignificandAllOnes ...

topperc via All-commits all-commits at lists.llvm.org
Wed Sep 30 19:33:19 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 12bdd427b33a75bd7abb5d4cb095d0b983328034
      https://github.com/llvm/llvm-project/commit/12bdd427b33a75bd7abb5d4cb095d0b983328034
  Author: Craig Topper <craig.topper at intel.com>
  Date:   2020-09-30 (Wed, 30 Sep 2020)

  Changed paths:
    M llvm/lib/Support/APFloat.cpp

  Log Message:
  -----------
  [APFloat] Improve asserts in isSignificandAllOnes and isSignificandAllZeros so they protect shift operations from undefined behavior.

For example, the assert in isSignificandAllZeros allowed NumHighBits
to be integerPartWidth. But since it is used directly as a shift amount
it must be less than integerPartWidth.




More information about the All-commits mailing list