[llvm-commits] [llvm] r67194 - in /llvm/trunk/lib/Transforms: Scalar/ScalarReplAggregates.cpp Utils/Local.cpp

Duncan Sands baldrick at free.fr
Wed Mar 18 04:29:14 PDT 2009


Hi,

> > why is it safe to delete the instruction itself (done just below)?
> > Does being used by debug intrinsics imply that the instruction cannot
> > write memory?
> 
> I'm not sure if an instruction only used by debug info will write memory.
> But in this case, as the instruction "I" is just an allocaInst, so, I think
> it is safe to delete.

"I" is not the AllocaInst, it is the user of the alloca (the alloca called AI).
If it was the alloca inst there would never have been a problem with your
testcase in the first place...

Ciao,

Duncan.



More information about the llvm-commits mailing list