[PATCH] D79217: Process gep (select ptr1, ptr2) in SROA

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon May 18 18:26:28 PDT 2020


arsenm added inline comments.


================
Comment at: llvm/lib/Transforms/Scalar/SROA.cpp:3476
+    bool IsInBounds = GEPI.isInBounds();
+
+    Value *True = Sel->getTrueValue();
----------------
Probably should check there are only constant indexes?


================
Comment at: llvm/test/Transforms/SROA/select-gep.ll:6
+
+define i32 @test_sroa_select_gep(i1 %cond) {
+; CHECK-LABEL: @test_sroa_select_gep(
----------------
Should have a test with non-constant GEP indices. This probably doesn't help if they aren't constants


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

https://reviews.llvm.org/D79217





More information about the llvm-commits mailing list