Skip to content

Conversation

@zyw-bot
Copy link
Collaborator

@zyw-bot zyw-bot commented Nov 18, 2025

Link: llvm/llvm-project#168505
Requested by: @dtcxzyw

@github-actions github-actions bot mentioned this pull request Nov 18, 2025
@zyw-bot
Copy link
Collaborator Author

zyw-bot commented Nov 18, 2025

Diff mode

runner: ariselab-64c-docker
baseline: llvm/llvm-project@4ecfaa6
patch: llvm/llvm-project#168505
sha256: e097a777e26fb2a673c582f7b8cd4cac8d03b4abb15e6092b7774979e9366c45
commit: 480b207

2 files changed, 435 insertions(+), 429 deletions(-)

Improvements:
Regressions:
  correlated-value-propagation.NumSDivSRemsNarrowed 2803 -> 2488 -11.24%
  correlated-value-propagation.NumDeadCases 66071 -> 61552 -6.84%
  tailcallelim.NumRetDuped 15557 -> 14553 -6.45%
  loop-rotate.NumNotRotatedDueToHeaderSize 5140 -> 4925 -4.18%
  tailcallelim.NumEliminated 8681 -> 8334 -4.00%
  licm.NumMinMaxHoisted 593 -> 570 -3.88%
  globalopt.NumCXXDtorsRemoved 2003 -> 1926 -3.84%
  correlated-value-propagation.NumSDivs 16936 -> 16296 -3.78%
  correlated-value-propagation.NumSRems 1574 -> 1518 -3.56%
  correlated-value-propagation.NumMinMax 11981 -> 11596 -3.21%

https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/postgres/original/tuplesortvariants.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/postgres/original/heapam.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/llvm/original/OptimizedStructLayout.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nlohmann_json/original/unit-iterators2.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/evmone/original/tracing.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/mold/original/gdb-index.cc.X86_64.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/mold/original/icf.cc.X86_64.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/mold/original/input-files.cc.X86_64.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/mold/original/multi-glob.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/mold/original/cmdline.cc.X86_64.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/mold/original/output-chunks.cc.X86_64.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/mold/original/passes.cc.X86_64.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/actix-rs/original/1cyxz7f31jo1m8z1.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/ssh.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/binary-cache-store.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/unpack-channel.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/posix-source-accessor.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/local-keys.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/substitution-goal.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/value-to-xml.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/dotgraph.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/stack.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/file-system.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/upgrade-nix.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/primops.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/store-info.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/progress-bar.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/error.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/user-env.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/profiles.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/command.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/common-args.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/fs-sink.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/uds-remote-store.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/edit.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/add-to-store.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/fromTOML.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/serve-protocol-impl.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/cgroup.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/drv-output-substitution-goal.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/cache.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/filtering-input-accessor.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/remote-fs-accessor.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/http-binary-cache-store.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/verify.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/goal.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/legacy-ssh-store.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/store-gc.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/dummy-store.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/why-depends.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/make-content-addressed.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/fetchTree.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/export-import.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/lock.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/run.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/graphml.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/fetchClosure.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/source-accessor.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/build-remote.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/sqlite.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/built-path.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/local-fs-store.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/nix-instantiate.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/signals.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/local-binary-cache-store.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/prefetch.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/entry-points.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/mounted-input-accessor.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/source-path.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/installable-attr-path.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/users.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/ssh-store.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/attr-set.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/child.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/mercurial.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/tarball.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/editor-for.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/installables.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/tarfile.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/util.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/shared.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/print-ambiguous.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/hook-instance.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/names.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/dump-path.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/posix-fs-canonicalise.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/github.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/nixexpr.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/unix-domain-socket.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/eval-error.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/processes.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/config-check.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/repl.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/serialise.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/memory-source-accessor.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/gc.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/path-from-hash-part.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/derivation-add.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/ls.ll fail
https://github.com/dtcxzyw/llvm-opt-benchmark/blob/main/bench/nix/original/current-process.ll fail

+6 icu/collationcompare.ll

@github-actions
Copy link
Contributor

The provided diff modifies LLVM IR for the collationcompare function in an ICU benchmark, primarily improving correctness and optimization potential. Below are the major changes:

  1. Introduction of @llvm.ucmp.i32.i32 intrinsic:
    The patch replaces manual unsigned comparison logic (using icmp ult, select, etc.) with calls to the new @llvm.ucmp.i32.i32 intrinsic. This simplifies code that compares two 32-bit integers and returns -1, 0, or 1 based on their unsigned order. Uses appear in key comparison paths (e.g., %139 = tail call i32 @llvm.ucmp.i32.i32(...)), reducing verbosity and enabling better optimization.

  2. Use of freeze on loaded values before truncation:
    Before truncating i64 values loaded from memory to i32, the patch inserts freeze instructions (e.g., %.fr = freeze i64 %126). This ensures that undef/poison bits in the high part of the i64 do not propagate into the i32 result, making the behavior well-defined and allowing safer optimizations.

  3. Loop and control flow restructuring with updated PHI nodes:
    Several loop headers and critical edges have updated PHI node incoming block labels (e.g., from %.loopexit370 to %.loopexit373, %.preheader360 to %.preheader363). These reflect changes in loop structure or splitting, likely due to improved loop unrolling or outlining (e.g., .preheader363, .lr.ph445). This improves clarity and correctness of SSA construction.

  4. Fixes to PHI node predecessor blocks in complex loops:
    Multiple PHI nodes in merge blocks (like %._crit_edge446, %154, .split.us) now reference correct predecessor blocks after refactoring. For example, %.0241 and related PHIs now correctly list %153 instead of %154, indicating precise dataflow updates post-optimization.

  5. Simplification and correction of conditional logic in comparison loops:
    Blocks like %252%.thread334 are restructured to reduce redundancy. The logic for handling special cases (e.g., values > 256) is streamlined, with fewer branches and more direct use of phi nodes to merge results. This reduces code size and improves analyzability.

Overall, the changes enhance semantic correctness (via freeze and ucmp), improve optimization potential, and clean up control flow after loop transformations.

model: qwen-plus-latest
CompletionUsage(completion_tokens=576, prompt_tokens=14151, total_tokens=14727, completion_tokens_details=None, prompt_tokens_details=None)

@dtcxzyw dtcxzyw added the crash label Nov 18, 2025
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.

2 participants