[GVN] reportMayClobberedLoad - avoid repeated cast<> calls. NFCI.
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 15 Dec 2022 15:44:27 +0000 (15:44 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 15 Dec 2022 15:44:35 +0000 (15:44 +0000)
commitd46f6cd7673790168376c52bf383746816630e41
treea92e869d61b971dcbb846681a2cb965fb71510e1
parent98550df7b7bbce0e38a1ec558287d759163c64ba
[GVN] reportMayClobberedLoad - avoid repeated cast<> calls. NFCI.

Just perform each cast<Instruction> once - we can make OtherAccess a Instruction* type as we only ever assign it from a known LoadInst/StoreInst
llvm/lib/Transforms/Scalar/GVN.cpp