[PATCH] D156154: [clang][ConstExprEmitter] handle IntegerLiterals and IntegralCasts
Nick Desaulniers via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Jul 24 11:41:37 PDT 2023
nickdesaulniers added a comment.
In D156154#4529265 <https://reviews.llvm.org/D156154#4529265>, @efriedma wrote:
> As a practical matter, I'm not sure this helps much; ExprConstant should be reasonably fast for simple integers. The performance issues only really show for structs/arrays. But maybe it helps a little to handle a few of the most common integer expressions.
Perhaps, but after D151587 <https://reviews.llvm.org/D151587>, `ConstExprEmitter` will be tried first before `ExprConstant::Evaluate` (or rather `Evaluate` in ExprConstant.cpp; god, why is that a static function and not a method???). So it seems bad if we can't just evaluate the constant then and there.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D156154/new/
https://reviews.llvm.org/D156154
More information about the cfe-commits
mailing list