[all-commits] [llvm/llvm-project] 5a8a7b: [NFC] Re-autogenerate check lines in some tests to...

Roman Lebedev via All-commits all-commits at lists.llvm.org
Wed Oct 27 08:03:36 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 5a8a7b3bf807b3c8c2b3772eb70386846a72013f
      https://github.com/llvm/llvm-project/commit/5a8a7b3bf807b3c8c2b3772eb70386846a72013f
  Author: Roman Lebedev <lebedev.ri at gmail.com>
  Date:   2021-10-27 (Wed, 27 Oct 2021)

  Changed paths:
    M llvm/test/Transforms/LoopPredication/basic.ll
    M llvm/test/Transforms/LoopPredication/basic_widenable_branch_guards.ll
    M llvm/test/Transforms/LoopPredication/invariant_load.ll
    M llvm/test/Transforms/LoopVectorize/X86/illegal-parallel-loop-uniform-write.ll
    M llvm/test/Transforms/LoopVectorize/X86/pr35432.ll
    M llvm/test/Transforms/LoopVectorize/optimal-epilog-vectorization.ll
    M llvm/test/Transforms/LoopVectorize/pr30654-phiscev-sext-trunc.ll
    M llvm/test/Transforms/LoopVectorize/runtime-check-needed-but-empty.ll

  Log Message:
  -----------
  [NFC] Re-autogenerate check lines in some tests to ease of future update


  Commit: ab1dbcecd6f0969976fafd62af34730436ad5944
      https://github.com/llvm/llvm-project/commit/ab1dbcecd6f0969976fafd62af34730436ad5944
  Author: Roman Lebedev <lebedev.ri at gmail.com>
  Date:   2021-10-27 (Wed, 27 Oct 2021)

  Changed paths:
    M clang/test/CodeGen/ubsan-pointer-overflow.c
    M clang/test/CodeGenCXX/pr27030.cpp
    M llvm/lib/IR/IRBuilder.cpp
    M llvm/test/CodeGen/X86/block-placement.ll
    M llvm/test/Transforms/LoopDistribute/scev-inserted-runtime-check.ll
    M llvm/test/Transforms/LoopVectorize/ARM/mve-gather-scatter-tailpred.ll
    M llvm/test/Transforms/LoopVectorize/ARM/tail-folding-not-allowed.ll
    M llvm/test/Transforms/LoopVectorize/PowerPC/optimal-epilog-vectorization.ll
    M llvm/test/Transforms/LoopVectorize/X86/illegal-parallel-loop-uniform-write.ll
    M llvm/test/Transforms/LoopVectorize/X86/pr35432.ll
    M llvm/test/Transforms/LoopVectorize/first-order-recurrence-complex.ll
    M llvm/test/Transforms/LoopVectorize/optimal-epilog-vectorization.ll
    M llvm/test/Transforms/LoopVectorize/pr45259.ll
    M llvm/test/Transforms/LoopVectorize/runtime-check-needed-but-empty.ll
    M llvm/test/Transforms/LoopVectorize/runtime-check-small-clamped-bounds.ll
    M llvm/test/Transforms/LoopVersioning/wrapping-pointer-versioning.ll

  Log Message:
  -----------
  [IR] `IRBuilderBase::CreateSelect()`: if cond is a constant i1, short-circuit

While we could emit such a tautological `select`,
it will stick around until the next instsimplify invocation,
which may happen after we count the cost of this redundant `select`.
Which is precisely what happens with loop vectorization legality checks,
and that artificially increases the cost of said checks,
which is bad.

There is prior art for this in `IRBuilderBase::CreateAnd()`/`IRBuilderBase::CreateOr()`.

