[all-commits] [llvm/llvm-project] 2c5a68: Fix non-splat vector SREM expansion when one of th...
Owen Anderson via All-commits
all-commits at lists.llvm.org
Sun Feb 25 07:13:16 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 2c5a68858b046c8a2ca3ba07ecd82771a5a9b884
https://github.com/llvm/llvm-project/commit/2c5a68858b046c8a2ca3ba07ecd82771a5a9b884
Author: Owen Anderson <resistor at mac.com>
Date: 2024-02-25 (Sun, 25 Feb 2024)
Changed paths:
M llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
M llvm/test/CodeGen/X86/srem-seteq-vec-nonsplat.ll
Log Message:
-----------
Fix non-splat vector SREM expansion when one of the divisors is a power of two. (#82706)
The expansion previously used, derived from Hacker's Delight,
does not work correctly when the dividend is INT_MIN and the
divisor is a power of two. We now use an alternate derivation
of the A and Q constants specifically for the power-of-two divisor
case to avoid this problem. Credit to Fabian Giesen for the
new derivation.
Fixes https://github.com/llvm/llvm-project/issues/77169
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