Hi there,
i am currently working on a transformation pass where i replace some function calls. I use replaceAllUsesWith() to replace them.
After that i want to clean up like this:
callInst->removeFromParent();
delete callInst;
If the instruction is not deleted an error occurs when running the pass (parentless instruction). So is it okay to do it this way or is there a better way to do it?
Regards
Lorenz