Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pre-commit: test PR80941 #199

Closed
wants to merge 3 commits into from
Closed

pre-commit: test PR80941 #199

wants to merge 3 commits into from

Conversation

dtcxzyw
Copy link
Owner

@dtcxzyw dtcxzyw commented Feb 7, 2024

Copy link
Contributor

github-actions bot commented Feb 7, 2024

baseline: llvm/llvm-project@adbf21f
patch: llvm/llvm-project#80941
sha256: bec52c4b880e0e4693ad0f61a8cd344cae7f527a4d92f2f5bab30176ed8c17e0
commit: 9d91be7
41 files changed, 11714 insertions(+), 12332 deletions(-)
9d91be7 pre-commit: Update
bench/abseil-cpp/optimized/bernoulli_distribution_test.cc.ll
bench/abseil-cpp/optimized/beta_distribution_test.cc.ll
bench/abseil-cpp/optimized/discrete_distribution_test.cc.ll
bench/abseil-cpp/optimized/exponential_distribution_test.cc.ll
bench/abseil-cpp/optimized/gaussian_distribution_test.cc.ll
bench/abseil-cpp/optimized/iostream_state_saver_test.cc.ll
bench/abseil-cpp/optimized/poisson_distribution_test.cc.ll
bench/abseil-cpp/optimized/uniform_real_distribution_test.cc.ll
bench/assimp/optimized/IFCUtil.cpp.ll
bench/assimp/optimized/LWOLoader.cpp.ll
bench/assimp/optimized/NFFLoader.cpp.ll
bench/assimp/optimized/SkeletonMeshBuilder.cpp.ll
bench/cpython/optimized/mathmodule.ll
bench/eastl/optimized/TestSort.cpp.ll
bench/hermes/optimized/Array.cpp.ll
bench/icu/optimized/putil.ll
bench/imgui/optimized/imgui.cpp.ll
bench/imgui/optimized/imgui_draw.cpp.ll
bench/lodepng/optimized/lodepng_util.cpp.ll
bench/miniaudio/optimized/unity.c.ll
bench/nlohmann_json/optimized/unit-regression2.cpp.ll
bench/nuklear/optimized/unity.c.ll
bench/oiio/optimized/imagebufalgo_compare.cpp.ll
bench/oiio/optimized/imagebufalgo_yee.cpp.ll
bench/pbrt-v4/optimized/aggregate.cpp.ll
bench/pbrt-v4/optimized/bxdfs.cpp.ll
bench/pbrt-v4/optimized/imgtool.cpp.ll
bench/pbrt-v4/optimized/integrators.cpp.ll
bench/pbrt-v4/optimized/lights.cpp.ll
bench/pbrt-v4/optimized/primitive.cpp.ll
bench/qemu/optimized/fpu_softfloat.c.ll
bench/redis/optimized/util.ll
bench/stb/optimized/stb_truetype.c.ll
bench/velox/optimized/BaseVector.cpp.ll
bench/velox/optimized/Bridge.cpp.ll
bench/velox/optimized/VectorSaver.cpp.ll
bench/yoga/optimized/AbsoluteLayout.cpp.ll
bench/yoga/optimized/CalculateLayout.cpp.ll
bench/z3/optimized/smt_case_split_queue.cpp.ll

dtcxzyw added a commit to llvm/llvm-project that referenced this pull request Feb 7, 2024
This patch canonicalizes floating-point comparisons with inf:
```
fcmp olt X, +inf -> fcmp one X, +inf
fcmp ole X, +inf -> fcmp ord X, 0
fcmp ogt X, +inf -> false
fcmp oge X, +inf -> fcmp oeq X, +inf
fcmp ult X, +inf -> fcmp une X, +inf
fcmp ule X, +inf -> true
fcmp ugt X, +inf -> fcmp uno X, 0
fcmp uge X, +inf -> fcmp ueq X, +inf
fcmp olt X, -inf -> false
fcmp ole X, -inf -> fcmp oeq X, -inf
fcmp ogt X, -inf -> fcmp one X, -inf
fcmp oge X, -inf -> fcmp ord X, 0
fcmp ult X, -inf -> fcmp uno X, 0
fcmp ule X, -inf -> fcmp ueq X, -inf
fcmp ugt X, -inf -> fcmp une X, -inf
fcmp uge X, -inf -> true
```
Alive2: https://alive2.llvm.org/ce/z/FRqqDg

