[all-commits] [llvm/llvm-project] a1e62a: Minor reflow of FloorDivSIOp/CeilDivSIOp folder to...

Mehdi Amini via All-commits all-commits at lists.llvm.org
Sun Jan 2 21:55:40 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a1e62aa75b66e2b25e85fd98f41a8d6134192783
      https://github.com/llvm/llvm-project/commit/a1e62aa75b66e2b25e85fd98f41a8d6134192783
  Author: Mehdi Amini <joker.eph at gmail.com>
  Date:   2022-01-03 (Mon, 03 Jan 2022)

  Changed paths:
    M mlir/lib/Dialect/Arithmetic/IR/ArithmeticOps.cpp

  Log Message:
  -----------
  Minor reflow of FloorDivSIOp/CeilDivSIOp folder to limit the number of APInt API calls (NFC)

Cache the result of the comparison in boolean, and check early for 0 to
leverage `(a < 0) == !(a > 0)`.




More information about the All-commits mailing list