[AggressiveInstCombine] Only fold consecutive shifts of loads with constant shift...
authorArthur Eubanks <aeubanks@google.com>
Thu, 4 May 2023 20:07:27 +0000 (13:07 -0700)
committerArthur Eubanks <aeubanks@google.com>
Thu, 4 May 2023 20:52:25 +0000 (13:52 -0700)
commited443d81d16768786b81534094ae64fa0afa5936
tree46db40c6c88b0309a6477cce7be2aff4a90dcdd5
parentdc39d98c3faa81ea48b89489b17ba80dae38c9b9
[AggressiveInstCombine] Only fold consecutive shifts of loads with constant shift amounts

This is what the code assumed but never actually checked.

Fixes https://github.com/llvm/llvm-project/issues/62509.

Reviewed By: nikic

Differential Revision: https://reviews.llvm.org/D149896
llvm/lib/Transforms/AggressiveInstCombine/AggressiveInstCombine.cpp
llvm/test/Transforms/AggressiveInstCombine/X86/or-load.ll