[PATCH] D75505: [InstCombine] Enhance cast-of-load->load-of-bitcast fold to handle multiple identical casts
Nikita Popov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 3 12:37:15 PST 2020
nikic added inline comments.
================
Comment at: llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp:589
+ for (CastInst *CI : Casts) {
+ CI->replaceAllUsesWith(NewLoad);
+ IC.eraseInstFromFunction(*CI);
----------------
This should use `replaceInstUsesWith()`.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D75505/new/
https://reviews.llvm.org/D75505
More information about the llvm-commits
mailing list