[all-commits] [llvm/llvm-project] ba1255: [DAG] Use FoldConstantArithmetic to constant fold ...
Simon Pilgrim via All-commits
all-commits at lists.llvm.org
Sun Oct 20 05:10:26 PDT 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: ba1255def64a9c3c68d97ace051eec76f546eeb0
https://github.com/llvm/llvm-project/commit/ba1255def64a9c3c68d97ace051eec76f546eeb0
Author: Simon Pilgrim <llvm-dev at redking.me.uk>
Date: 2024-10-20 (Sun, 20 Oct 2024)
Changed paths:
M llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
Log Message:
-----------
[DAG] Use FoldConstantArithmetic to constant fold (and (ext (and V, c1)), c2) -> (and (ext V), (and c1, (ext c2)))
Noticed while triaging the regression from #112710 noticed by @mstorsjo - don't rely on isConstantIntBuildVectorOrConstantInt+getNode to guarantee constant folding (if it fails to constant fold it will infinite loop), use FoldConstantArithmetic instead.
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