[all-commits] [llvm/llvm-project] d4627b: [InstCombine] Avoid modifying instructions in-place

Nikita Popov via All-commits all-commits at lists.llvm.org
Sat Feb 8 08:06:23 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: d4627b90a0462c90a834c2f7b9c9228b3ec7a45b
      https://github.com/llvm/llvm-project/commit/d4627b90a0462c90a834c2f7b9c9228b3ec7a45b
  Author: Nikita Popov <nikita.ppv at gmail.com>
  Date:   2020-02-08 (Sat, 08 Feb 2020)

  Changed paths:
    M llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp
    M llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp
    M llvm/lib/Transforms/InstCombine/InstCombineVectorOps.cpp
    M llvm/test/Transforms/InstCombine/icmp-custom-dl.ll
    M llvm/test/Transforms/InstCombine/icmp.ll

  Log Message:
  -----------
  [InstCombine] Avoid modifying instructions in-place

As discussed on D73919, this replaces a few cases where we were
modifying multiple operands of instructions in-place with the
creation of a new instruction, which we generally prefer nowadays.

This tends to be more readable and less prone to worklist management
bugs.

Test changes are only superficial (instruction naming and order).




More information about the All-commits mailing list