[PATCH] D97735: [Globals] Treat nobuiltin fns as maybe-derefined.

Johannes Doerfert via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Mar 1 15:38:06 PST 2021


jdoerfert added inline comments.


================
Comment at: llvm/include/llvm/IR/GlobalValue.h:147
+      // derefined.
+      return isInterposable() || isNobuiltinFnDef();
     }
----------------
rsmith wrote:
> I don't think `nobuiltin` is relevant; I think what matters is whether the function is a builtin function. We have the same miscompile if we removed all the `builtin` / `nobuiltin` annotations from the IR generated for the PR49022 example, and this change does nothing to address that case.
So you are saying we can legally define our own `operator delete(void*) = _ZdlPv` without a `nobuiltin` attribute and that would still need to stop IPO from assuming it is the idealized version we all know and love?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D97735/new/

https://reviews.llvm.org/D97735



More information about the llvm-commits mailing list