[all-commits] [llvm/llvm-project] 673401: [Codegen][X86] EltsFromConsecutiveLoads(): if only...
Roman Lebedev via All-commits
all-commits at lists.llvm.org
Fri Aug 27 10:27:15 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 6734018041e408fe3cad13f2782d8048437de405
https://github.com/llvm/llvm-project/commit/6734018041e408fe3cad13f2782d8048437de405
Author: Roman Lebedev <lebedev.ri at gmail.com>
Date: 2021-08-27 (Fri, 27 Aug 2021)
Changed paths:
M llvm/lib/Target/X86/X86ISelLowering.cpp
M llvm/test/CodeGen/X86/pr51615.ll
Log Message:
-----------
[Codegen][X86] EltsFromConsecutiveLoads(): if only have AVX1, ensure that the "load" is actually foldable (PR51615)
This fixes another reproducer from https://bugs.llvm.org/show_bug.cgi?id=51615
And again, the fix lies not in the code added in D105390
In this case, we completely don't check that the "broadcast-from-mem" we create
can actually fold the load. In this case, it's operand was not a load at all:
```
Combining: t16: v8i32 = vector_shuffle<0,u,u,u,0,u,u,u> t14, undef:v8i32
Creating new node: t29: i32 = undef
RepeatLoad:
t8: i32 = truncate t7
t7: i64 = extract_vector_elt t5, Constant:i64<0>
t5: v2i64,ch = load<(load (s128) from %ir.arg)> t0, t2, undef:i64
t2: i64,ch = CopyFromReg t0, Register:i64 %0
t1: i64 = Register %0
t4: i64 = undef
t3: i64 = Constant<0>
Combining: t15: v8i32 = undef
```
Reviewed By: RKSimon
Differential Revision: https://reviews.llvm.org/D108821
More information about the All-commits
mailing list