[PATCH] Improved __builtin_constant_p
Janusz Sobczak
janusz.sobczak at mobica.com
Mon Jul 14 05:32:54 PDT 2014
Hi nlewycky,
Improved __builtin_constant_p() implementation to match GCC closer.
If the compiler cannot confirm that the argument is constant, the function
is lowered to a (new) llvm.is.constant intrinsic and the constantness is
evaluated again after optimisations such as inlining.
Depends on D4276
http://reviews.llvm.org/D4492
Files:
lib/CodeGen/CGBuiltin.cpp
test/CodeGen/builtin_constant_p.c
test/Sema/builtin_constant_p.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D4492.11370.patch
Type: text/x-patch
Size: 5354 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20140714/07b8434b/attachment.bin>
More information about the cfe-commits
mailing list