[PATCH] D45287: [InstCombine] Properly change GEP type when reassociating loop invariant GEP chains
Daniel Neilson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 5 06:21:48 PDT 2018
dneilson added inline comments.
================
Comment at: lib/Transforms/InstCombine/InstructionCombining.cpp:1710
+ auto *SO0 = Src->getOperand(0);
+ Builder.SetInsertPoint(&GEP);
+ auto *NewSrc = cast<GetElementPtrInst>(
----------------
I need to change this. We should be putting the new src instruction at the same location as the one it's replacing. Otherwise, it might be possible to get into unknown weirdness.
Repository:
rL LLVM
https://reviews.llvm.org/D45287
More information about the llvm-commits
mailing list