[cfe-commits] r44500 - /cfe/trunk/include/clang/AST/Builtins.def
Chris Lattner
sabre at nondot.org
Sat Dec 1 17:20:30 PST 2007
Author: lattner
Date: Sat Dec 1 19:20:23 2007
New Revision: 44500
URL: http://llvm.org/viewvc/llvm-project?rev=44500&view=rev
Log:
register clz and ctz builtins.
Modified:
cfe/trunk/include/clang/AST/Builtins.def
Modified: cfe/trunk/include/clang/AST/Builtins.def
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/Builtins.def?rev=44500&r1=44499&r2=44500&view=diff
==============================================================================
--- cfe/trunk/include/clang/AST/Builtins.def (original)
+++ cfe/trunk/include/clang/AST/Builtins.def Sat Dec 1 19:20:23 2007
@@ -53,6 +53,7 @@
// c -> const
// F -> this is a libc/libm function with a '__builtin_' prefix added.
+// Standard libc/libm functions:
BUILTIN(__builtin_inf , "d" , "ncF")
BUILTIN(__builtin_inff , "f" , "ncF")
BUILTIN(__builtin_infl , "Ld" , "ncF")
@@ -60,6 +61,19 @@
BUILTIN(__builtin_fabs , "dd" , "ncF")
BUILTIN(__builtin_fabsf, "ff" , "ncF")
BUILTIN(__builtin_fabsl, "LdLd", "ncF")
+
+// Builtins for arithmetic.
+BUILTIN(__builtin_clz , "iUi" , "nc")
+BUILTIN(__builtin_clzl , "iULi" , "nc")
+BUILTIN(__builtin_clzll, "iULLi", "nc")
+// fixme: int clzimax(uintmax_t)
+BUILTIN(__builtin_ctz , "iUi" , "nc")
+BUILTIN(__builtin_ctzl , "iULi" , "nc")
+BUILTIN(__builtin_ctzll, "iULLi", "nc")
+// fixme: int ctzimax(uintmax_t)
+
+
+// Random GCC builtins
BUILTIN(__builtin_constant_p, "UsUs", "nc")
BUILTIN(__builtin_classify_type, "i.", "nc")
BUILTIN(__builtin___CFStringMakeConstantString, "FC*cC*", "nc")
More information about the cfe-commits
mailing list