[PATCH] D71828: [InstCombine] Convert vector store to scalar store if only one element updated

Qiu Chaofan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 14 02:19:07 PST 2020


qiucf added inline comments.


================
Comment at: llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp:1189
+  if (!match(SI.getValueOperand(),
+             m_InsertElement(m_Instruction(Source), m_Value(NewElement),
+                             m_Constant(Idx))))
----------------
lebedev.ri wrote:
> Match `m_Load()` specifically?
I think `m_Load()` is used for matching a load to some specific address. `m_Load(Src)` set `Src` as address of the load. But here we need the load instr to do more checks. Is that necessary?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D71828/new/

https://reviews.llvm.org/D71828





More information about the llvm-commits mailing list