[PATCH] D71442: [X86] Check if source elements are not structures before using a uniform base for the Gather/Scatter intrinsic.

Dávid Bolvanský via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Dec 14 02:36:27 PST 2019


xbolva00 added inline comments.


================
Comment at: llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp:4387
+      C = C->getSplatValue();
+    auto *CI = dyn_cast_or_null<ConstantInt>(C);
+    assert(CI && "Index inside structure must be integer.");
----------------
just 'cast'?

CI must be nonnull anyway, otherwise your assert fires.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D71442





More information about the llvm-commits mailing list