[PATCH] D52729: [InstCombine] Fix SimplifyLibCalls erasing an instruction while IC still had references to it

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 9 07:46:06 PDT 2018


spatel added inline comments.


================
Comment at: include/llvm/Transforms/Utils/SimplifyLibCalls.h:105
+          &replaceAllUsesWithDefault,
+      function_ref<void(Instruction *)> Eraser = &eraseFromParentDefault);
 
----------------
This will fail at link time if a client has not provided the function? Isn't it better to just require this param (and the existing RAUW)?


Repository:
  rL LLVM

https://reviews.llvm.org/D52729





More information about the llvm-commits mailing list