[all-commits] [llvm/llvm-project] 2d8d62: [SCEV] Require that addrec operands dominate the loop
Nikita Popov via All-commits
all-commits at lists.llvm.org
Fri Sep 22 00:03:42 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 2d8d622c738e636c4405072825c01bb14f87bb2f
https://github.com/llvm/llvm-project/commit/2d8d622c738e636c4405072825c01bb14f87bb2f
Author: Nikita Popov <npopov at redhat.com>
Date: 2023-09-22 (Fri, 22 Sep 2023)
Changed paths:
M llvm/lib/Analysis/ScalarEvolution.cpp
M llvm/lib/Transforms/Utils/ScalarEvolutionExpander.cpp
M llvm/unittests/Transforms/Utils/ScalarEvolutionExpanderTest.cpp
Log Message:
-----------
[SCEV] Require that addrec operands dominate the loop
SCEVExpander currently has special handling for the case where the
start or the step of an addrec do not dominate the loop header,
which is not used by any lit test.
Initially I thought that this is entirely dead code, because
addrec operands are required to be loop invariant. However,
SCEV currently allows creating an addrec with operands that are
loop invariant but defined *after* the loop.
This doesn't seem like a useful case to allow, and we don't
appear to be using this outside a single easy to adjust unit test.
More information about the All-commits
mailing list