Refs. https://reviews.llvm.org/D109368#3089809


  Commit: f3df87d57e096143670e0fd396e81d43393a2dd2
      https://github.com/llvm/llvm-project/commit/f3df87d57e096143670e0fd396e81d43393a2dd2
  Author: Roman Lebedev <lebedev.ri at gmail.com>
  Date:   2021-10-27 (Wed, 27 Oct 2021)

  Changed paths:
    M clang/test/CodeGenCXX/cfi-mfcall.cpp
    M llvm/include/llvm/IR/IRBuilder.h
    M llvm/test/Instrumentation/BoundsChecking/opt.ll
    M llvm/test/Transforms/LoopDistribute/scev-inserted-runtime-check.ll
    M llvm/test/Transforms/LoopVectorize/ARM/mve-gather-scatter-tailpred.ll
    M llvm/test/Transforms/LoopVectorize/ARM/tail-folding-not-allowed.ll
    M llvm/test/Transforms/LoopVectorize/PowerPC/optimal-epilog-vectorization.ll
    M llvm/test/Transforms/LoopVectorize/X86/illegal-parallel-loop-uniform-write.ll
    M llvm/test/Transforms/LoopVectorize/X86/pr35432.ll
    M llvm/test/Transforms/LoopVectorize/first-order-recurrence-complex.ll
    M llvm/test/Transforms/LoopVectorize/optimal-epilog-vectorization.ll
    M llvm/test/Transforms/LoopVectorize/pr30654-phiscev-sext-trunc.ll
    M llvm/test/Transforms/LoopVectorize/pr45259.ll
    M llvm/test/Transforms/LoopVectorize/runtime-check-needed-but-empty.ll
    M llvm/test/Transforms/LoopVectorize/runtime-check-small-clamped-bounds.ll
    M llvm/test/Transforms/LoopVersioning/wrapping-pointer-versioning.ll

  Log Message:
  -----------
  [IR] `IRBuilderBase::CreateOr()`: fix short-circuiting for constant on LHS

There is no guarantee that the constant is on RHS here,
we have to handle both cases.

Refs. https://reviews.llvm.org/D109368#3089809


  Commit: 749581d21f2b3f53e4fca4eb8728c942d646893b
      https://github.com/llvm/llvm-project/commit/749581d21f2b3f53e4fca4eb8728c942d646893b
  Author: Roman Lebedev <lebedev.ri at gmail.com>
  Date:   2021-10-27 (Wed, 27 Oct 2021)

  Changed paths:
    M clang/test/CodeGen/arm-mve-intrinsics/vadc.c
    M clang/test/CodeGen/catch-nullptr-and-nonzero-offset.c
    M clang/test/CodeGenCXX/ext-vector-type-conditional.cpp
    M clang/test/CodeGenObjC/ubsan-nullability.m
    M llvm/include/llvm/IR/IRBuilder.h
    M llvm/test/Transforms/LoopIdiom/X86/left-shift-until-bittest.ll
    M llvm/test/Transforms/LoopPredication/basic.ll
    M llvm/test/Transforms/LoopPredication/basic_widenable_branch_guards.ll
    M llvm/test/Transforms/LoopPredication/invariant_load.ll
    M llvm/test/Transforms/LowerTypeTests/import.ll

  Log Message:
  -----------
  [IR] `IRBuilderBase::CreateAnd()`: fix short-circuiting for constant on LHS

Refs. https://reviews.llvm.org/D109368#3089809


  Commit: f3190dedeef9da2109ea57e4cb372f295ff53b88
      https://github.com/llvm/llvm-project/commit/f3190dedeef9da2109ea57e4cb372f295ff53b88
  Author: Roman Lebedev <lebedev.ri at gmail.com>
  Date:   2021-10-27 (Wed, 27 Oct 2021)

  Changed paths:
    M clang/test/CodeGen/catch-nullptr-and-nonzero-offset.c
    M llvm/include/llvm/IR/IRBuilder.h
    M llvm/test/Transforms/LoopPredication/basic.ll
    M llvm/test/Transforms/LoopPredication/reverse.ll

  Log Message:
  -----------
  [IR] `IRBuilderBase::CreateAnd()`: short-circuit `x & 0` --> `0`

https://alive2.llvm.org/ce/z/YzPhSb

Refs. https://reviews.llvm.org/D109368#3089809


Compare: https://github.com/llvm/llvm-project/compare/888af47095d5...f3190dedeef9


More information about the All-commits mailing list