The motivation of this patch is to fix the regression found in
dtcxzyw/llvm-opt-benchmark#199 (comment).
dtcxzyw added a commit to llvm/llvm-project that referenced this pull request Feb 8, 2024
This patch generalizes `simplifyAndOrOfFCmps` to simplify patterns like:
```
define i1 @src(float %x, float %y) {
  %or.cond.i = fcmp ord float %x, 0.000000e+00
  %cmp.i.i34 = fcmp olt float %x, %y
  %cmp.i2.sink.i = and i1 %or.cond.i, %cmp.i.i34
  ret i1 %cmp.i2.sink.i
}

define i1 @tgt(float %x, float %y) {
  %cmp.i.i34 = fcmp olt float %x, %y
  ret i1 %cmp.i.i34
}
```
Alive2: https://alive2.llvm.org/ce/z/9rydcx

This patch and #80986 will fix the regression introduced by #80941.
See also the IR diff
dtcxzyw/llvm-opt-benchmark#199 (comment).
Copy link
Contributor

github-actions bot commented Feb 8, 2024

baseline: llvm/llvm-project@067d277
patch: llvm/llvm-project#80941
sha256: e9843debe25cc4eea101e70745cfa2aa2a77aac8debb0b469f1b117b852c301e
commit: 740a634
39 files changed, 11885 insertions(+), 12487 deletions(-)
740a634 pre-commit: Update
bench/abseil-cpp/optimized/bernoulli_distribution_test.cc.ll
bench/abseil-cpp/optimized/beta_distribution_test.cc.ll
bench/abseil-cpp/optimized/discrete_distribution_test.cc.ll
bench/abseil-cpp/optimized/exponential_distribution_test.cc.ll
bench/abseil-cpp/optimized/gaussian_distribution_test.cc.ll
bench/abseil-cpp/optimized/iostream_state_saver_test.cc.ll
bench/abseil-cpp/optimized/poisson_distribution_test.cc.ll
bench/abseil-cpp/optimized/uniform_real_distribution_test.cc.ll
bench/assimp/optimized/IFCUtil.cpp.ll
bench/assimp/optimized/LWOLoader.cpp.ll
bench/assimp/optimized/NFFLoader.cpp.ll
bench/assimp/optimized/SkeletonMeshBuilder.cpp.ll
bench/cpython/optimized/mathmodule.ll
bench/eastl/optimized/TestSort.cpp.ll
bench/hermes/optimized/Array.cpp.ll
bench/imgui/optimized/imgui.cpp.ll
bench/imgui/optimized/imgui_draw.cpp.ll
bench/lodepng/optimized/lodepng_util.cpp.ll
bench/miniaudio/optimized/unity.c.ll
bench/nuklear/optimized/unity.c.ll
bench/oiio/optimized/imagebufalgo_compare.cpp.ll
bench/oiio/optimized/imagebufalgo_yee.cpp.ll
bench/pbrt-v4/optimized/aggregate.cpp.ll
bench/pbrt-v4/optimized/bxdfs.cpp.ll
bench/pbrt-v4/optimized/imgtool.cpp.ll
bench/pbrt-v4/optimized/integrators.cpp.ll
bench/pbrt-v4/optimized/lights.cpp.ll
bench/pbrt-v4/optimized/primitive.cpp.ll
bench/qemu/optimized/fpu_softfloat.c.ll
bench/redis/optimized/util.ll
bench/stb/optimized/stb_truetype.c.ll
bench/velox/optimized/BaseVector.cpp.ll
bench/velox/optimized/Bridge.cpp.ll
bench/velox/optimized/VectorSaver.cpp.ll
bench/yoga/optimized/AbsoluteLayout.cpp.ll
bench/yoga/optimized/CalculateLayout.cpp.ll
bench/z3/optimized/smt_case_split_queue.cpp.ll

Copy link
Contributor

github-actions bot commented Feb 8, 2024

baseline: llvm/llvm-project@067d277
patch: llvm/llvm-project#80941
sha256: e9843debe25cc4eea101e70745cfa2aa2a77aac8debb0b469f1b117b852c301e
commit: f2c4125
2 files changed, 8847 insertions(+), 9057 deletions(-)
f2c4125 pre-commit: Update
bench/oiio/optimized/imagebufalgo_pixelmath.cpp.ll

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant