[all-commits] [llvm/llvm-project] 47b6dc: [AArch64][SelectionDAG] Mask for SUBS with multipl...
Weihang Fan via All-commits
all-commits at lists.llvm.org
Tue May 14 14:16:09 PDT 2024
Branch: refs/heads/release/18.x
Home: https://github.com/llvm/llvm-project
Commit: 47b6dc45e39aea5369308c602f0d6341a054aca2
https://github.com/llvm/llvm-project/commit/47b6dc45e39aea5369308c602f0d6341a054aca2
Author: Weihang Fan <134108011+weihangf-apple at users.noreply.github.com>
Date: 2024-05-14 (Tue, 14 May 2024)
Changed paths:
M llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
M llvm/test/CodeGen/AArch64/and-mask-removal.ll
Log Message:
-----------
[AArch64][SelectionDAG] Mask for SUBS with multiple users cannot be elided (#90911)
In DAGCombiner, the `performCONDCombine` function attempts to remove AND
instructions in front of SUBS (cmp) instructions for which the AND is
transparent. The rules for that are correct, but it fails to take into
account the case where the SUBS instruction has multiple users with
different condition codes for comparison and simply removes the AND for
all of them. This causes a miscompilation in the attached test case.
(cherry picked from commit 72eaa0ed9934bfaa2449091bbc6e45648d1396d6)
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list