[PATCH] D108479: [Clang] Add __builtin_addressof_nocfi

Sami Tolvanen via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Nov 18 09:52:12 PST 2021


samitolvanen marked an inline comment as done.
samitolvanen added a comment.

In D108479#3133578 <https://reviews.llvm.org/D108479#3133578>, @rjmccall wrote:

> If we do need to support constant expressions of this

Yes, we need this also in constant expressions.

> I think we should have the constant evaluator produce an expression rather than an l-value, the way we do with some other builtin calls.  That should stop the comparison problem more generally.

Sure, I can take a look at how that would work. Basically, in `PointerExprEvaluator::VisitBuiltinCallExpr` we should not evaluate the l-value and just leave it at `Result.set(E)`?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D108479



More information about the cfe-commits mailing list