[PATCH] D52854: Use is.constant intrinsic for __builtin_constant_p

Bill Wendling via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Oct 3 17:15:27 PDT 2018


void created this revision.
void added reviewers: jyknight, eli.friedman, resistor, janusz.
Herald added subscribers: cfe-commits, kristina.

A __builtin_constant_p may end up with a constant after inlining. Use
the is.constant intrinsic if we're unable to determine if it's a
constant.

See: https://reviews.llvm.org/D4276


Repository:
  rC Clang

https://reviews.llvm.org/D52854

Files:
  include/clang/AST/Expr.h
  include/clang/Sema/Sema.h
  lib/AST/Expr.cpp
  lib/AST/ExprConstant.cpp
  lib/CodeGen/CGBuiltin.cpp
  lib/Sema/SemaExpr.cpp
  lib/Sema/SemaType.cpp
  test/Analysis/builtin-functions.cpp
  test/Sema/builtins.c

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D52854.168211.patch
Type: text/x-patch
Size: 10506 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20181004/c6b57201/attachment-0001.bin>


More information about the cfe-commits mailing list