[PATCH] D117180: [BasicAliasAnalysis] Switch from isMallocOrCallocLikeFn to onlyAccessesInaccessibleMemory

Bryce Wilson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jan 16 12:19:50 PST 2022


Bryce-MW added a comment.

My current thought on how this could be done is to add some sort of optimization flag to clang, say -fstrict-op-new. If off (-fno-strict-op-new), it would mark op new as inaccessiblememonly and possibly removable if we ever add a way to mark that. When they would enable that flag would be up to them. I would say disabled unless -Ofast but maybe because of the regressions we've seen, it should be disabled at -O3 or something. I can't see any easier way to solve this issue unless we basically leave this optimization to LTO where we would know if op new was globally replaced or not.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D117180



More information about the llvm-commits mailing list