[all-commits] [llvm/llvm-project] cb4443: [SimplifyCFG] Make test more robust (NFC)

Nikita Popov via All-commits all-commits at lists.llvm.org
Sun Apr 4 08:15:20 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: cb4443994e72ab524c70854dc93cd272ac1c4026
      https://github.com/llvm/llvm-project/commit/cb4443994e72ab524c70854dc93cd272ac1c4026
  Author: Nikita Popov <nikita.ppv at gmail.com>
  Date:   2021-04-04 (Sun, 04 Apr 2021)

  Changed paths:
    M llvm/test/Transforms/SimplifyCFG/switch_create-custom-dl.ll
    M llvm/test/Transforms/SimplifyCFG/switch_create.ll

  Log Message:
  -----------
  [SimplifyCFG] Make test more robust (NFC)

These are supposed to test creation of a switch, so make sure
there is some actual code in the branches. Otherwise this could
be turned into a select instead.


  Commit: 7ca168dd5adabcc01e957fb8486ddf2e22dd37d7
      https://github.com/llvm/llvm-project/commit/7ca168dd5adabcc01e957fb8486ddf2e22dd37d7
  Author: Nikita Popov <nikita.ppv at gmail.com>
  Date:   2021-04-04 (Sun, 04 Apr 2021)

  Changed paths:
    A llvm/test/Transforms/PhaseOrdering/partialord-ule.ll
    M llvm/test/Transforms/SimplifyCFG/switch-to-select-two-case.ll

  Log Message:
  -----------
  [SimplifyCFG] Add switch-to-select test with two equal cases (NFC)

We handle the case where we have two cases and a default all having
different values, but not the case where two cases happen to have
the same one.

The PhaseOrdering test is a particularly bad example where this
showed up.


Compare: https://github.com/llvm/llvm-project/compare/241d42c38226...7ca168dd5ada


More information about the All-commits mailing list